BMitch is right. Docker has nothing to do with runlevels, it will never change a runlevel. But there is more.
runlevel
unknown
is common on some systems running systemd
. Your question is tagged with Debian though, and Debian Jessie (the latest Debian release, which uses systemd, uses compatibility script to print a runlevel). Arch based distros, and the unstable RedHat based distros (e.g. Fedora) print unknown
when executing runlevel
, i.e. they do not even care to print a fake runlevel.
If you check your runlevel script you will get the following output on a recent distro:
$ ls -l $(which runlevel)
lrwxrwxrwx 1 root root 9 Jun 18 14:44 /usr/bin/runlevel -> systemctl
(that is on arch, runlevel
is in /usr/sbin
on Debian, but it also points to systemctl
on Debian)
The runlevel
script points to sysemtd
control on most recent distros.
In general runlevel
has no meaning on recent distros (because of systemd
to which pretty much everyone switched to). If you look inside the /etc/rc.d/rc*.d/
directories, they're almost empty.
What is actually defining how init
processes the system boot is the systemd default target, located here:
/lib/systemd/system/default.target
Or /etc/systemd/system/default.target
, if that exists.