← Back to team overview

launchpad-users team mailing list archive

System has not been booted with systemd as init system (PID 1). Can't operate.

 

Hello list,

I am having difficulties running my package's unit tests in the
Launchpad builders for all architectures. Some of my unit tests require
the spawning of (user) systemd service units.

After many hours of trying to get them to start with elusive error
messages, I seem to have located the problem after prepending
`systemctl status` to my override_dh_auto_test hook in d/rules.

   System has not been booted with systemd as init system (PID 1). Can't operate.

I figured this might be due to the Launchpad builders running inside of
a chroot where systemd needs to be PID=1, but isn't. So I verified by
prepending in the above with a call to ps -p 1.

   PID TTY          TIME CMD
   1 ?        00:00:01 systemd

So it does appear to have been started at boot, and with PID=1. Or
perhaps that is the host's instance of systemd and not the chroots?

Is there something I need to do, perhaps set an environment variable,
add something to my Build-Depends, or execute something before running
the unit tests?

Yours truly,

-- 
Kip Warner
OpenPGP signed/encrypted mail preferred
https://www.thevertigo.com

Attachment: signature.asc
Description: This is a digitally signed message part


Follow ups