[dm-crypt] Luks resizing error
ditisnietmijnnaam at yahoo.com
Fri Sep 6 04:10:27 CEST 2013
I tried to shrink a luks partition using these instructions: http://unix.stackexchange.com/questions/41091/how-can-i-shrink-a-luks-partition-what-does-cryptsetup-resize-do
but it failed.
in the answer on that page it gives the following commands:
# parted /dev/sda2
(parted) rm 2
(parted) mkpart Everything 250035s 124844158s
this last command failed with me:
Instead of a name (Everything) the mkpart command wanted (extended/primary).
So I made the partition the way I remembered them to be.
gparted now shows : http://i998.photobucket.com/albums/af104/ditisnietmijnnaam/gparted_zps85ed6ad9.png
when I rebooted, I got this error: alert /dev/mapper/vg-mint-root does not exist dropping to shell
(I cant the remember the exact message and names, so it might be off a little)
Using an ubuntu live usb I could get some following information.
The luks authentication seems to be working:
~$ sudo cryptsetup luksOpen /dev/sda5 partName
Enter passphrase for /dev/sda5:
~$ sudo cryptsetup status partName
/dev/mapper/partName is active.
keysize: 512 bits
offset: 4096 sectors
size: 1743302656 sectors
There was a (fully updated) linux mint 15 installation on that partition.
Can any of it be recovered?
Thanks in advance and best regards,
P.S. some extra info:
sda3 in the picture did not exist; the mint partition covered the entire hard drive.
I wanted to shrink it to install windows beside my main OS.
sda3 now temporarily has ubunt 13.04 installed on it.
More information about the dm-crypt