You are not logged in.
Hi guys,
What I've got is a Thinkpad T430S with a Samsung 830 SSD (256GB) and a freshly installed Arch Linux with full disk encryption using dmsetup and luks and lvm. My problem is that the discard option does not get to the SSD, i.e.:
[root@fxt felix]# dmsetup table /dev/mapper/vg_ssd --showkeys
0 498864128 crypt aes-xts-plain64 a69bc848d82fe86fremovedtherest 0 8:2 4096
There's no discard option shown.
My fstab looks like this:
[root@fxt felix]# cat /etc/fstab
# UUID=bea14846-2b3c-417a-b300-35aeb0e52cd0
/dev/mapper/vg_ssd-lv_root / ext4 discard,rw,relatime,data=ordered 0 1
# UUID=63152aae-d333-4b26-a7c2-dd52703ac8df
/dev/mapper/vg_ssd-lv_home /home ext4 discard,rw,relatime,data=ordered 0 2
# UUID=F230-3FA0
/dev/sda1 /boot vfat rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro,discard 0 2
My crypttab like this: (removed the comments)
[root@fxt felix]# cat /etc/crypttab
vg_ssd UUID=e127d5e0-6090-4d9d-ba07-3c22de1c76c6 none luks,allow-discards
I guess I need to mention that after I set up Arch with encryption did not have anything added to crypttab myself and in fact it was empty. Still, the startup and encryption worked just fine. I just added this line to the crypttab because that's what according to several blog entries was required. Any help is appreciated! :-)
Last edited by felikz (2013-09-10 10:43:05)
Offline
okay, I was able to solve this by adding the allow-discards also to the GRUB config file:
vi /etc/default/grub
before
GRUB_CMDLINE_LINUX_DEFAULT="cryptdevice=/dev/sda2:vg_ssd"
afterwards
GRUB_CMDLINE_LINUX_DEFAULT="cryptdevice=/dev/sda2:vg_ssd:allow-discards"
Now dmsetup shows this :-)
[root@fxt felix]# dmsetup table /dev/mapper/vg_ssd --showkeys
0 498864128 crypt aes-xts-plain64 a69bc8removedtherest 0 8:2 4096 1 allow_discards
Last edited by felikz (2013-09-10 09:38:19)
Offline