sytemd vs init.d question

I’m currently bringing up a memcached server (had to compile from source, not included in suse12) and I’m trying to add the newrelic plugin to monitor.

Everything is installed, I have memcache set up as a systemd service, runs fine, but the newrelic plugin is java based and has a init.d script.

Now if I run the init.d script /etc/init.d/newrelic_plugin_memcached it runs just fine. But if I try to run the same script using service or systemctl is fails to start.

Isn’t there a line I can add to a init.d script so the the system just runs the script as it should ? very frustrating.
I’ve also looked at other init.d scripts and I’ll be damed if I can see why one script works fine through service and others don’t in this new systemd setup.

Differences: I’d check the top of the init scripts to see if anything
stands out there. Does ‘chkconfig -l’ show either of them, or both of
them? Have you considered creating a systemd service configuration file
instead of trying to use the sys-V init script?


Good luck.

If you find this post helpful and are logged into the web interface,
show your appreciation and click on the star below…

No unfortunately - nothing stands out in the script format.

The biggest difference is this. In the ones that do work ok through systemd they all call a actual program.

This script calls this: sudo -u root java -Xmx128m “-Dnewrelic.platform.config.dir=/opt/newrelic-npi/plugins/com.newrelic.plugins.memcached/newrelic_memcached_plugin-2.0.1/config” -jar “/opt/newrelic-npi/plugins/com.newrelic.plugins.memcached/newrelic_memcached_plugin-2.0.1/plugin.jar” >> $DAEMONDIR/daemon.log 2>&1 &

don’t if this makes a difference - not even sure if this command is even possible in a service file.