<div dir="ltr">Hi folks,<div><br></div><div>I learned that [Install] section in a drop-in is not respected. This behavior is documented, but I failed to see *why*.</div><div><br></div><div>I found this related GitHub issue: <a href="https://github.com/systemd/systemd/issues/1774">https://github.com/systemd/systemd/issues/1774</a>, and here is the quote from "poettering commented on 5 Nov 2015":</div><div><br></div><div>> Well, this has been requested before, but generally, install info is something that is provided by the unit file vendor in the unit files. drop-ins and symlinks in /etc are user extensions however. "systemctl enable" is for applying that install info to /etc. It would be contradictory to use user configuration to create user configuration though. Hence we do not respect install info in drop-ins.</div><div><br></div><div>However, I don't think it's contradictory since drop-ins are not always user configuration. For "s.service", the drop-ins in /usr/lib/systemd/system/s.service.d/ and /var/run/systemd/generator/s.service.d/ are respected, but they are not user configurations.</div><div><br></div><div>For example, one can create a package that includes 2 things:</div><div><br></div><div>1. a target unit called "remote-access.target"</div><div>2. a systemd generator that generates the following drop-ins for "sshd.service", "telnetd.service" and "vnc.service":</div><div><br></div><div>[Unit]</div><div>PartOf=remote-access.target<br></div><div><br></div><div>[Install]</div><div>WantedBy=remote-access.target</div><div><br></div><div>That way, after a user typed "systemctl enable sshd telnetd vnc", he/she can:</div><div><br></div><div>- systemctl start remote-access.target</div><div>- systemctl stop remote-access.target</div><div><br></div><div>to conveniently start/stop all remote access services.</div><div><br></div><div>In conclusion, I consider drop-ins as a way to enhance the original unit files. Just like [Unit], [Service] or any other sections, [Install] should be enhance-able too.</div><div><br></div><div>John</div></div>