linux命令
文章平均质量分 65
jlnhyd
一定要三思而后行!
展开
-
find
find . -type f -mtime -1 -print ------------查找当前目录下建立不到一天的文件(包括子目录的) find . -type f -mtime -1 -print |xargs chmod u+w ----------并将其权限改为u+w find . -type f -mtime -1 |xargs ls -al------------原创 2009-02-25 10:31:00 · 678 阅读 · 0 评论 -
[转]Linux面试题
From: http://blog.chinaunix.net/u3/101356/showart.php?id=2120288 一.填空题:1. 在Linux系统中,以文件方式访问设备 。2. Linux内核引导时,从文件/etc/fstab中读取要加载的文件系统。3. Linux转载 2009-12-18 13:42:00 · 2138 阅读 · 0 评论 -
Linux gets first driver for USB 3.0
The NEC USB 3.0 controlleris due to(预期的;应到的;预定的) hit the streets this month, and already Sarah Sharp (the, um,"Geekess") has been able to crank out (制成)a Linux driver for the device.Sharp转载 2009-06-18 10:22:00 · 803 阅读 · 0 评论 -
看看我的linux什么版本呢?
$ lsb_release -aNo LSB modules are available.Distributor ID: UbuntuDescription: Ubuntu 7.10Release: 7.10Codename: gutsy # cat /etc/issue也可以看到原创 2009-03-06 11:07:00 · 469 阅读 · 0 评论 -
zip压缩命令
http://it.sohu.com/2004/06/09/20/article220452097.shtml zip [-选项] [文件名.zip] [文件名] 打包并压缩成文件名为 .zip 的文件 zip 所使用的格式其实与 DOS 和 Windows 上的 .zip是完全一样的!也就是说,它无需经过打包和压缩两道手续,就可以产生兼有两种效用的“压缩文件包”。而且,如转载 2009-03-04 14:17:00 · 8406 阅读 · 1 评论 -
我的vimtutor是乱码
sudo iconv -f gb2312 -t utf8 /usr/share/vim/vim71/tutor/tutor.zh.euc用了直接只在终端上把它完好的输出了。 用gedit打开倒可以阅读,不是乱码。可是不能保存呢。查了这个文件的权限,644。用sudo gedit打开的时候,终端出现了下面的的内容,gedit在一个新的窗口打开了。Launching原创 2009-03-05 15:24:00 · 1674 阅读 · 0 评论 -
我用到的ls命令
ls -al test_stress_edit_*.h | wc -l------计算以test_stress开头的.h文件的数目 ll test_perf_canvas_set_[^get,^config]*.*-------------查看set后不跟get或不跟config的文件原创 2009-03-02 12:32:00 · 445 阅读 · 0 评论 -
rename
rename s/test_normal/test_stress/ *.*------批量将当前目录下的所有文件的开头test_normal改成test_stress rename s/main_240_320_dflt.bak/main_480_854_dflt.bak/ *.bak------批量将所有.bak文件中以main_240_320_dflt结尾的文件改成以原创 2009-02-25 13:46:00 · 598 阅读 · 0 评论 -
sed
find . -name "*.c" -type f -perm 644 -exec sed -i s/ret = logInit(filepath)/ret = logInit(filepath);/g {} /;----加分号 sed -i s/]: T"/]: T//n"/g myfile.c ------在T后面加字符串“/n”;如果就是要加个回车,让T和”用回车原创 2009-02-25 09:54:00 · 1201 阅读 · 0 评论 -
su:鉴定故障
有两个用户:nsuser和mylinux当前是在mylinux上,想要切换到nsuser。执行命令:su - nsuser报错:su:鉴定故障 一开始以为nsuser的用户没有正确建立,于是查看/etc/passwdnsuser:x:1001:1002::/home/nsuser:/bin/sh(name:password:uid:gid:comment:home:sh原创 2009-12-22 16:00:00 · 15848 阅读 · 1 评论