21.01.2019 0:17, Carlos E. R. пишет:
On 20/01/2019 20.15, Andrei Borzenkov wrote:
20.01.2019 22:11, Matthias Bach пишет:
...
Please post output of
dmsetup table
on system where you see "working" discard. I suspect this is false positive.
I'm getting curious. I have two machines in which home is encrypted and on SSD disks. Using that command I get:
Laptop with encrypted home on SSD:
Legolas:~ # dmsetup table cr_sda8: 0 976746496 crypt aes-xts-plain64 0000000000000000000000000000000000000000000000000000000000000000 0 8:8 4096 Legolas:~ #
Small server with encrypted home on mSATA SSD
sengard:~ # dmsetup table ... ... cr_home: 0 146798592 crypt aes-xts-plain64 0000000000000000000000000000000000000000000000000000000000000000 0 8:5 4096 ... Isengard:~ #
Discard is not active.
The log has entries like this:
# grep -i "discard|trim" /var/log/messages
small server:
...
<3.6> 2018-12-26 11:05:47 Legolas fstrim 1134 - - /: 19.3 GiB (20749635584 bytes) trimmed <3.6> 2018-12-26 11:05:47 Legolas systemd 1 - - Started Discard unused blocks. <3.6> 2019-01-02 03:26:37 Legolas systemd 1 - - Starting Discard unused blocks... ...
Laptop:
<3.6> 2018-12-30T22:58:51.181568+01:00 Isengard btrfsmaintenance-refresh-cron.sh 973 - - Refresh timer btrfs-trim for weekly <3.6> 2018-12-31T00:00:03.446660+01:00 Isengard systemd 1 - - Starting Discard unused blocks... <3.6> 2018-12-31T00:01:41.548922+01:00 Isengard fstrim 6391 - - /: 2.6 GiB (2778935296 bytes) trimmed <3.6> 2018-12-31T00:01:41.551418+01:00 Isengard systemd 1 - - Started Discard unused blocks. ...
I don't have entries on /etc/crypttab or fstab about discard or trim.
please show lslbk --discard on both systems.
Should I?
I guess it is up to you - whether you want to actually use TRIM or not.