The installer assumes systemd is there, I actually installed it, but still the postinstall script fails. Maybe a way to pass in not to install system service or manually start would be good workaround.
Error message:
New default version is 2.1.0p1.cfe.
Installing systemd service: omd.init
Disabling startup through SysV (/etc/init.d/*) scripts
Activating startup during system boot
System has not been booted with systemd as init system (PID 1). Can’t operate.
Failed to connect to bus: Host is down
dpkg: error processing package check-mk-free-2.1.0p1 (–configure):
installed check-mk-free-2.1.0p1 package post-installation script subprocess returned error exit status 1
Setting up samba-common-bin (2:4.15.5~dfsg-0ubuntu5) …
Checking smb.conf with testparm
Load smb config files from /etc/samba/smb.conf
Loaded services file OK.
Weak crypto is allowed
If you want to run the CMK inside WSL 2, i would recommend to use the Docker image.
For my dev system it looks like WSL 2 with running Ubuntu as distri and there inside the Docker CE.
As it is not possible to start these services with the system start as there is no systemd i use the “/etc/wsl.conf” with the following entry.
[boot]
command = service docker start
With this setting i can start my dev container with running CMK with an easy “code .” inside the dev container folder.
Shell from inside WSL 2
~> cd cmk_dev/checkmk_template/
~/c/checkmk_template (master)> code-insiders .
Updating VS Code Server to version acb156d6fb0dc451f427748d5f68774f17cc96fd
Removing previous installation...
Installing VS Code Server for x64 (acb156d6fb0dc451f427748d5f68774f17cc96fd)
Downloading: 100%
Unpacking: 100%
Unpacked 2377 files and folders to .../.vscode-server-insiders/bin/acb156d6fb0dc451f427748d5f68774f17cc96fd.
~/c/checkmk_template (master)> dpkg -l | grep ii | grep docker
ii docker-ce 5:20.10.16~3-0~ubuntu-focal amd64 Docker: the open-source application container engine
ii docker-ce-cli 5:20.10.16~3-0~ubuntu-focal amd64 Docker CLI: the open-source application container engine
ii docker-ce-rootless-extras 5:20.10.16~3-0~ubuntu-focal amd64 Rootless support for Docker.
ii docker-scan-plugin 0.17.0~ubuntu-focal amd64 Docker scan cli plugin.
~/c/checkmk_template (master)> docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
ec730d62e71f vsc-checkmk_template-e9f84f514c3090c733e7539b9ef74805-uid "/bin/sh -c 'echo Co…" 7 days ago Up 53 seconds (health: starting) 5000/tcp, 6557/tcp bold_ellis
ec02d9acc985 portainer/portainer-ce:latest "/portainer" 13 days ago Up About a minute 8000/tcp, 9443/tcp, 0.0.0.0:3040->9000/tcp, :::3040->9000/tcp portainer
The “bold_ellis” container is the CMK running after starting it with the start of the vscode environment.
You can also start such a container automatically after starting the WSL. But it will not autostart with the start of you Windows system without implementing some type of start script from Windows side.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed. Contact an admin if you think this should be re-opened.