linux 常用命令及零散知识

磁盘管理常用命令

fdisk -l  //展示磁盘使用情况

df -h      //展示目录挂载情况

du -sh   //查文件、文件夹的总大小

scp /home/a.txt /home/b.txt root@10.12.34.11:/root/test  //从本地向远处复制

 gcc GNU Compiler Collection

清理范围大小:make clean < make distclean

grep 'am' d.log | wc -l   //统计d.log中的am行数

sed -i 's/am/ee/g' d.log  //替换d.log的am为ee

:1,10s/am/ee/g  //替换1-10行中的am为ee

持续更新。。。

原文地址:https://www.cnblogs.com/hblthink/p/8570549.html