The officially official Devuan Forum!

You are not logged in.

#1 Re: Installation » An interesting attempt to modify init->openrc-init » 2026-09-21 10:42:11

I don't understand how to quote or reply
Do not see an action button similar to @who, So I copied the original text directly:

[I believe that this can be handled via dpkg-divert?]

1.
Thanks for the reply
I read the dpkg-divert manual/etc/init.d/*as confiles
Say it may not be reliable

Maybe I can use a different name for service such as xxx-openrc(openrc) vs xxx(sysv)

[Isn't this problem already covered by the "orphan-sysvinit-scripts" package?]

2.There are fewer and fewer people maintaining sysv, so I still don't feel at ease. In addition,I Want to make an pure  openrc style devuan to play haha for fun

#2 Re: Installation » An interesting attempt to modify init->openrc-init » 2026-09-19 14:01:59

I have currently packaged this and written a script to automate the operations described above. I also modified some services from the original `initscripts` to use the OpenRC format, mainly by adding `depend()` functions and virtual dependencies. They can run and work properly.
However, I cannot think of a good way to handle the following issue: if `initscripts` or other software is upgraded or updated, it may overwrite my scripts with the newer versions. Copying the many OpenRC service files from Alpine may also be difficult to manage.

#3 Installation » An interesting attempt to modify init->openrc-init » 2026-09-15 03:35:13

alin
Replies: 5

# Using OpenRC-init  as pid=1

Inspired by this [https://laskarnix.org/devuan-migrate-fr … enrc-init/], I tried the following approach on Devuan.

## 1. Create an empty package to replace `sysvinit-core`

I created an empty package named `openrc-init` with the following control information:

```text
Conflicts: sysvinit-core
Replaces: sysvinit-core
Provides: sysvinit-core
Depends: openrc
```

After installing this package, `sysvinit-core` is removed from the system.

## 2. Use `openrc-init` as PID 1

Create a symlink that points `/sbin/init` to the `openrc-init` provided by OpenRC:

```sh
ln -sf /sbin/openrc-init /sbin/init
```

I also created the `poweroff` and `reboot` commands.

### `poweroff`

```sh
#!/bin/sh
exec /sbin/openrc-shutdown -p 0
```

### `reboot`

```sh
#!/bin/sh
exec /sbin/openrc-shutdown -r 0
```

## 3. Create and enable TTY services

Create `agetty` service links for `tty1` through `tty6`, then add them to the default runlevel:

```sh
for n in $(seq 1 6); do
    ln -s agetty "agetty.tty$n"
    rc-update add "agetty.tty$n" default
done
```

The system was able to boot normally. 👍

## Idea

As more and more Debian packages remove support for SysV service scripts in the future, it may be possible to build a Devuan distribution centered around OpenRC without extensively modifying or rebuilding upstream Debian packages.

The general approach could be:

- Reuse upstream Debian SysV service scripts whenever they are still available, reducing maintenance work;
- When a service no longer has a usable SysV script, obtain an appropriate OpenRC service script from Gentoo or Alpine Linux;
- Provide a compatibility layer or adaptation mechanism so that existing Debian packages can continue to work in an OpenRC environment;
- Minimize modifications to upstream packages in order to reduce long-term maintenance costs.

In this way, Devuan could preserve the Debian package ecosystem while gradually building a more complete and independent initialization and service-management system centered around OpenRC.

Board footer

Forum Software