ubuntu16.04安装中文输入法:html
https://blog.csdn.net/singleyellow/article/details/77448246linux
ubuntu16.04 用vi编辑代码,能够打开,可是内容都是白色:ios
sudo apt install vimubuntu
经常使用工具vim
文本处理bash
进程调试工具
目标文件分析性能
全局 top 或 sarspa
top查看某一个进程所占内存:.net
top -p PID
查看一个进程的详细信息:
cat /proc/pid/status
这里会打印出当前进程详细的状况,其中,内存是 VmRSS。
内存free
IO iostat(注:Linux经常使用的收集系统信息的命令iostat,sar等并无默认安装。安装apt-get install sysstat后,这些命令均可以使用了)
系统调用 strace 栈pstack(注:pstack并无默认安装,sudo apt-get install pstack)
进程 ps -ef 查看进程ID
程序 -pg参数 gprof
通常权限 755
最高权限 777
给指定文件夹下全部内容加权限
chmod 755 -R /home/zhangsuosheng
ln -s 源文件夹 生成的软链接文件名
cp -r
选项
-w 抓取当前活动窗口
-a 抓取自定义的区域
-b 包含窗口的边框
-B 去除边框
-d N 等待N秒后截图
-e 附加效果(shadow,border,none)
-i 交互式运行
举例
截取屏幕
gnome-screenshot
截取当前活动窗口(要边框)
gnome-screenshot -wb
截取自定义区域
gnome-screenshot -a
5秒后截取当前窗口去除边框,附加阴影效果
gnome-screenshot -wBe shadow -d 5
n下一个
N上一个
command | tee outputfile
输出文件不存在时能够自动建立,注意是tee 不是 tree
command 2>&1 | tee outputfile
command > outputfile 覆盖 command >> outputfile 追加
command 2 > outputfile 覆盖
command 2 >> outputfile 追加
find
-name '*.html' 根据名称查找
-type f 类型为普通文件
b - 块设备文件。
d - 目录。
c - 字符设备文件。
p - 管道文件。
l - 符号连接文件。
f - 普通文件
-mmin -30 最近30分钟改动过的文件
-mmin +30 30分钟以前改动过的文件
-mtime -1 最近1天改动过的文件
https://linuxtools-rst.readthedocs.io/zh_CN/latest/tool/index.html
-C:对tree显示的进行颜色显示,便于查看。
-d: 只显示目录。
-L:显示层级数量,关键参数。
例如:显示3层,只显示目录
tree -d -L 3
例如:scancel掉174969到175007号任务
for((i=174969;i<175008;i++));do scancel $i;done;
https://blog.csdn.net/wzy_1988/article/details/8674535
grep -A 2 str_to_search
查看当前目录大小
du -h --max-depth=0
查看当前目录下的各目录的大小
du -h --max-depth=1
查看指定目录大小
du -h --max-depth=0 zhangsuosheng
查看指定目录下的各目录的大小
du -h --max-depth=1 zhangsuosheng