SaltStack installation

Linux cluster management, the configuration is basically the same. At the beginning, it is easy to maintain a few servers and log in to the server to change one by one. When there are hundreds of hosts on hand, the operation is a little broken. I saw a bunch of batch management tools Ssh key, Saltstack, expect, puppet, ansible, cfengine on the Internet.

Saltstack automatic operation and maintenance is selected from the comprehensive consideration of simplicity and practicality, and the development language is py.

Saltstack is a brand new infrastructure management method. It is a centralized management platform for server infrastructure. It can be up and running within a few minutes. The speed is fast enough. The second-level communication between servers is excellent. , It is easy to manage tens of thousands of servers in batches, which significantly reduces labor and operation and maintenance costs; it has configuration management, remote execution, monitoring and other functions, which can generally be understood as a simplified version of puppet and an enhanced version of func; by deploying the SaltStack environment, you can To execute commands in batches on thousands of servers, configure centralized management, distribute files, collect server data, operating system foundation, and software package management according to different business characteristics. 

Server installation configuration

#Install EPEL YUM source
yum install epel-release.noarch
#Install server
yum install salt- master

[[email protected] ~]# cd /etc/yum.repos.d/
[[email protected] yum.repos.d]# ls
CentOS- Base.repo
epel.repo

Client installation configuration

#Install EPEL YUM source
yum -y install epel-release.noarch
#Install client
yum -y install salt-minion

# Configure the host name as the client ID
line 16 master: 192.168.1.130
page 78 Line id: centos

#Set start
service salt-minion start
systemctl restart salt-minion

Server:
[[ email protected] ~]# salt-key -L
Accepted Keys:
Centos
Denied Keys:
Unaccepted Keys:
Rejected Keys:

Test service
salt'*' test.ping
salt'*' cmd.run'free -m'

WordPress database error: [Table 'yf99682.wp_s6mz6tyggq_comments' doesn't exist]
SELECT SQL_CALC_FOUND_ROWS wp_s6mz6tyggq_comments.comment_ID FROM wp_s6mz6tyggq_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 2220 ORDER BY wp_s6mz6tyggq_comments.comment_date_gmt ASC, wp_s6mz6tyggq_comments.comment_ID ASC

Leave a Comment

Your email address will not be published.