unable to start mongodb server

I followed this tutorial to install mongodb with the 1-click install. https://en.opensuse.org/MongoDB
All went fine.

Also created a btrfs subvolume with mongodb directory, all good.

However, when I run systemctl status mongodb, i get this error:

Job for mongodb.service failed because the control process exited with error code.
See "systemctl status mongodb.service" and "journalctl -xe" for details.

Then, I run systemctl status mongodb.service, i get:

● mongodb.service - High-performance, schema-free document-oriented database
   Loaded: loaded (/usr/lib/systemd/system/mongodb.service; disabled; vendor pr>
   Active: failed (Result: exit-code) since Wed 2019-10-09 19:41:36 EDT; 18s ago
  Process: 31299 ExecStart=/usr/sbin/mongod -f $CONFIG $OPTIONS (code=exited, s>


More details, i run journalctl -xe:

Oct 09 19:41:29 ryzen-pc polkit-kde-authentication-agent-1[3702]: WinId of the >
Oct 09 19:41:29 ryzen-pc polkit-kde-authentication-agent-1[3702]: Trying again
Oct 09 19:41:29 ryzen-pc polkit-kde-authentication-agent-1[3702]: REQUEST
Oct 09 19:41:29 ryzen-pc polkit-kde-authentication-agent-1[3702]: Request:  "Pa>
Oct 09 19:41:29 ryzen-pc polkit-kde-authentication-agent-1[3702]: "Password: "
Oct 09 19:41:31 ryzen-pc polkit-kde-authentication-agent-1[3702]: Dialog accept>
Oct 09 19:41:31 ryzen-pc polkit-agent-helper-1[31292]: gkr-pam: unable to locat>
Oct 09 19:41:31 ryzen-pc polkit-agent-helper-1[31292]: pam_unix(polkit-1:auth):>
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: COMPLETED
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: Completed:  f>
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: Finishing obt>
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: Trying again
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: REQUEST
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: Request:  "Pa>
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: "Password: "
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: Dialog accept>
Oct 09 19:41:36 ryzen-pc polkit-agent-helper-1[31294]: gkr-pam: unable to locat>
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: COMPLETED
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: Completed:  t>
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: Finishing obt>
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: Listener adap>
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: polkit_qt_lis>
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: Finish obtain>
lines 1286-1308/1308 (END)
Oct 09 19:41:29 ryzen-pc polkit-kde-authentication-agent-1[3702]: WinId of the shown dialog is  33554461 33554461
Oct 09 19:41:29 ryzen-pc polkit-kde-authentication-agent-1[3702]: Trying again
Oct 09 19:41:29 ryzen-pc polkit-kde-authentication-agent-1[3702]: REQUEST
Oct 09 19:41:29 ryzen-pc polkit-kde-authentication-agent-1[3702]: Request:  "Password: "
Oct 09 19:41:29 ryzen-pc polkit-kde-authentication-agent-1[3702]: "Password: "
Oct 09 19:41:31 ryzen-pc polkit-kde-authentication-agent-1[3702]: Dialog accepted
Oct 09 19:41:31 ryzen-pc polkit-agent-helper-1[31292]: gkr-pam: unable to locate daemon control file
Oct 09 19:41:31 ryzen-pc polkit-agent-helper-1[31292]:  pam_unix(polkit-1:auth): authentication failure; logname= uid=1000  euid=0 tty= ruser=root rhost=  user=root
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: COMPLETED
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: Completed:  false
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: Finishing obtaining privileges
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: Trying again
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: REQUEST
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: Request:  "Password: "
Oct 09 19:41:33 ryzen-pc polkit-kde-authentication-agent-1[3702]: "Password: "
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: Dialog accepted
Oct 09 19:41:36 ryzen-pc polkit-agent-helper-1[31294]: gkr-pam: unable to locate daemon control file
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: COMPLETED
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: Completed:  true
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: Finishing obtaining privileges
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]:  Listener adapter polkit_qt_listener_initiate_authentication_finish
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]:  polkit_qt_listener_initiate_authentication_finish callback for   0x55afc7e206a0
Oct 09 19:41:36 ryzen-pc polkit-kde-authentication-agent-1[3702]: Finish obtain authorization: true

I tried googling but no avail. Any idea what’s going on?
Thanks.

Don’t post just part, post the entire

systemctl status mogodb

The system log snippet you left out is likely important.

TSU

Hi, that’s all i’m getting when I run systemctl status mongodb:

● mongodb.service - High-performance, schema-free document-oriented database
   Loaded: loaded (/usr/lib/systemd/system/mongodb.service; disabled; vendor pr>
   Active: failed (Result: exit-code) since Thu 2019-10-10 05:30:13 EDT; 50s ago
  Process: 7490 ExecStart=/usr/sbin/mongod -f $CONFIG $OPTIONS (code=exited, st>


Try doing a force re-install,
If the package is named “mongodb” then

zypper in -f mongodb

If that doesn’t solve your problems,
Then remove

zypper rm mongodb

Then go to to the openSUSE software search
And install from the server:database repository

TSU

I tried that and no avail.

This is what is already installed:
Screenshot 20191010 171022 — Postimages](Screenshot 20191010 171022 — Postimages)

I had no problems once I resolved the missing dependency.

So…
Install the missing libboost_filesystem dependency from the following private repo (the command adds the repo)

zypper ar -f http://download.opensuse.org/repositories/home:/marec2000:/cryptocoins/openSUSE_Factory/ repo_to_install_libboost_for_mongodb

Then, install mongodb

zypper in mongodb

Then, start mongodb

systemctl start mongodb

Although the above shouldn’t throw an error, I can verify with the following

systemctl status mongodb
● mongodb.service - High-performance, schema-free document-oriented database
   Loaded: loaded (/usr/lib/systemd/system/mongodb.service; disabled; vendor preset: di>
   Active: active (running) since Thu 2019-10-10 16:46:06 PDT; 3s ago
  Process: 3632 ExecStart=/usr/sbin/mongod -f $CONFIG $OPTIONS (code=exited, status=0/S>
 Main PID: 3645 (mongod)
   Memory: 44.0M
   CGroup: /system.slice/mongodb.service
           └─3645 /usr/sbin/mongod -f /etc/mongodb.conf

HTH,
TSU

I added the repository but nothing changed. So I decided to start over. I used the one-click install, but in Yast, I got this:

Screenshot 20191010 204658 — Postimages](Screenshot 20191010 204658 — Postimages)

systemctl start mongodb
Job for mongodb.service failed because the control process exited with error code.
See "systemctl status mongodb.service" and "journalctl -xe" for details.
systemctl status mongodb.service
● mongodb.service - High-performance, schema-free document-oriented database
   Loaded: loaded (/usr/lib/systemd/system/mongodb.service; disabled; vendor pr>
   Active: failed (Result: exit-code) since Thu 2019-10-10 20:51:54 EDT; 1min 1>
  Process: 11872 ExecStart=/usr/sbin/mongod -f $CONFIG $OPTIONS (code=exited, s>


I feel like nothing really has changed…

UPDATE:

I rebooted the computer and ran

systemctl status  mongodb

and got:

● mongodb.service - High-performance, schema-free document-oriented database
   Loaded: loaded (/usr/lib/systemd/system/mongodb.service; disabled; vendor pr>
   Active: inactive (dead)

Then:

systemctl start mongodb

I get:

Job for mongodb.service failed because the control process exited with error code.
See "systemctl status mongodb.service" and "journalctl -xe" for details.

systemctl status mongodb

● mongodb.service - High-performance, schema-free document-oriented database
   Loaded: loaded (/usr/lib/systemd/system/mongodb.service; disabled; vendor pr>
   Active: failed (Result: exit-code) since Fri 2019-10-11 07:06:41 EDT; 2min 2>
  Process: 3473 ExecStart=/usr/sbin/mongod -f $CONFIG $OPTIONS (code=exited, st>

journalctl -xe
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Listener adap>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: GSimpleAsyncR>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: polkit_qt_lis>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Initiating au>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Message of ac>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Action descri>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: WinId of the >
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: WinId of the >
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Trying again
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: REQUEST
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Request:  "Pa>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: "Password: "
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Dialog accept>
Oct 11 07:06:41 ryzen-pc polkit-agent-helper-1[3470]: gkr-pam: unable to locate>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: COMPLETED
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Completed:  t>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Finishing obt>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Listener adap>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: polkit_qt_lis>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Finish obtain>
Oct 11 07:06:59 ryzen-pc kwin_x11[2415]: qt.qpa.xcb: QXcbConnection: XCB error:>
Oct 11 07:07:00 ryzen-pc kwin_x11[2415]: qt.qpa.xcb: QXcbConnection: XCB error:>
Oct 11 07:07:00 ryzen-pc kwin_x11[2415]: qt.qpa.xcb: QXcbConnection: XCB error:>
 ESCOD
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Listener adap>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: GSimpleAsyncR>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: polkit_qt_lis>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Initiating au>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Message of ac>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Action descri>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: WinId of the >
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: WinId of the >
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Trying again
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: REQUEST
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Request:  "Pa>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: "Password: "
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Dialog accept>
Oct 11 07:06:41 ryzen-pc polkit-agent-helper-1[3470]: gkr-pam: unable to locate>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: COMPLETED
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Completed:  t>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Finishing obt>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Listener adap>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: polkit_qt_lis>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Finish obtain>
Oct 11 07:06:59 ryzen-pc kwin_x11[2415]: qt.qpa.xcb: QXcbConnection: XCB error:>
Oct 11 07:07:00 ryzen-pc kwin_x11[2415]: qt.qpa.xcb: QXcbConnection: XCB error:>
Oct 11 07:07:00 ryzen-pc kwin_x11[2415]: qt.qpa.xcb: QXcbConnection: XCB error:>
 ESCOC
entication-agent-1[2426]: Listener adapter polkit_qt_listener_initiate_authenti>
entication-agent-1[2426]: GSimpleAsyncResult: 0x55d636443200
entication-agent-1[2426]: polkit_qt_listener_initiate_authentication callback f>
entication-agent-1[2426]: Initiating authentication
entication-agent-1[2426]: Message of action:  "Authentication is required to st>
entication-agent-1[2426]: Action description has been found
entication-agent-1[2426]: WinId of the dialog is  35651590 35651590
entication-agent-1[2426]: WinId of the shown dialog is  35651590 35651590
entication-agent-1[2426]: Trying again
entication-agent-1[2426]: REQUEST
entication-agent-1[2426]: Request:  "Password: "
entication-agent-1[2426]: "Password: "
entication-agent-1[2426]: Dialog accepted
lper-1[3470]: gkr-pam: unable to locate daemon control file
entication-agent-1[2426]: COMPLETED
entication-agent-1[2426]: Completed:  true
entication-agent-1[2426]: Finishing obtaining privileges
entication-agent-1[2426]: Listener adapter polkit_qt_listener_initiate_authenti>
entication-agent-1[2426]: polkit_qt_listener_initiate_authentication_finish cal>
entication-agent-1[2426]: Finish obtain authorization: true
 qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 47232, resourc>
 qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 47364, resourc>
 qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 47368, resourc>
 ESCOD


continued:

Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Listener adap>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: GSimpleAsyncR>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: polkit_qt_lis>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Initiating au>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Message of ac>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Action descri>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: WinId of the >
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: WinId of the >
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Trying again
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: REQUEST
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: Request:  "Pa>
Oct 11 07:06:39 ryzen-pc polkit-kde-authentication-agent-1[2426]: "Password: "
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Dialog accept>
Oct 11 07:06:41 ryzen-pc polkit-agent-helper-1[3470]: gkr-pam: unable to locate>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: COMPLETED
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Completed:  t>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Finishing obt>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Listener adap>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: polkit_qt_lis>
Oct 11 07:06:41 ryzen-pc polkit-kde-authentication-agent-1[2426]: Finish obtain>
Oct 11 07:06:59 ryzen-pc kwin_x11[2415]: qt.qpa.xcb: QXcbConnection: XCB error:>
Oct 11 07:07:00 ryzen-pc kwin_x11[2415]: qt.qpa.xcb: QXcbConnection: XCB error:>
Oct 11 07:07:00 ryzen-pc kwin_x11[2415]: qt.qpa.xcb: QXcbConnection: XCB error:>
 ESCOC
entication-agent-1[2426]: Listener adapter polkit_qt_listener_initiate_authenti>
entication-agent-1[2426]: GSimpleAsyncResult: 0x55d636443200
entication-agent-1[2426]: polkit_qt_listener_initiate_authentication callback f>
entication-agent-1[2426]: Initiating authentication
entication-agent-1[2426]: Message of action:  "Authentication is required to st>
entication-agent-1[2426]: Action description has been found
entication-agent-1[2426]: WinId of the dialog is  35651590 35651590
entication-agent-1[2426]: WinId of the shown dialog is  35651590 35651590
entication-agent-1[2426]: Trying again
entication-agent-1[2426]: REQUEST
entication-agent-1[2426]: Request:  "Password: "
entication-agent-1[2426]: "Password: "
entication-agent-1[2426]: Dialog accepted
lper-1[3470]: gkr-pam: unable to locate daemon control file
entication-agent-1[2426]: COMPLETED
entication-agent-1[2426]: Completed:  true
entication-agent-1[2426]: Finishing obtaining privileges
entication-agent-1[2426]: Listener adapter polkit_qt_listener_initiate_authenti>
entication-agent-1[2426]: polkit_qt_listener_initiate_authentication_finish cal>
entication-agent-1[2426]: Finish obtain authorization: true
 qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 47232, resourc>
 qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 47364, resourc>
 qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 47368, resourc>
 ESCOC
er polkit_qt_listener_initiate_authentication
sult: 0x55d636443200
ener_initiate_authentication callback for  0x55d636418ca0
hentication
ion:  "Authentication is required to start 'mongodb.service'."
tion has been found
ialog is  35651590 35651590
hown dialog is  35651590 35651590

Also, when I refresh my repos, i get this:

sudo zypper ref
Repository 'openSUSE:Tumbleweed' is up to date.                                 
Repository 'server:database' is up to date.                                     
Repository 'openSUSE:Factory:NonFree' is up to date.                            
Repository 'Packman Repository' is up to date.                                  
Repository 'openSUSE-Tumbleweed-Non-Oss' is up to date.                         
Repository 'openSUSE-Tumbleweed-Oss' is up to date.                             
Repository 'openSUSE-Tumbleweed-Update' is up to date.                          
Retrieving repository 'repo_to_install_libboost_for_mongodb' metadata ...[error]
Repository 'repo_to_install_libboost_for_mongodb' is invalid.
[repo_to_install_libboost_for_mongodb|http://download.opensuse.org/reposit...nSUSE_Factory/] Valid metadata not found at specified URL
Please check if the URIs defined for this repository are pointing to a valid repository.
Skipping repository 'repo_to_install_libboost_for_mongodb' because of the above error.
Repository 'Databases (openSUSE_Tumbleweed)' is up to date.                     
Repository 'snappy' is up to date.                                              
Some of the repositories have not been refreshed because of an error.


I noticed that the link wasn’t complete, so I fixed that. I don’t get that error anymore. However, as soon as I reboot, i run:

systemctl status mongodb
● mongodb.service - High-performance, schema-free document-oriented database
   Loaded: loaded (/usr/lib/systemd/system/mongodb.service; disabled; vendor pr>
   Active: inactive (dead)

but then it ends with:

mongodb.service - High-performance, schema-free document-oriented database
   Loaded: loaded (/usr/lib/systemd/system/mongodb.service; disabled; vendor pr>
   Active: failed (Result: exit-code) since Fri 2019-10-11 08:54:23 EDT; 2min 3>


By default all newly installed services aren’t running by default, you have to start the service with the command I gave, and only then check status.
Once you’ve verified the services starts and runs, don’t forget to enable so it starts on boot

systemctl enable mongodb.service

TSU

Yep, it also worked about a reboot. Thanks a ton for your help!!