一次Saltstack的报错记录
master端报错信息:1
2
3
4
5
6
7
# salt -G 'roles:nginx' test.ping
Key grains with value roles:nginx env:prod has an invalid type of <type 'str'>, a dict is required for this value
Key grains with value roles:nginx env:prod has an invalid type of <type 'str'>, a dict is required for this value
Key grains with value roles:nginx env:prod has an invalid type of <type 'str'>, a dict is required for this value
Key grains with value roles:nginx env:prod has an invalid type of <type 'str'>, a dict is required for this value
minion.saltstack.com:
True
minion端的配置:
1
2
3
4
5
6
7
8
9
10
11
# egrep -v '#|^$' /etc/salt/minion
master: 10.10.10.131
id: minion.saltstack.com
mysql.host: '10.10.10.131'
mysql.user: 'salt'
mysql.pass: 'salt'
mysql.db: 'salt'
mysql.port: 3306
grains:
roles: nginx
env: prod
小结:主要是因为yaml的格式问题,之前以为是minion端的问题,后来发现是自己配置master的时候出了点格式问题,重新调整后,多半可以解决。
很厉害!!!!!!!
页:
[1]