摘要: du :disk usage du 会显示指定的目录或文件所占用的磁盘空间 -a或-all 显示目录中个别文件的大小。 -b或-bytes 显示目录或文件大小时,以byte为单位。 -c或--total 除了显示个别目录或文件的大小外,同时也显示所有目录或文件的总和。 -D或--dereferenc 阅读全文
posted @ 2021-09-16 10:19 拥抱大海,面向天空 阅读(96) 评论(0) 推荐(0)
摘要: #!/bin/bash for ip in {1..254} do { ping -c 1 10.122.138.$ip } if [ $? -eq 0 ]; then echo 10.122.138.$ip UP >>/root/a.txt else echo 10.122.138.$ip DOW 阅读全文
posted @ 2021-09-14 00:09 拥抱大海,面向天空 阅读(131) 评论(0) 推荐(0)
摘要: ifconfig ens32 |awk -F' ' NR==2'{print$2}' 阅读全文
posted @ 2021-09-13 22:38 拥抱大海,面向天空 阅读(82) 评论(0) 推荐(0)
摘要: [root@k8s-node03 ~]# ll total 9040 -rw . 1 root root 1259 Aug 11 18:24 anaconda-ks.cfg -rw-r--r--. 1 root root 3619 Aug 15 08:24 index.html -rw-r--r-- 阅读全文
posted @ 2021-09-12 14:24 拥抱大海,面向天空 阅读(57) 评论(0) 推荐(0)
摘要: [root@zabbix-server ~]# cat test.txt Fri Sep 10 07:33:23 CST 2021 [root@zabbix-server ~]# pwd | tee -a test.txt /root [root@zabbix-server ~]# cat test 阅读全文
posted @ 2021-09-10 07:52 拥抱大海,面向天空 阅读(44) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2021-09-09 14:53 拥抱大海,面向天空 阅读(25) 评论(0) 推荐(0)
摘要: usermod -L 相当于passwd -l 锁定用户 usermod -U 相当于passwd -u 解锁用户 passwd -S 查看用户状态 usermod -l 新用户名称 就用户名称 chage 命令 设置账号有效期 chage -W 30 用户名称 密码到期前30天提醒 chage - 阅读全文
posted @ 2021-09-09 14:52 拥抱大海,面向天空 阅读(19) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2021-09-09 14:51 拥抱大海,面向天空 阅读(25) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2021-09-09 14:49 拥抱大海,面向天空 阅读(29) 评论(0) 推荐(0)
摘要: sar命令 [root@zabbix-server ~]# sar -u 1 5 Linux 3.10.0-1160.el7.x86_64 (zabbix-server) 09/08/2021 _x86_64_ (2 CPU) 05:18:51 PM CPU %user %nice %system 阅读全文
posted @ 2021-09-08 17:28 拥抱大海,面向天空 阅读(87) 评论(0) 推荐(0)