CentOS7 安装Saltstack

 时间:2026-04-27 07:18:32

1、安装Saltstack

[root@linuxprobe ~]# yum -y install salt-master

[root@linuxprobe ~]# systemctl start salt-master 

[root@linuxprobe ~]# systemctl enable salt-master

# 配置防火墙规则

[root@linuxprobe ~]# firewall-cmd --add-port={4505/tcp,4506/tcp} --permanent 

success

[root@linuxprobe ~]# firewall-cmd --reload 

succes

CentOS7 安装Saltstack

CentOS7 安装Saltstack

2、# 安装salt-minion,在同一台服务器

[root@linuxprobe ~]# yum --enablerepo=epel -y install salt-minion

[root@linuxprobe ~]# sed -i 's/\#master\: salt/master\: www\.linuxprobe\.com/g' /etc/salt/minion

或者

[root@linuxprobe ~]# vi /etc/salt/minion

# 设置salt-master服务

master: www.linuxprobe.com

# master 使用域名的话需要设置本机host解析

echo "10.1.1.87 www.linuxprobe.com" >>/etc/hosts

[root@linuxprobe ~]# systemctl start salt-minion 

[root@linuxprobe ~]# systemctl enable salt-minion

# salt-master 与salt-minion连接

[root@linuxprobe ~]# salt-key -y -A

[root@linuxprobe ~]# salt-key -L 

Accepted Keys:

www.linuxprobe.com

Denied Keys:

Unaccepted Keys:

Rejected Keys:

[root@linuxprobe ~]# salt "*" test.ping 

www.linuxprobe.com:

    True

CentOS7 安装Saltstack

  • CentOS7 mini系统安装
  • CentOS7 安装GUI界面
  • Centos7 yum安装redis方法
  • Linux(CentOS7)上部署Telnet
  • CentOS7 截图
  • 热门搜索
    关于感恩的手抄报资料 中秋节手抄报的内容 关于正月十五的手抄报 争做最美少年手抄报 关于运动会的手抄报 科技之光手抄报内容 关于植物的手抄报 关于猴年的手抄报 小学生健康知识手抄报 关于春天的手抄报花边