Skip to content
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

Cannot install mongodb #67

Open
roldengarm opened this issue Aug 25, 2024 · 0 comments
Open

Cannot install mongodb #67

roldengarm opened this issue Aug 25, 2024 · 0 comments

Comments

@roldengarm
Copy link

I'm trying to install mongodb, but am having trouble, as it seems neither init nor systemd are available.

I've got this as a script which installs mongodb fine.

sudo DEBIAN_FRONTEND=noninteractive apt-get install -y tzdata
sudo apt-get install -y gnupg curl
curl -fsSL https://www.mongodb.org/static/pgp/server-7.0.asc | sudo gpg -o /usr/share/keyrings/mongodb-server-7.0.gpg --dearmor
echo "deb [ signed-by=/usr/share/keyrings/mongodb-server-7.0.gpg ] http://repo.mongodb.org/apt/debian bookworm/mongodb-org/7.0 main" | sudo tee /etc/apt/sources.list.d/mongodb-org-7.0.list
sudo apt-get update          
sudo apt-get install -y mongodb-org
ps --no-headers -o comm 1

However, at the end it shows:
System has not been booted with systemd as init system (PID 1). Can't operate.
If I try via init I get an error it can't find service mongod

sudo service mongod start

I neither can run a docker image, so I feel I'm stuck here.

I also tried running it manually via sudo /usr/bin/mongod & but that doesn't seem to work; at a later step it can't access a mongodb at localhost.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant