Skip to content

Commit

Permalink
dtprobed: make sure the daemon is started in the first place
Browse files Browse the repository at this point in the history
The work done earlier only suffices to restart the daemon automatically on
upgrade.  There appears to be no attempt to start newly-installed daemons at
a distro level, only to enable them (via presets).  Most daemons already in
the distro don't bother, apparently relying on the post-installation reboot
to start them.

We'd rather do the job right, so explicitly do a start in %posttrans (which
it looks like will usually be late enough that the thing will already have
been enabled even if presets don't do the job -- we have no way of running
later other than hooking into at jobs or something, at any rate.)

Signed-off-by: Nick Alcock <nick.alcock@oracle.com>
Reviewed-by: Kris Van Hees <kris.van.hees@oracle.com>
  • Loading branch information
nickalcock authored and kvanhees committed Mar 9, 2024
1 parent c337ff9 commit de65d31
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions dtrace.spec
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,12 @@ fi
%udev_rules_update
%systemd_postun_with_restart dtprobed.service

%posttrans
# Make sure the daemon really is started (OL9 doesn't start the
# daemon properly on fresh installations -- all presets do is enable
# it, not start it, and postun_with_restart only restarts on *upgrade*.)
systemctl start dtprobed || :

%files
%defattr(-,root,root,-)
%{_libdir}/dtrace
Expand Down

0 comments on commit de65d31

Please sign in to comment.