Re: [qubes-users] Startup/Shutdown thin pool trim - where to insert with systemd?
brendan.h...@gmail.com: > If fedora were still running init, I'm pretty sure I could find the right > place to do this, but with systemd, I am quite discombobulated. Perhaps that is the "do one thing, and do it well" systemd strives for. > 1. Where/how do I insert a thin_trim of the qubes_00 pool during startup > when it's available (e.g. after luks volume is mounted) but before the pool > is activated? How do I do it safely (ensuring that activation only occurs > on exit of thin_trim)? Maybe /lib/systemd/system/lvm2-pvscan@.service? I see a /lib/systemd/system/lvm2-pvscan@.service.d/30_qubes.conf too. > 2. Where/how do I insert a thin_trim of the qubes_00 pool during shutdown > after it is deactivated but before the luks volume (the VG) is dismounted? Possibly the ExecStop in the first file. -- - don't top post Mailing list etiquette: - trim quoted reply to only relevant portions - when possible, copy and paste text instead of screenshots -- You received this message because you are subscribed to the Google Groups "qubes-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to qubes-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/qubes-users/937ef057-f876-121f-6e12-a4aafad1ea91%40danwin1210.me.
[qubes-users] Startup/Shutdown thin pool trim - where to insert with systemd?
Hi folks [ calling @tasket !] I'd like to have the system perform a thin_trim command across the primary thin pool on Qubes startup and shutdown. The purpose would be opportunistic erasure of deleted volumes in the pool (say, if they were removed without blkdiscard being run against them first). I have already activated passdown through the luks layer and enabled discards on the hardware. As the documentation tells us, thin_trim can only be safely invoked before the pool is activated or after the pool is successfully deactivated. If fedora were still running init, I'm pretty sure I could find the right place to do this, but with systemd, I am quite discombobulated. >From the documentation I know that as part of the automatic lvm scanning and activating of autodiscovered lvm VGs/volumes/pools that thin_check is automatically run on startup before activating volumes (though that might be internal and therefore controlled via lvm.conf). So... 1. Where/how do I insert a thin_trim of the qubes_00 pool during startup when it's available (e.g. after luks volume is mounted) but before the pool is activated? How do I do it safely (ensuring that activation only occurs on exit of thin_trim)? 2. Where/how do I insert a thin_trim of the qubes_00 pool during shutdown after it is deactivated but before the luks volume (the VG) is dismounted? Brendan -- You received this message because you are subscribed to the Google Groups "qubes-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to qubes-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/qubes-users/f1ae53ba-d942-4f0c-b6f5-599eee544593%40googlegroups.com.