Re: [dm-devel] dm-era over mdadm raid5 loses discard support

2021-11-19 Thread vitalif
Hi Just to note, the problem is solved by setting raid456.devices_handle_discard_safely=Y in kernel command line. It seems that dm-table.c checks for blk_queue_discard() of underlying devices and RAID5 device has the QUEUE_FLAG_DISCARD unset and at the same time discard_granularity != 0. So di

Re: [dm-devel] dm-era over mdadm raid5 loses discard support

2021-11-19 Thread vitalif
Even worse, dm-linear has the same problem. dm-linear over mdadm RAID5 doesn't support discard while mdadm device itself supports it. > Hi! > > A dm-era device created over a RAID5 array loses discard support. > > Test script is attached. > > If you run it on SSD you'll see something like: >

[dm-devel] dm-era over mdadm raid5 loses discard support

2021-11-19 Thread vitalif
Hi! A dm-era device created over a RAID5 array loses discard support. Test script is attached. If you run it on SSD you'll see something like: loop0 4096 loop1 4096 loop2 4096 loop3 4096 md55 1048576 loop_test_era 0 I.e. mdadm device supports discard, but dm-era device started over it doesn't.