[systemd-devel] Nested systemd
Mantas Mikulėnas
grawity at gmail.com
Mon Dec 11 21:33:53 UTC 2017
On Mon, Dec 11, 2017 at 10:14 PM, Boyce, Kevin P [US] (AS) <
Kevin.Boyce at ngc.com> wrote:
> Good Afternoon List,
>
>
>
> I have a question regarding the use of systemd. I would like to know if
> it is possible to have two instances of system running at a time?
>
>
>
> For instance I have an application that has a very complicated set of
> startup procedures. It runs on linux. I was considering using an instance
> of systemd with some custom unit files and targets as a self-contained
> startup procedure. I was wondering if systemd could then start this
> systemd instance using an alternate root directory?
>
Your description sounds almost exactly like what containers
(systemd-nspawn, LXC, Docker) are normally used for – including both the
nested init system and the alternate root directory. Systemd should work
just fine when used as a container init process.
But beyond that, systemd only supports *one* "system mode" instance per
system – that is, PID 1.
(It *does* support unprivileged "user mode" instances of `systemd --user`,
limited to one per UID, but I'm not sure if these are suitable for
"complicated startup procedures" in your case.)
--
Mantas Mikulėnas <grawity at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/systemd-devel/attachments/20171211/518b4b76/attachment.html>
More information about the systemd-devel
mailing list