多语言展示
当前在线:497今日阅读:2今日分享:38

linux查看文件 系统的各种方法

常用的linux查看文件系统的方法
方法/步骤
1

不需挂载就能查看的命令: 1. file [root@localhost dev]# file -s /dev/sda1/dev/sda1: Linux rev 1.0 ext4 filesystem data (extents) (huge files)  2.parted[root@localhost dev]# parted /dev/sdaGNU Parted 1.8.8Using /dev/sdaWelcome to GNU Parted! Type 'help' to view a list of commands.(parted) printModel: VMware, VMware Virtual S (scsi)Disk /dev/sda: 21.5GBSector size (logical/physical): 512B/512BPartition Table: msdosNumber  Start   End     Size    Type     File system  Flags 1      32.3kB  206MB   206MB   primary  ext3         boot 2      206MB   21.5GB  21.3GB  primary               lvm 3.fdisk[root@localhost dev]# fdisk -l /dev/sdaDisk /dev/sda: 21.4 GB, 21474836480 bytes255 heads, 63 sectors/track, 2610 cylindersUnits = cylinders of 16065 * 512 = 8225280 bytesDisk identifier: 0x0007c1e8   Device Boot      Start         End      Blocks   Id  System/dev/sda1   *           1          25      200781   83  Linux/dev/sda2              26        2610    20764012+  8e  Linux LVM

2

需要挂载才能查看的命令: 1.mount[root@localhost dev]# mount/dev/mapper/VolGroup00-LogVol00 on / type ext3 (rw)/proc on /proc type proc (rw)sysfs on /sys type sysfs (rw)devpts on /dev/pts type devpts (rw,gid=5,mode=620)/dev/sda1 on /boot type ext3 (rw)tmpfs on /dev/shm type tmpfs (rw)none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)  2.df[root@localhost dev]# df -TFilesystem    Type   1K-blocks      Used Available Use% Mounted on/dev/mapper/VolGroup00-LogVol00              ext3    18320140   3426724  13962808  20% //dev/sda1     ext3      194442     13480    170923   8% /boottmpfs        tmpfs      516908         0    516908   0% /dev/shm3.stat[root@localhost /]# stat -f bin  File: 'bin'    ID: 3ef5d5f4a8cc1340 Namelen: 255     Type: ext2/ext3Block size: 4096       Fundamental block size: 4096Blocks: Total: 4580035    Free: 3723354    Available: 3490702Inodes: Total: 1163264    Free: 1044678

推荐信息