Post 9m2Nug1fIGAXzdCTSK by jeeger@mastodon.social
(DIR) More posts by jeeger@mastodon.social
(DIR) Post #9lwpF5wIBp9py2t7ui by amolith@masto.nixnet.xyz
2019-08-16T15:28:38Z
0 likes, 0 repeats
If I hadn't taken a snapshot of my server before attempting to resize partitions, it would be in flames right now :blobsweats: Does anyone have experience resizing a LUKS-encrypted partition without LVM? I used fdisk and deleted sda2 (extended) and sda5 (logical), remade them filling the whole disk while making sure the beginning block for sda5 was the same, used cryptsetup to resize the luks volume, then ran e2fsck on /dev/mapper/cryptdisk to verify that things were ok. Things were not ok 😢 resize2fs didn't work for extending the filesystem either.
(DIR) Post #9m2Nug1fIGAXzdCTSK by jeeger@mastodon.social
2019-08-19T07:50:40Z
0 likes, 0 repeats
@amolith this process (without the partition deletion and moving) worked for me a few years back.
(DIR) Post #9m2m10vksgr9StzTeK by amolith@masto.nixnet.xyz
2019-08-19T12:20:46Z
0 likes, 0 repeats
@jeeger It may be something weird that happened with my process. I'm going to try again sometime this afternoon with gparted instead of fdisk and see if it handles things any better.
(DIR) Post #9m30bmV4tUmKmcwG92 by jeeger@mastodon.social
2019-08-19T15:04:17Z
0 likes, 0 repeats
@amolith I *think I used gparted, but I could be wrong.
(DIR) Post #9mAXeicNiJjGQFfMeG by kot@mastodon.social
2019-08-23T06:17:33Z
0 likes, 0 repeats
@amolithIt's safer and faster to just back up the data, recreate the partition, and restore the data, than to resize a partition, whether encrypted or not. (Unless you're just increasing a partition size into empty space following it.) You can create a LUKS encrypted partition by hand with these instructions (no LVM involved): http://dpaste.com/00S3N1N