-2

I want resize my /dev/bcache0 to full HDD size.

But I use resize2fs /dev/bcache0 it tell me:

[localhost-PC ~]# resize2fs /dev/bcache0
resize2fs 1.46.2 (28-Feb-2021)
resize2fs: Device or resource busy while trying to open /dev/bcache0
Couldn't find valid filesystem superblock.

I tried resize the bcache location /dev/sdb1 is same

[localhost-PC ~]# resize2fs /dev/sdb1
resize2fs 1.46.2 (28-Feb-2021)
resize2fs: Device or resource busy while trying to open /dev/sdb1
Couldn't find valid filesystem superblock.

Below is my disks pattern:

[localhost-PC ~]# lsblk
NAME                     MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda                        8:0    0 223.6G  0 disk 
├─sda1                     8:1    0   300M  0 part /boot/efi
├─sda2                     8:2    0     2G  0 part /boot
├─sda3                     8:3    0  17.2G  0 part [SWAP]
└─sda4                     8:4    0 204.1G  0 part 
  └─bcache0              254:0    0   1.7T  0 disk 
    └─VolumeGroup00-root 253:0    0   1.7T  0 lvm  /
sdb                        8:16   0   3.6T  0 disk 
└─sdb1                     8:18   0   1.7T  0 part 
  └─bcache0              254:0    0   1.7T  0 disk 
    └─VolumeGroup00-root 253:0    0   1.7T  0 lvm  /

Thank you

iHad 169
  • 1,267
  • 1
  • 10
  • 16

1 Answers1

1

According to lsblk, /dev/bcache0 is a physical volume within a volume group, hence, in order to resize the root filesystem, and use all space available in sdb, you must:

  1. Grow sdb1 to 3.6T (https://www.gnu.org/software/parted/manual/html_node/parted_31.html)
  2. reboot
  3. pvresize /dev/bcache0
  4. lvextend /dev/VolGroup00/root /dev/bcache0
  5. resize2fs /dev/VolGroup00/root

Cheers!

  • The "Parted". Use "resize" command it say "Error: The resize command has been removed in parted 3.0". I need to use "resizepart" command. – iHad 169 Jun 07 '21 at 11:42