E25-Points to be paid attention to in online disk expansion

Points to pay attention to when expanding disk online

1. Pay attention to the LVS name of the online expansion disk

2. Note that the time point of resize2fs is a single execution. When adding multiple disks, remember not to increase them together

pvcreate   /dev/sdb
vgextend  VolGroup00  /dev/sdb
lvextend -l +100%FREE /dev/VolGroup00/LogVol00
resize2fs  /dev/VolGroup00/LogVol00
[s-linuxad@imgfile-v-szzb ~]$ df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/VolGroup00-LogVol00
                      289G  169G  106G  62% /
/dev/sda1              99M   26M   68M  28% /boot
tmpfs                 7.8G   12K  7.8G   1% /dev/shm
[s-linuxad@imgfile-v-szzb ~]$ sudo -i
[root@imgfile-v-szzb ~]# lvdisplay
  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol00
  VG Name                VolGroup00
  LV UUID                8d1kvS-5mba-BSOQ-Z7rd-xf8a-hJ3h-y3lUTl
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                297.91 GB
  Current LE             9533
  Segments               2
  Allocation             inherit
  Read ahead sectors     0
  Block device           253:0
   
  --- Logical volume ---
  LV Name                /dev/VolGroup00/LogVol01
  VG Name                VolGroup00
  LV UUID                w2C8gK-NUfy-LF4s-vM4R-I5xZ-4Q62-lspDrQ
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.94 GB
  Current LE             62
  Segments               1
  Allocation             inherit
  Read ahead sectors     0
  Block device           253:1
   

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325649278&siteId=291194637