Re: upgraded config files in /lib/systemd/system
- Date: Tue, 28 Feb 2017 18:20:49 +0100
- From: Sven Hartge <sven@xxxxxxxxxxxxx>
- Subject: Re: upgraded config files in /lib/systemd/system
Marc Auslander <marcslists@xxxxxxxxx> wrote:
> Dominique Dumont <dod@xxxxxxxxxx> writes:
>> On Tuesday, 28 February 2017 14:01:18 CET Harald Dunkel wrote:
>>> short question about /lib/systemd/system: AFAICS the config
>>> files here are supposed to be overridden by local config files
>>> in /etc/systemd/system, using the same path, as described in
>>> How can I make sure that there is a conflict dialog at upgrade
>>> time, if I have to modify the unit file shipped with my package?
>> I don't understand why a change in /lib/systemd/system should trigger a
>> conflict warning.
>> Either you have changed a value not modified by end user and there's no conflict
> IIRC in the "old" world, if you had a modified version of a config
> file and an update modified the original released version, you got a
> warning and a dialog which let you decide how to proceed.
> The question is whether or not you will get such a warning using the
> described method of modifying a config file by publishing a new
> version in the override directory.
If you copied the *whole* unit from /lib/systemd/system/foobar.service
to /etc/systemd/system/foobar.service, then you have been using the
override system the wrong way.
The correct (and documented) way is to
1) create /etc/systemd/system/foobar.service.d/
2) put your overrides and *only* your overrides into
Or, starting with Stretch, you can just do "systemctl edit
foobar.service" and it will do the right thing for you.
Sigmentation fault. Core dumped.