摘要: # 检查主机连接# ansible test -m ping # 执行远程命令# ansible test -m command -a 'uptime' # 执行主控端脚本# ansible test -m script -a '/etc/ansible/script/test.sh' # 执行远程 阅读全文
posted @ 2017-01-13 11:41 行知散人 阅读(3879) 评论(0) 推荐(0) 编辑
摘要: xenserver是基于redhat的,可以在zabbix官网下载对应的redhat zabbix安装包,直接安装即可 http://repo.zabbix.com/zabbix/3.0/rhel/5/x86_64/ 根据zabbix server 的版本来选agent的版本 rpm -ivh直接安 阅读全文
posted @ 2017-01-12 14:53 行知散人 阅读(1171) 评论(0) 推荐(0) 编辑
摘要: 从windows迁移网站到linux 发现乱码 出现这种情况的原因为两种操作系统的中文压缩方式不同,在windows环境中中文一般为gbk,而在linux环境中为utf8,这就导致了在windows下能正常显示 txt文件在linux环境下打开呈现了乱码状态。 解决方法:在linux用iconv命令 阅读全文
posted @ 2017-01-12 11:41 行知散人 阅读(782) 评论(0) 推荐(0) 编辑
摘要: 1、. 匹配任意除换行符“\n”外的字符;2、*表示匹配前一个字符0次或无限次;3、+或*后跟?表示非贪婪匹配,即尽可能少的匹配,如*?重复任意次,但尽可能少重复;4、 .*? 表示匹配任意数量的重复,但是在能使整个匹配成功的前提下使用最少的重复。如:a.*?b匹配最短的,以a开始,以b结束的字符串 阅读全文
posted @ 2017-01-05 11:40 行知散人 阅读(127) 评论(0) 推荐(0) 编辑
摘要: 1.为了安全,使用nologin账号来运行程序, su -s /bin/bash -c "ls" www 这条命令到底做了什么呢?su -s 是指定shell,这里www用户是nologin用户,是没有默认的shell的,这里指定使用/bin/bash, -c 后面接需要运行的命令, 后面www是用 阅读全文
posted @ 2016-12-29 09:47 行知散人 阅读(4582) 评论(0) 推荐(0) 编辑
摘要: 1xx Informational Request received, continuing process. This class of status code indicates a provisional response, consisting only of the Status-Line 阅读全文
posted @ 2016-12-28 11:22 行知散人 阅读(897) 评论(0) 推荐(0) 编辑
摘要: 查找资料将http中缓存相关的知识记录下 一般来说:Last-Modifed和Expires是一对,ETag和Cache-Control是一对 Last-Modified ETag 由上面可以得知,Last-Modified、ETag这两种机制的运作模式几乎是一样的 再论Expires与Cache- 阅读全文
posted @ 2016-12-28 11:07 行知散人 阅读(207) 评论(0) 推荐(0) 编辑
摘要: http://linuxtools-rst.readthedocs.io/zh_CN/latest/tool/lsof.html 阅读全文
posted @ 2016-12-28 10:34 行知散人 阅读(179) 评论(0) 推荐(0) 编辑
摘要: iostat -x 1 10 Linux 2.6.18-92.el5xen 02/03/2009 avg-cpu: %user %nice %system %iowait %steal %idle 1.10 0.00 4.82 39.54 0.07 54.46 Device: rrqm/s wrqm 阅读全文
posted @ 2016-12-27 17:55 行知散人 阅读(211) 评论(0) 推荐(0) 编辑
摘要: 1.使用hdparm命令 hdparm -Tt /dev/sda /dev/sda: Timing cached reads: 6676 MB in 2.00 seconds = 3340.18 MB/sec Timing buffered disk reads: 218 MB in 3.11 se 阅读全文
posted @ 2016-12-27 16:31 行知散人 阅读(349) 评论(0) 推荐(0) 编辑