Hide Forgot
Description of problem:pcp uses several legacy init scripts /etc/rc.d/init.d/pcp /etc/rc.d/init.d/pmcd /etc/rc.d/init.d/pmie /etc/rc.d/init.d/pmlogger /etc/rc.d/init.d/pmproxy /etc/rc.d/init.d/pmwebd Version-Release number of selected component (if applicable):pcp-3.8.6-2.el7.x86_64.rpm How reproducible:100% Steps to Reproduce: 1.install pcp 2.look for systemd services 3.find legacy init scripts Actual results: legacy init scripts Expected results: system unit files with relevant dependencies set Additional info:
Quick status update on this one, I'd forgot to make a note here. An initial investigation was done a little while ago into switching over to native systemd daemon startup mechanisms, rather than the existing init script mechanism. There are a couple of complications which make this not a straight/simple swap, but I believe they are solvable. Firstly, two of the init scripts (pmlogger, pmie) do not have a one-script-one-daemon mapping - in a distributed monitoring situation, they may have been configured to start multiple daemons for multiple remote hosts. I think I know how to tackle this now with systemd, but this had me confused/stumped for awhile. Second, some of the scripts have before-hand-scripting that needs to be run before the daemon is started - I also was unsure how to tackle this before, but there appears to be multiple options here on closer examination. These two specific issues aside, the biggest remaining problem is the testsuite. This contains several hundred tests, many of which make use of the existing init scripts directly. This will need to be audited, and the scripts modified to conditionally use the systemd daemon startup command variants for platforms like RHEL7 & current Fedora (but not RHEL6 and earlier Fedoras, or the many other platforms PCP supports). So, there are no blockers to this work going ahead, and go ahead it will - it does have larger scope than one might initially anticipate, however.
Note that the degree of systemd support in this release is minimal: it wraps/hides the old sysvinit scripts as ExecStart/ExecStop oneshot invocations. A fuller solution would perhaps: - have the daemons use stderr/syslog to record trace output into the journal - invoke the daemons directly rather than through the sysvinit scripts - use systemd timer units instead of cron jobs - use unit templates for hard-configured multi-instance daemons (pmlogger, pmie) - socket activation for pmcd, pmproxy, pmwebd - add extras like Restart=restart-always for key daemons
Verified for build pcp-3.9.10-8.el7, with regard to degree of support mentioned in comment #15.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHBA-2015-0413.html