在linux下需要设置windows共享。我们使用SMBA来实现。1.查看是否安装smba。rpm -qa | grep samba如果没有安装,则去 www.rpmfind.net 下载smb,输入查询条件为samba.ftp://195.220.108.108/linux/centos/6.5/...
$.grep(array, callback, [invert])过滤,常用解释: 使用过滤函数过滤数组元素.此函数至少传递两个参数(第三个参数为true或false,对过滤函数返回值取反,个人觉得用处不大): 待过滤数组和过滤函数. 过滤函数必须返回 true 以保留元素或 false 以删除元素...
分类:
其他好文 时间:
2014-11-03 15:53:32
阅读次数:
193
例子,查看80端口的占用情况:lsof -i:80 或者:netstat -apn | grep 80上面的命令执行之后可以显示进程号,找到进程号以后,再使用以下命令查看详细信息:ps -aux | grep 附:windows下查看端口占用命令:netstat -ano | findstr 80w...
分类:
系统相关 时间:
2014-11-03 15:50:14
阅读次数:
326
一、CPU大小 [root@idc ~]# more /proc/cpuinfo可以看到详细内容或:[root@idc ~]# cat /proc/cpuinfo |grep "model name" && cat /proc/cpuinfo |grep "physical id" model na...
分类:
系统相关 时间:
2014-11-03 12:57:04
阅读次数:
258
查找语句: find . -name "*orz(文件类型等)" | xargs grep "string" grep -i -r 'string' ./* grep 'string' * -rn grep 'string' * -rlNetstat 指令 命令用于显示各种网络相关信息,...
分类:
系统相关 时间:
2014-11-03 10:07:58
阅读次数:
254
一、grepgrep-printlinesmatchingapattern(grep可以分析一行信息,若当中有我们所需要的信息,就将该行拿出来)grep[OPTIONS]PATTERN[FILE...](pattern:文本字符和正则表达式的元字符组合而成的匹配条件)-a:将binary文本以text文本的方式搜寻数据-c:计算找到‘pattern’的次..
分类:
其他好文 时间:
2014-11-03 01:24:33
阅读次数:
161
??怎样绕过oracle 监听的password设置:1.找到监听进程pid ,并将它kill 掉ps -ef|grep tns [oracle@lixora admin]$ ps -ef|grep tns root 9 2 0 Jul11 ? 00:00:00 [netns]oracle 2966...
分类:
数据库 时间:
2014-11-02 22:10:51
阅读次数:
240
几个cpu
more /proc/cpuinfo |grep "physical id"|uniq|wc -l
每个cpu是几核(假设cpu配置相同)
more /proc/cpuinfo |grep "physical id"|grep "0"|wc -l
cat /proc/cpuinfo | grep processor...
分类:
系统相关 时间:
2014-11-02 16:35:41
阅读次数:
300
sed -i 's/10.1.1.1/10.1.1.2/g' `grep -ir 10.1.1.1 * |grep -E '.xml:|.cfg:|.ini:|.wsdl:|.properties:' | awk -F: '{print $1}' | uniq `注:当中1为原IP,2为新IP ;要...
分类:
系统相关 时间:
2014-11-02 12:05:10
阅读次数:
154
1. grep最简单的使用方法,匹配一个词:grep word filename
2. 可以从多个文件中匹配:grep word filename1 filenam2 filename3
3. 可以使用正则表达式匹配:grep -E pattern f1 f2 f3...
4. 可以使用-o只打印匹配的字符,如下所示:
lichao@ubuntu:command$ echo this is a line. | grep -E -o "[a-z]*\."
line.
5. 打印除匹配行之外的其他行,使用-v
...
分类:
其他好文 时间:
2014-11-01 23:19:52
阅读次数:
420