Expansion master/Standby physical data disk:
[Email protected] ~]# drbdadm down data
[Email protected] ~]# mount/dev/sdb1/mnt/
[Email protected] ~]# df-h
Filesystem Size used Avail use% mounted on
/dev/sda3 7.2G 1.9G 5.0G 28%/
Tmpfs 242M 0 242M 0%/dev/shm
/DEV/SDA1 194M 57M 128M 31%/boot
/DEV/SDB1 380M 11M 350M 3%/mnt # can see the standby node disk utilization only 380M
[Email protected] ~]# Parted/dev/sdb p
model:msft Virtual Disk (SCSI)
Disk/dev/sdb:2147mb
Sector size (logical/physical): 512b/512b
Partition Table:msdos
Number Start End Size Type File system Flags
1 32.3kB 814MB 814MB Primary EXT4 # However, the true size of the standby node is 814M
2 814MB 979MB 165MB Primary
[Email protected] ~]# umount/mnt/
[[email protected] ~]# e2fsck-f/dev/sdb1 # view partition size
E2fsck 1.41.12 (17-may-2010)
Pass 1:checking inodes, blocks, and sizes
Pass 2:checking directory structure
Pass 3:checking Directory Connectivity
Pass 4:checking Reference counts
Pass 5:checking Group summary Information
/dev/sdb1:38/100744 files (0.0% non-contiguous), 22971/401409 blocks
[[email protected] ~]# RESIZE2FS/DEV/SDB1 # Reallocate partition (expansion)
RESIZE2FS 1.41.12 (17-may-2010)
Resizing the filesystem on/dev/sdb1 to 795184 (1k) blocks.
The filesystem on/dev/sdb1 is now 795184 blocks long.
[Email protected] ~]# mount/dev/sdb1/mnt/
[Email protected] ~]# df-h
Filesystem Size used Avail use% mounted on
/dev/sda3 7.2G 1.9G 5.0G 28%/
Tmpfs 242M 0 242M 0%/dev/shm
/DEV/SDA1 194M 57M 128M 31%/boot
/DEV/SDB1 752M 11M 703M 2%/mnt # Spare node disk space has been increased to maximum
[Email protected] ~]# ls/mnt/
This article is from the "Struggle Bar" blog, please be sure to keep this source http://lvnian.blog.51cto.com/7155281/1709384
DRBD expansion of Big data migrations