摘要: [root@LocalWeb01 ~]# printf '%s%s%s\n' 1 2 3 41234[root@LocalWeb01 ~]# printf '%s%s%s' 1 2 3 41234[root@LocalWeb01 ~]# printf '%s%s\n' $(cat /etc/pass... 阅读全文
posted @ 2014-11-10 22:56 agang_19 阅读(173) 评论(0) 推荐(0)
摘要: [root@LocalWeb01 ~]# sort /etc/passwd |less (升序 )[root@LocalWeb01 ~]# sort -r /etc/passwd |less (降序)sort的-o选项由于sort默认是把结果输出到标准输出,所以需要用重定向才能将结果写入文件,形如s... 阅读全文
posted @ 2014-11-10 22:27 agang_19 阅读(348) 评论(0) 推荐(0)
摘要: 比如在php-fpm添加服务中,一部分脚步如下#!/bin/sh # # php-fpm - this script starts and stops the php-fpm daemin # # chkconfig: 2345 76 25 # processname: php-fpm # conf... 阅读全文
posted @ 2014-11-10 14:19 agang_19 阅读(313) 评论(0) 推荐(0)
摘要: PHP 5.4.8 添加系统服务命令之前没注意,PHP 5.4.8 的安装包有自带的系统服务注册文件的打开编译安装包,换成你自己的路径cd /mydata/soft/php-5.4.8/cp sapi/fpm/init.d.php-fpm /etc/init.d/php-fpmchmod +x /e... 阅读全文
posted @ 2014-11-10 14:07 agang_19 阅读(172) 评论(0) 推荐(0)
摘要: linux字符串列截取 cut -d ‘分割条件’ -f ‘列数’[root@LocalWeb01 ~]# less /etc/passwd | grep '^user' | grep -v 'root' | cut -d ':' -f 1user1 阅读全文
posted @ 2014-11-10 07:58 agang_19 阅读(1687) 评论(0) 推荐(0)
摘要: [root@LocalWeb01 log]# grep '^\[' acpidlinux中正则表达式和通配符的区别正则表达式是对文件内容,通配符是匹配文件名 例如 ls 'dddd*' 阅读全文
posted @ 2014-11-10 00:16 agang_19 阅读(159) 评论(0) 推荐(0)