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

Unable to start mongodb exporter in 7.0.5 version of mongodb #815

Closed
mkmpvtltd1 opened this issue Mar 11, 2024 · 1 comment
Closed

Unable to start mongodb exporter in 7.0.5 version of mongodb #815

mkmpvtltd1 opened this issue Mar 11, 2024 · 1 comment

Comments

@mkmpvtltd1
Copy link

mkmpvtltd1 commented Mar 11, 2024

 sudo systemctl status mongodb_exporter.service
● mongodb_exporter.service - MongoDB Exporter
     Loaded: loaded (/lib/systemd/system/mongodb_exporter.service; disabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Mon 2024-03-11 09:55:35 CET; 3min 2s ago
    Process: 129289 ExecStart=/usr/local/bin/mongodb_exporter (code=exited, status=203/EXEC)
   Main PID: 129289 (code=exited, status=203/EXEC)

[1]: mongodb_exporter.service: Scheduled restart job, restart counter is at 5.
[1]: Stopped MongoDB Exporter.
[1]: mongodb_exporter.service: Start request repeated too quickly.
[1]: mongodb_exporter.service: Failed with result 'exit-code'.
[1]: Failed to start MongoDB Exporter.
@Kellman3000
Copy link

Kellman3000 commented Mar 14, 2024

Ran into this as well. It's the group getting set in '/etc/systemd/system/mongodb_exporter.service'
It's currently getting set to 'nogroup' by the RPM, but it should be 'mongodb_exporter'. Change it to 'mongodb_exporter' and it will start. I.e. here's what your .service file should look like:

[Unit]
Description=Prometheus MongoDB Exporter
Documentation=https://github.com/percona/mongodb_exporter
After=network.target

[Service]
Type=simple

User=mongodb_exporter
Group=mongodb_exporter

EnvironmentFile=-/etc/default/mongodb_exporter
ExecStart=/usr/bin/mongodb_exporter $OPTIONS
SyslogIdentifier=mongodb_exporter

Restart=always

[Install]
WantedBy=multi-user.target

@igroene igroene closed this as completed May 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants