Re: Question regarding systemd service unit cleanup

2019-10-17 Thread Michal Schorm
Hello, Can you specify which packages are the A & B? I wanted to reproduce the initial situation - that the service requiring another will put a symlink to the "/usr/lib/systemd/system". I forged iptables RPM containing service file mentioning "Requires=firewalld.service" to see the link to be cr

Re: Question regarding systemd service unit cleanup

2019-10-11 Thread Ravindra Kumar via devel
> You need something like this in a scriptlet: > if systemctl is-enabled A; systemctl reenable A; done > > This will remove the old links and create the new ones. Thanks Zbigniew for the idea. It seemed very promising and I tried it. Unfortunately, it still did not help because "reenable" command

RE: Question regarding systemd service unit cleanup

2019-10-11 Thread Ravindra Kumar via devel
> systemctl daemon-reload? Thanks Dridi. I had forgotten to mention that I had tried daemon-reload and that did not help. > Isn't this handled automatically by the %systemd scriptlets? %systemd_post macro is a no-op for upgrade case - https://github.com/systemd/systemd/blob/master/src/core/mac

Re: Question regarding systemd service unit cleanup

2019-10-08 Thread Zbigniew Jędrzejewski-Szmek
On Wed, Oct 09, 2019 at 06:04:39AM +, Dridi Boukelmoune wrote: > On Tue, Oct 8, 2019 at 6:45 PM Ravindra Kumar via devel > wrote: > > > > Hi, > > > > > > > > I have removed dependency on service B from service A and all references to > > service B. The new package works well for fresh install

Re: Question regarding systemd service unit cleanup

2019-10-08 Thread Dridi Boukelmoune
On Tue, Oct 8, 2019 at 6:45 PM Ravindra Kumar via devel wrote: > > Hi, > > > > I have removed dependency on service B from service A and all references to > service B. The new package works well for fresh install (service A can be > started normally), but it does not work for upgrades from previ