linux下磁盘管理

磁盘格式化

[root@11gdg ~]# mkfs.ext4 /dev/sdb1
mke2fs 1.41.12 (17-May-2010)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
inodes, 2620595 blocks
blocks (5.00%) reserved for the super user
First data block=0
Maximum filesystem blocks=2684354560
block groups
blocks per group, 32768 fragments per group
inodes per group
Superblock backups stored on blocks: 
        32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632

Writing inode tables: done                            
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 31 mounts or
days, whichever comes first.  Use tune2fs -c or -i to override.

mkfs.ext4 /dev/sdb1
View Code

磁盘挂载

[root@11gdg /]# mount -t ext4 /dev/sdb1 /rman_backup/


[root@11gdg /]# df -Th
Filesystem    Type    Size  Used Avail Use% Mounted on
/dev/sda2     ext4     16G  2.9G   13G  20% /
tmpfs        tmpfs    751M     0  751M   0% /dev/shm
/dev/sdb1     ext4    9.9G  151M  9.2G   2% /rman_backup


#
# /etc/fstab
# Created by anaconda on Fri Jun 28 01:39:52 2013
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
UUID=d2abcbb7-dc9b-4fdd-9971-4f1060f19187 /                       ext4    defaults        1 1
UUID=a42a3594-4da2-4371-b20c-2ca36d569356 swap                    swap    defaults        0 0
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
/dev/sdb1               /rman_backup            ext4    defaults        0 0

vi /etc/fstab
View Code
posted @ 2014-07-24 09:57  ArcerZhang  阅读(191)  评论(0编辑  收藏  举报