You are not logged in.

#1 2022-11-15 07:22:12

fTEVC
Member
Registered: 2020-02-23
Posts: 4

MongoDB up and running but mongo returns "No such file or directory"

After upgrading some of my AUR packages with yay I can no longer start the mongo shell. My app successfully connects to the database, but when I run

$ mongo

i get:

bash: /usr/bin/mongo: No such file or directory

I've tried uninstalling a reinstalling with

sudo pacman -Rns mongodb-bin mongosh-bin mongodb-tools-bin

and

yay -S mongodb-bin mongosh-bin mongodb-tools-bin

but it doesn't help.

Any idea what might be going wrong here?

Last edited by fTEVC (2022-11-16 06:54:57)

Offline

#2 2022-11-15 08:02:57

d.ALT
Member
Registered: 2019-05-10
Posts: 327

Re: MongoDB up and running but mongo returns "No such file or directory"

fTEVC wrote:

After upgrading some of my AUR packages with yay I can no longer start the mongo shell. My app successfully connects to the database, but when I run

mongo

i get:

bash: /usr/bin/mongo: No such file or directory
# find /usr -iname "mongo*"

<49,17,III,I>    Fama di loro il mondo esser non lassa;
<50,17,III,I>    misericordia e giustizia li sdegna:
<51,17,III,I>    non ragioniam di lor, ma guarda e passa.

Offline

#3 2022-11-15 12:26:16

a821
Member
Registered: 2012-10-31
Posts: 352

Re: MongoDB up and running but mongo returns "No such file or directory"

by looking at the sources of mongodb-bin the command should be "mongos" (note the 's')

Last edited by a821 (2022-11-15 12:26:29)

Offline

#4 2022-11-16 06:54:37

fTEVC
Member
Registered: 2020-02-23
Posts: 4

Re: MongoDB up and running but mongo returns "No such file or directory"

Thanks for the replies.

Realized that the "mongo" command is an older command and must either not be installed with these packages anymore or maybe has a conflict with mongosh. Have to do some more research on that, but in any case, mongosh is the new version of the shell and can be accessed normally with:

$ mongosh

Last edited by fTEVC (2022-11-16 06:56:06)

Offline

Board footer

Powered by FluxBB