摘要:
find /etc/ -name "*.conf" | xargs tar -cpvf `date +%F`.tar && cp -a `date +%F`.tar /usr/local/src/ 阅读全文
posted @ 2020-07-11 21:37
树在地上
阅读(644)
评论(0)
推荐(0)
摘要:
find /etc/ -type f -size +1M 阅读全文
posted @ 2020-07-11 21:33
树在地上
阅读(364)
评论(0)
推荐(0)
摘要:
sed -ri.bak '/^#/s/^#//' /data/fstab 此处实验时,将fstab文件cp了一份到/data下进行测试 阅读全文
posted @ 2020-07-11 21:23
树在地上
阅读(388)
评论(0)
推荐(0)
摘要:
ifconfig|sed -nr "2s/[^0-9]+([0-9.]+).*/\1/p" 阅读全文
posted @ 2020-07-11 21:18
树在地上
阅读(414)
评论(0)
推荐(0)
摘要:
取目录 echo "/etc/fstab" |sed -r 's#(^/.*/)([^/]+/?)#\1#' 取基名 echo "/etc/fstab" |sed -r 's#(^/.*/)([^/]+/?)#\2#' 阅读全文
posted @ 2020-07-11 21:17
树在地上
阅读(411)
评论(0)
推荐(0)
摘要:
w -h|tr -s " "|cut -d " " -f3|sort|uniq -c|sort -nr 阅读全文
posted @ 2020-07-11 17:16
树在地上
阅读(345)
评论(0)
推荐(0)
摘要:
[root@centos7 data]#grep -v "/sbin/nologin" /etc/passwd root:x:0:0:root:/root:/bin/bash sync:x:5:0:sync:/sbin:/bin/sync shutdown:x:6:0:shutdown:/sbin: 阅读全文
posted @ 2020-07-11 16:56
树在地上
阅读(488)
评论(0)
推荐(0)
摘要:
cut -d: -f1,3,7 /etc/passwd |sort -t: -k2 -n | tail -1 阅读全文
posted @ 2020-07-11 16:01
树在地上
阅读(346)
评论(0)
推荐(0)

浙公网安备 33010602011771号