Converting systemv to systemd? Using drbd as an example

Although at the moment I do understand that we are going through a transitional period where although systemd is likely the implemented subystem in most recent OS (12.2 currently), systemv init scripts are still supported. Looking towards the future, I’d still prefer to implement services management (eg start, stop, restart, priority) as much as possible using systemd.

But, am having some difficulty finding a clear description how to manually implement changes.

As often the case when I’m exploring something bleeding edge which may not yet be fully documented by openSUSE, I’ve started with what is available at theArch Wiki That link in turn links to a number of “common services” which might be enabled simply by

#systemctrl enable *servicename*

But, my current specific investigation is actually to configure drbd (Distributed Replicated Block Device).
The included man page currently describes the service as setup using systemv init scripts and indeed when I use locate to find all the files associated with drbd that appears to be true. It also looks like drbd an be simply enabled and started using Yast.

But, I find it interesting that although drbd appears to be already configured as an available “service” it cannot be simply enabled using the systemctl command (see above).

Looking for an explanation to further understand if a service would have to be configured differently to enable systemctl support?

TIA,
TSU

“systemctl enable” supports only native systemd units. systemd additionally supports native initscripts and displays “synthesized” status of them - for /etc/init.d/foo it pretends that foo.service unit exists, it is “enabled” if initscript is enabled by insserv/chkconfig and its status reflects current initscript running status. This is only compatibility, you are encouraged to create native units. If foo.service exists, then /etc/init.d/foo is ignored. This allows packages to natively support both systemd and initscripts.

On 2013-01-16 18:16, tsu2 wrote:
> As often the case when I’m exploring something bleeding edge which may
> not yet be fully documented by openSUSE,

Did you look at doc.opensuse.org? One of the books has a chapter on it.


Cheers / Saludos,

Carlos E. R.
(from 11.4, with Evergreen, x86_64 “Celadon” (Minas Tirith))