Linux_常用命令_03_磁盘/挂载_信息查看

时间:2023-03-08 17:52:37
Linux_常用命令_03_磁盘/挂载_信息查看

1、

1.1、

mount

不带参数的话,显示的是 当前已经挂载的情况

1.2、

df

不带参数的话,硬盘分区状况查询

2、

2.1、

cat /proc/partitions

2.2、

fdisk -l

2.3、

3、

3.1、ubuntu 的相关显示信息:

root@33zzz:~# fdisk -l

Disk /dev/sda: 128.8 GB, 128849018880 bytes
255 heads, 63 sectors/track, 15665 cylinders, total 251658240 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00017f96 Device Boot Start End Blocks Id System
/dev/sda1 * 2048 249561087 124779520 83 Linux
/dev/sda2 249563134 251656191 1046529 5 Extended
/dev/sda5 249563136 251656191 1046528 82 Linux swap / Solaris root@33zzz:~# cat /proc/partitions
major minor #blocks name 11 0 1048575 sr0
8 0 125829120 sda
8 1 124779520 sda1
8 2 1 sda2
8 5 1046528 sda5 root@33zzz:~# mount
/dev/sda1 on / type ext4 (rw,errors=remount-ro)
proc    on /proc type proc (rw,noexec,nosuid,nodev)
sysfs   on /sys type sysfs (rw,noexec,nosuid,nodev)
none    on /sys/fs/fuse/connections type fusectl (rw)
none    on /sys/kernel/debug type debugfs (rw)
none    on /sys/kernel/security type securityfs (rw)
udev    on /dev type devtmpfs (rw,mode=0755)
devpts  on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
tmpfs   on /run type tmpfs (rw,noexec,nosuid,size=10%,mode=0755)
none   on /run/lock type tmpfs (rw,noexec,nosuid,nodev,size=5242880)
none   on /run/shm type tmpfs (rw,nosuid,nodev)
.host:/  on /mnt/hgfs type vmhgfs (rw,ttl=1)
vmware-vmblock  on /run/vmblock-fuse type fuse.vmware-vmblock (rw,nosuid,nodev,default_permissions,allow_other)
gvfs-fuse-daemon on /home/zzz/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=zzz) root@33zzz:~# df /
文件系统 1K-块 已用 可用 已用% 挂载点
/dev/sda1 124602456 18693288 99670192 16% / root@33zzz:~#

3.2、android4.4 相关信息显示:

shell@mako:/dev/block # df
Filesystem Size Used Free Blksize
/dev 917.4M 128.0K 917.3M 4096
/sys/fs/cgroup 917.4M 12.0K 917.4M 4096
/mnt/secure 917.4M 0.0K 917.4M 4096
/mnt/asec 917.4M 0.0K 917.4M 4096
/mnt/obb 917.4M 0.0K 917.4M 4096
/system 827.8M 288.6M 539.2M 4096
/cache 551.7M 9.8M 542.0M 4096
/data 12.9G 531.0M 12.4G 4096
/persist 15.8M 4.2M 11.6M 4096
/firmware 64.0M 44.4M 19.5M 16384
/mnt/shell/emulated 12.9G 531.0M 12.4G 4096 shell@mako:/dev/block # cat /proc/partitions
major minor #blocks name 179 0 15388672 mmcblk0
179 1 65536 mmcblk0p1
179 2 512 mmcblk0p2
179 3 512 mmcblk0p3
179 4 2048 mmcblk0p4
179 5 512 mmcblk0p5
179 6 22528 mmcblk0p6
179 7 22528 mmcblk0p7
179 8 780 mmcblk0p8
179 9 780 mmcblk0p9
179 10 780 mmcblk0p10
179 11 512 mmcblk0p11
179 12 512 mmcblk0p12
179 13 512 mmcblk0p13
179 14 2048 mmcblk0p14
179 15 512 mmcblk0p15
179 16 512 mmcblk0p16
179 17 512 mmcblk0p17
179 18 512 mmcblk0p18
179 19 16384 mmcblk0p19
179 20 16384 mmcblk0p20
179 21 860160 mmcblk0p21
179 22 573440 mmcblk0p22
179 23 13798400 mmcblk0p23
179 24 512 mmcblk0p24
179 25 495 mmcblk0p25
shell@mako:/dev/block # mount
rootfs / rootfs ro,relatime 0 0
tmpfs /dev tmpfs rw,seclabel,nosuid,relatime,mode=755 0 0
devpts /dev/pts devpts rw,seclabel,relatime,mode=600 0 0
proc /proc proc rw,relatime 0 0
sysfs /sys sysfs rw,seclabel,relatime 0 0
selinuxfs /sys/fs/selinux selinuxfs rw,relatime 0 0
debugfs /sys/kernel/debug debugfs rw,relatime 0 0
none /acct cgroup rw,relatime,cpuacct 0 0
none /sys/fs/cgroup tmpfs rw,seclabel,relatime,mode=750,gid=1000 0 0
tmpfs /mnt/secure tmpfs rw,seclabel,relatime,mode=700 0 0
tmpfs /mnt/asec tmpfs rw,seclabel,relatime,mode=755,gid=1000 0 0
tmpfs /mnt/obb tmpfs rw,seclabel,relatime,mode=755,gid=1000 0 0
none /dev/cpuctl cgroup rw,relatime,cpu 0 0
/dev/block/platform/msm_sdcc.1/by-name/system /system ext4 ro,seclabel,relatime,
data=ordered 0 0
/dev/block/platform/msm_sdcc.1/by-name/cache /cache ext4 rw,seclabel,nosuid,node
v,noatime,data=ordered 0 0
/dev/block/platform/msm_sdcc.1/by-name/userdata /data ext4 rw,seclabel,nosuid,no
dev,noatime,noauto_da_alloc,data=ordered 0 0
/dev/block/platform/msm_sdcc.1/by-name/persist /persist ext4 rw,seclabel,nosuid,
nodev,relatime,nodelalloc,data=ordered 0 0
/dev/block/platform/msm_sdcc.1/by-name/modem /firmware vfat ro,relatime,uid=1000
,gid=1000,fmask=0337,dmask=0227,codepage=cp437,iocharset=iso8859-1,shortname=mix
ed,errors=remount-ro 0 0
/dev/fuse /mnt/shell/emulated fuse rw,nosuid,nodev,relatime,user_id=1023,group_i
d=1023,default_permissions,allow_other 0 0
shell@mako:/dev/block #