Centos 大于4TB 硬盘LVM 水平扩容

环境

名称 属性
CPU x5650
内存 4G
磁盘 20G+4TB

这时候,我们假设服务器已经有如下东西:

  • 安装好了Parted(yum install parted)

  • 分区容量已经告捷,公司为服务器增加了一块4T硬盘用来增加容量!

  • 除了/boot分区外,其余都为LVM 模式的扩展逻辑分区

软件安装与信息查看

首先查看软件是否安装:

[root@Candy ~]# rpm -qa | grep lvm
lvm2-libs-2.02.118-2.el6.x86_64
lvm2-2.02.118-2.el6.x86_64
[root@Candy ~]# lv
lvchange     lvextend     lvmdiskscan  lvmsar       lvresize
lvconvert    lvm          lvmdump      lvreduce     lvs
lvcreate     lvmchange    lvmetad      lvremove     lvscan
lvdisplay    lvmconf      lvmsadc      lvrename
[root@Candy ~]# rpm -qa | grep parted
parted-2.1-29.el6.x86_64

软件准备好后顺便查看下 VM 硬件:

[root@Candy ~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/vg_candy-root
                      7.3G  231M  6.7G   4% /
tmpfs                 1.9G     0  1.9G   0% /dev/shm
/dev/sda1             477M   30M  422M   7% /boot
/dev/mapper/vg_candy-home
                      3.9G  8.0M  3.7G   1% /home
/dev/mapper/vg_candy-usr
                      3.9G  382M  3.3G  11% /usr
/dev/mapper/vg_candy-var
                      3.9G   63M  3.6G   2% /var
[root@Candy ~]# fdisk -l
Disk /dev/sda: 21.5 GB, 21474836480 bytes
255 heads, 63 sectors/track, 2610 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0006e71c
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          64      512000   83  Linux
Partition 1 does not end on cylinder boundary.
/dev/sda2              64        2611    20458496   8e  Linux LVM
Disk /dev/sdb: 4398.0 GB, 4398046511104 bytes
255 heads, 63 sectors/track, 534698 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/mapper/vg_candy-root: 8061 MB, 8061452288 bytes
255 heads, 63 sectors/track, 980 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/mapper/vg_candy-usr: 4294 MB, 4294967296 bytes
255 heads, 63 sectors/track, 522 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size 

你可能感兴趣的:(Linux,LVM,TB,LVM扩容,Centos)