CommonCommand

#### 查看内存使用
$ free
              total        used        free      shared  buff/cache   available
Mem:      131920400     1039696    60624308    66203260    70256396    64246780
Swap:             0           0           0
## 改变显示单位
$ free -g
              total        used        free      shared  buff/cache   available
Mem:            125           0          57          63          67          61
Swap:             0           0           0
$ free -m
              total        used        free      shared  buff/cache   available
Mem:         128828        1014       59119       64651       68694       62741
Swap:             0           0           0
#### 硬盘使用量
$ df
Filesystem                   1K-blocks      Used  Available Use% Mounted on
/dev/mapper/vg_root-lv_root   20511356   2613276   16833120  14% /
devtmpfs                      65949600         0   65949600   0% /dev
tmpfs                         65960200  65960200          0 100% /dev/shm
tmpfs                         65960200    243060   65717140   1% /run
tmpfs                         65960200         0   65960200   0% /sys/fs/cgroup
/dev/sda1                       194241    157511      22394  88% /boot
/dev/mapper/vg_root-lv_home 2271859724 844917528 1311515280  40% /home
## 人类可读
$ df -h
Filesystem                   Size  Used Avail Use% Mounted on
/dev/mapper/vg_root-lv_root   20G  2.5G   17G  14% /
devtmpfs                      63G     0   63G   0% /dev
tmpfs                         63G   63G     0 100% /dev/shm
tmpfs                         63G  238M   63G   1% /run
tmpfs                         63G     0   63G   0% /sys/fs/cgroup
/dev/sda1                    190M  154M   22M  88% /boot
/dev/mapper/vg_root-lv_home  2.2T  806G  1.3T  40% /home

最后更新于

这有帮助吗?