#!/bin/bash hostname=hostname old_hostname=grep -Ev '^$|^#' /etc/zabbix/zabbix_agentd.conf | grep Hostname sed -i "s#old_hostname#Hostname=hostname#g" /etc/zabbix/zabbix_agentd.conf systemctl restart zabbix-agent 下发: ansible -i hosts.work new-openstack -m shell -a "netstat -lntup | grep 10050" ansible -i hosts.work new-openstack-ceph -m shell -a "cat /etc/zabbix/zabbix_agentd.conf | grep 172.24.15.122" ansible -i hosts.work new-openstack -m copy -a "src=/root/test.sh dest=/tmp/test.sh" a.... 修改Hostname值 zabbix
[root@system-wiki ~]# cat /usr/lib/systemd/system/wiki.service [Unit] Description=Wiki [Service] Type=simple PIDFile=/usr/local/atlassian/confluence/work/catalina.pid ExecStartPre=rm -rf /usr/local/atlassian/confluence/work/catalina.pid ExecStart=/usr/local/atlassian/confluence/bin/startup.sh ExecStop=/usr/local/atlassian/confluence/bin/shutdown.sh PrivateTmp=true Restart=always User=confluence Group=confluence [Install] WantedBy=multi-user.target pid设置文件:/usr/local/atlassian/confluence/bin/s....... confluence自启动 Linux
添加硬盘后,输入如下命令可识别: echo '- - -' > /sys/class/scsi_host/host0/scan #vm虚拟机扫描硬盘并识别硬盘 vmware添加硬盘识别问题 vmware