GPARTED not letting me shrink partition on encrypted drive
by blooperx3 from LinuxQuestions.org on (#5B7NN)
I opened the luks encrypted drive and then tried it. I used fdisk to add 2 partitions and then tried it again on the non-encrypted partition, but get same error message:
Code:GPARTED NOT WORKING SHRINK PARTITION
GParted 0.32.0 --enable-libparted-dmraid --enable-online-resize
Libparted 3.2
Shrink /dev/sda1 from 5.46 TiB to 1.91 TiB 00:06:11 ( ERROR )
calibrate /dev/sda1 00:00:00 ( SUCCESS )
path: /dev/sda1 (partition)
start: 2048
end: 11721043967
size: 11721041920 (5.46 TiB)
encryption path: /dev/mapper/three
check file system on /dev/mapper/three for errors and (if possible) fix them 00:00:29 ( SUCCESS )
e2fsck -f -y -v -C 0 '/dev/mapper/three' 00:00:29 ( SUCCESS )
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
11 inodes used (0.00%, out of 91586560)
0 non-contiguous files (0.0%)
0 non-contiguous directories (0.0%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 2/1
6061281 blocks used (0.83%, out of 732667904)
0 bad blocks
1 large file
0 regular files
2 directories
0 character device files
0 block device files
0 fifos
0 links
0 symbolic links (0 fast symbolic links)
0 sockets
------------
2 files
e2fsck 1.44.5 (15-Dec-2018)
shrink file system 00:05:41 ( SUCCESS )
resize2fs -p '/dev/mapper/three' 2047983616K 00:05:41 ( SUCCESS )
Resizing the filesystem on /dev/mapper/three to 511995904 (4k) blocks.
Begin pass 2 (max = 204801)
Relocating blocks XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Begin pass 3 (max = 22360)
Scanning inode table XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
The filesystem on /dev/mapper/three is now 511995904 (4k) blocks long.
resize2fs 1.44.5 (15-Dec-2018)
shrink encryption volume 00:00:01 ( ERROR )
cryptsetup -v --size 4095967232 resize 'three' 00:00:01 ( ERROR )
Command failed with code -1 (wrong or missing parameters).
Nothing to read on input.
========================================


Code:GPARTED NOT WORKING SHRINK PARTITION
GParted 0.32.0 --enable-libparted-dmraid --enable-online-resize
Libparted 3.2
Shrink /dev/sda1 from 5.46 TiB to 1.91 TiB 00:06:11 ( ERROR )
calibrate /dev/sda1 00:00:00 ( SUCCESS )
path: /dev/sda1 (partition)
start: 2048
end: 11721043967
size: 11721041920 (5.46 TiB)
encryption path: /dev/mapper/three
check file system on /dev/mapper/three for errors and (if possible) fix them 00:00:29 ( SUCCESS )
e2fsck -f -y -v -C 0 '/dev/mapper/three' 00:00:29 ( SUCCESS )
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
11 inodes used (0.00%, out of 91586560)
0 non-contiguous files (0.0%)
0 non-contiguous directories (0.0%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 2/1
6061281 blocks used (0.83%, out of 732667904)
0 bad blocks
1 large file
0 regular files
2 directories
0 character device files
0 block device files
0 fifos
0 links
0 symbolic links (0 fast symbolic links)
0 sockets
------------
2 files
e2fsck 1.44.5 (15-Dec-2018)
shrink file system 00:05:41 ( SUCCESS )
resize2fs -p '/dev/mapper/three' 2047983616K 00:05:41 ( SUCCESS )
Resizing the filesystem on /dev/mapper/three to 511995904 (4k) blocks.
Begin pass 2 (max = 204801)
Relocating blocks XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Begin pass 3 (max = 22360)
Scanning inode table XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
The filesystem on /dev/mapper/three is now 511995904 (4k) blocks long.
resize2fs 1.44.5 (15-Dec-2018)
shrink encryption volume 00:00:01 ( ERROR )
cryptsetup -v --size 4095967232 resize 'three' 00:00:01 ( ERROR )
Command failed with code -1 (wrong or missing parameters).
Nothing to read on input.
========================================