Incompatibilidade de contagem do setor da unidade mapeada LUKS / ext4 após resize2fs

1

Depois de usar e2resize e reparticionar um ext4 fs dentro de um container luks, estou obtendo alguns resultados peculiares:

# e2fsck /dev/mapper/a 
e2fsck 1.44.1 (24-Mar-2018)
The filesystem size (according to the superblock) is 356487715 blocks
The physical size of the device is 356487205 blocks
Either the superblock or the partition table is likely to be corrupt!
Abort<y>? yes

# fdisk -l /dev/sdc
Disk /dev/sdc: 2.7 TiB, 3000558944256 bytes, 732558336 sectors
Units: sectors of 1 * 4096 = 4096 bytes
Sector size (logical/physical): 4096 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0xe520dd91

Device     Boot     Start       End   Sectors  Size Id Type
/dev/sdc1             256 356487972 356487717  1.3T 83 Linux


Disk /dev/mapper/a: 1.3 TiB, 1460171591680 bytes, 356487205 sectors
Units: sectors of 1 * 4096 = 4096 bytes
Sector size (logical/physical): 4096 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes

O redimensionamento do sistema de arquivos novamente não funciona:

# e2fsck -f /dev/mapper/a 
e2fsck 1.44.1 (24-Mar-2018)
The filesystem size (according to the superblock) is 356487715 blocks
The physical size of the device is 356487205 blocks
Either the superblock or the partition table is likely to be corrupt!
Abort<y>? no
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/mapper/a: 145786/89128960 files (4.8% non-contiguous), 354794507/356487715 blocks

# resize2fs /dev/mapper/a 
resize2fs 1.44.1 (24-Mar-2018)
Resizing the filesystem on /dev/mapper/a to 356487205 (4k) blocks.
resize2fs: Attempt to read block from filesystem resulted in short read while trying to resize /dev/mapper/a
Please run 'e2fsck -fy /dev/mapper/a' to fix the filesystem
after the aborted resize operation.

De alguma forma, a contagem do setor da unidade mapeada é agora menor que a do fs? A diferença é pouco menor que 2MB (2MB é o tamanho do cabeçalho luks, acredito?)

Como é agora, não consigo montar o fs. Mas se eu passar pelo e2fsck ele não reportará erros.

Então, onde está esse comprimento definido. Alguém pode mudar isso de alguma forma para o valor "correto"?

    
por lash 24.04.2018 / 15:30

0 respostas