[systemd-devel] systemd-way for initialization zram swap

Oleksii Shevchuk alxchk at gmail.com
Mon Nov 19 13:18:44 PST 2012


> 1. this service is kind of duplicating swap.target
> 2. echo inside duplicates things, which tmpfiles.d could do

Maybe. 

IMO semantically, you have new device, that should be configured
before use. It can appears after loading module. As for man 7 bootup,
there is no deps between early targets. So tmpfiles could start earlier
then zram device appears, and so on. I think separate service for device
configuration should be used anyway. 

> 3. service still based on some "internals" of swap.target - it doesn't
> do swaoff before ExecStop

I should add RefuseManualStart=/RefuseManualStop= to unit


More information about the systemd-devel mailing list