zabbix监控系统搭建好了之后,就需要为各种角色host加入进来,现在新增一台zabbix-agent: 1.在172.16.23.128上安装zabbix-agent,zabbix-server:172.16.23.131 安装完成agent端程序之后,现在做一些简单配置: 然后开启服务,并检查 ...
分类:
其他好文 时间:
2018-12-09 16:26:00
阅读次数:
253
备忘 环境:Ubuntu 14.04 基于官网配置 "官网链接" ①导入源: ②安装: ③配置: ④启动: 完 ...
分类:
系统相关 时间:
2018-12-09 14:02:57
阅读次数:
416
zabbix_agent 端 ip : 192.168.1.206 hostname: www.test3.com 1、添加主机 2、添加模板 添加模板 更新模板 3、应用模板之后,等一会自动添加了这些信息 4、启用主机 启用主机前 启用主机后 5、配置监控 点击对应配置-主机-图形 查看默认生成的 ...
分类:
系统相关 时间:
2018-12-06 20:23:20
阅读次数:
574
grains工具grains是在minion启动时收集到的一些信息,如操作系统类型、网卡ip、内核版本、cpu架构等信息salt‘selecthostname‘grains.ls列出所有grains项目名字sakt‘selecthostname‘grains.items列出所有的grains项目与值grains的信息并不是动态的,不会实时变更,只有在minion启动
分类:
其他好文 时间:
2018-12-06 17:46:05
阅读次数:
226
涉及函数: password_hash(),password_verify()。 注意:password_hash 函数 支持算法中的PASSWORD_BCRYPT 使用时不建议使用salt后期版本可能将被废除,cost视服务器性能通常8-10。 ...
分类:
Web程序 时间:
2018-12-02 22:52:52
阅读次数:
293
目标
https://docs.saltstack.com/en/latest/
模块
https://docs.saltstack.com/en/latest/ref/modules/all/index.html
salt ‘*‘ service.available sshd 验证sshd服务
[root@master ~]# grep -v ‘^$‘ /etc/salt/master |grep -v ‘#‘
client_acl: #客户端开启模块限制
luo: #用户名
- test.ping
- network.*
file_roots:
base:
- /srv/salt
pillar_roots:
base:
- /srv/pillar
[root@master ~]# systemctl restart salt-master
给用户授权
[root@master ~]# useradd luo
useradd:用户“luo”已存在
[root@master ~]# passwd
分类:
其他好文 时间:
2018-12-01 00:13:20
阅读次数:
235
状态模块:
https://docs.saltstack.com/en/latest/ref/states/all/salt.states.file.html#module-salt.states.file
[root@master ~]# grep -v ‘^$‘ /etc/salt/master |grep -v ‘#‘
client_acl:
luo:
- test.ping
- network.*
file_roots: #top.sls路径,可以写多个
base: #但是只读取base路径
- /srv/salt/base
test:
- /srv/salt/test
prod:
- /srv/salt/prod
pillar_roots:
base:
- /srv/pillar
mysql.host: ‘192.168.43.118‘
mysql.user: ‘salt‘
mysql.pass: ‘Myq1231!‘
mysql.db: ‘salt‘
mysql.port: 330
分类:
其他好文 时间:
2018-12-01 00:08:52
阅读次数:
253
[root@master ~]# mkdir /srv/salt/prod/pkg
[root@master ~]# mkdir /srv/salt/prod/haproxy
[root@master ~]# mkdir /srv/salt/prod/haproxy/files
[root@master pkg]# pwd
/srv/salt/prod/pkg
[root@master pkg]# vim pkg-init.sls
[root@master pkg]# cat pkg-init.sls
pkg-init:
pkg.installed:
- names:
- gcc
- gcc-c++
- glibe
- make
- autoconf
- openssl
- openssl-devel
[root@master prod]# cd haproxy/files/
[root@master files]# wget https://fossies.org/linux/mis
分类:
其他好文 时间:
2018-12-01 00:04:37
阅读次数:
225
[root@localhost master]# salt-key -A 同意所有
[root@localhost master]# salt-key -a 192* 可选 *代表所有
-L 列表
-D 删除所有
-d 删除选中的
[root@localhost master]# salt-key -a 192*
The following keys are going to be accepted:
Unaccepted Keys:
192.168.43.118
192.168.43.71
Proceed? [n/Y] Y
Key for minion 192.168.43.118 accepted.
Key for minion 192.168.43.71 accepted.
分类:
其他好文 时间:
2018-11-30 22:34:43
阅读次数:
246
一、下载zabbix-agent客户端 被监控的主机装在windows server 2012 64位操作系统,被监控端需要安装: http://www.zabbix.com/downloads/3.2.0/zabbix_agents_3.2.0.win.zip 二、配置 下载完zip包,解压后会有 ...