-
Notifications
You must be signed in to change notification settings - Fork 586
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
System has not been booted with systemd as init system (PID 1). Can't operate #457
Comments
Instead of using |
The same is not working when trying to start mongodb service. |
@imdpkmr are you trying to use |
I have also faced the same issue when I'm using the Instead of that, I had used the |
I also face the same issue with postgresql. do you have any idea how to solve it? thanks |
@ZhengxunWu Try the command |
problem solved. |
Some services like docker (standalone, ubuntu version, installed using bash) still might not run even if you use What you have to do is, run the linux subsystem as administrator by right clicking from start menu. |
May I ask is there suggested command for |
Also one for |
Can not start service of firewalld (WSL Ubuntu 18.04.3 LTS)$ sudo service firewalld start
* Starting dynamic firewall daemon firewalld [ OK ]
$ sudo service firewalld status
* firewalld is not running there's no error, but it seems there should be... $ sudo firewall-cmd --list-ports
FirewallD is not running
$ sudo irewall-cmd --list-services
FirewallD is not running |
it
it works for me, run subsystem as administrator, and use 'sudo /etc/init.d/docker start'. |
I can't upgrade InfluxDB because part of the script in apt-get install influxdb results in an error determining the current runlevel. There are also a lot of other packages that just wont run. I'm going back to Hyper-V for the time being until you all get it worked out, ok? |
Hello, I have followed the steps to solve my problem however this has not worked for me. when I run |
when I run sudo /etc/init.d/docker start I get sudo: /etc/init.d/docker: command not found. What could I do in that case. same error for me |
Are you using the $ sudo dockerd |
I had this problem running WSL 2 the solution was the command
Open other terminal and try it
if after that you still have a problem with permission, run the command:
|
@felipementel Your answer is the most near to solve my problem. I can run docker commands but now I'm getting a "docker: Error response from daemon: OCI runtime create failed: container_linux.go:349: starting container process caused "process_linux.go:319: getting the final child's pid from pipe caused "EOF"": unknown. ERRO[0006] error waiting for container: context canceled". Could you help me with this? Thank you very much in advance for your help. |
Hi @TheTechOddBug ! So, tell me what are you doing to construction this error? |
it still showing /etc/init.d/docker: command not found. |
Well @felipementel, I upgraded my system to Windows 10 2004, enabled WSL2 and installed an Ubuntu distribution. I set WSL v2 as default. I installed docker inside that Ubuntu distribution and follow your comments to make docker commands work but when I try to run the hello-world simple container with docker run, I got the previously commented error. Again, thank you for your help! |
Thank you Felipe. It worked for me! |
Is there any equivalent to |
so how does docker help u fix issues with the System has not been booted with systemd as init system (PID 1), having same issue on kali linux wsl during the setup of openvas, when I do the openvas-setup or the openvas-check-setup gives me that and everything else is running. |
service is unrecognized in my scenario. |
For people looking for ways to enable services, I did find this and it was helpful to me https://github.com/shayne/wsl2-hacks/blob/master/README.md |
i did this with mongod but it said : sudo: /etc/init.d/mongod: command not found |
i used this for mongod but intead i got this error : mongod: unrecognized service |
again i got this error : sudo: /etc/init.d/mongod: command not found |
@Saurabhdaswant mongo doesn't include a /etc/init.d/mongod script by default. But here are docs on how to do this: |
I am having the same issue: Here after running Step 6: Install MongoDB packages: sudo apt-get install -y mongodb-org on my terminal and after running Step 10: Run a Mongo instance: sudo mongod --dbpath ~/data/db In a nutshell please help me with some valid resources or help to install mongodb on wsl2 and run it smoothly. PS:I ran with all helps from StackOverflow to github and dev , from changing ownerships to running init scripts but the So please look into this ! |
@thewackyindian @gaur-abhi524 Find here a script for the full installation of MongoDB 4.0 or 5.0 in WSL2, Ubuntu 20.04: |
System has not been booted with systemd as init system (PID 1). Can't operate. Am having this issue now in my termux 🤦🏽♂️🤦🏽♂️🤦🏽♂️ how can i solve this? |
Use:- docker container run -d --hostname --name privileged=true <image_name> /sbin/init |
If you wish to run systemctl, there is a way for it in WSL2. You can follow the gist https://gist.github.com/djfdyuruiry/6720faa3f9fc59bfdf6284ee1f41f950 |
For some reason, my WSL has not been updated to 2, and my windows build is 19043. Can anyone help me to know how I can do it? I have already tried to set the default version to 2, downloaded a new image, but it started on version 1. I already tried to convert an image to version 2, it says it will take a while, but it actully did nothing. |
It helped usage mongo on WSL2. Thank you! |
if you use wsl, at first please be sure you run docker windows and then try wsl for docker command |
March, 2022. Your answer helped me! Worked for me! |
这是来自QQ邮箱的假期自动回复邮件。
已收到
|
Thanks @craigloewen-msft ! |
这是来自QQ邮箱的假期自动回复邮件。
已收到
|
I have deployed a flask application on wsl 20.04.4, create the service under /etc/systemd/system but the command
start does not work |
How do we manage timezones in WSL 2 Ubuntu 22.04? $ Getting this error:
|
I was trying to install k3s on wsl and was running into this issue.... Simply execute /etc/init.d$ curl -sfL https://get.k3s.io | sudo bash - (from /etc/init.d ) and it works like magic!!! |
I can't start the snapd service also without systemctl. there is no init file in /etc/init.d directory so cant use /etc/init.d/snapd start. what can I do to start the snapd service in wsl2? |
try: update-alternatives --config iptables > type "1" > "enter" ==================== ┌──(root㉿darkside)-[~] Selection Path Priority Status*0 /usr/sbin/iptables-nft 20 auto mode Press to keep the current choice[*], or type selection number: 1 ######## RESTART WSL SERVICE ######## ┌──(root㉿darkside)-[~] Selection Path Priority Status0 /usr/sbin/iptables-nft 20 auto mode Press to keep the current choice[*], or type selection number: 1 ┌──(root㉿darkside)-[~] ┌──(root㉿darkside)-[~] ==================== |
DanielAKAOi that worked for me thank you |
I have the same problems recently, I update the
I also checked the process name of pid 1.
Although the process of pid 1 is not |
I've enabled systemd in WSL per https://learn.microsoft.com/en-us/windows/wsl/wsl-config instructions.
SOLVED: After running |
wsl --update solved allot of problems, networks: |
For people looking at this down the road: |
In Termux, I got this: |
Nice, but this doesn't work in Termux.p, unfortunately so. |
system:win10Pro-1903-18362.239
subLinux:ubuntu1804
when is input 【sudo systemctl start docker】but i can not start docker-daemon ,it show me
this:【System has not been booted with systemd as init system (PID 1). Can't
operate】
so,is i did wrong?
The text was updated successfully, but these errors were encountered: