0
votes

I tried to install mongodb. Everythnig was fine. Mongo command is working fine. But when i try mongod it throws error message like this :

'mongod' is not recognized as an internal or external command,operable program or batch file.

P.S: I added the path variable clearly and I put a backslash after bin (C:\Program Files\MongoDB\Server\4.0\bin\)like this.

So can anyone help me to sort this out, why mongod is not working, meanwhile mongo command is working fine.

Not a duplicate,bz in may case "mongo" is working fine,whereas "mongod" only throws error

2
nope.In my que server command is not working,while mongo is working. server connection command "mongod" only throws error - RAS
@RAS - After adding path to environment variables open fresh command prompt and try. Environment changes doesn't reflect if in the terminal process if it is already running. - A. Todkar
yup i knw that,,i refreshed and restart the whole machine .still no luck.i done this before,this time only it throws this weird error.can anyone tell me what i am doing wrong,in this simple process and dont vote down,it not a duplicate and i knew how to add path variable.it worked before,with this new system,i had this problem.Thanks - RAS

2 Answers

1
votes

Open command prompt as administrator and then run

0
votes

Finally, I found out the mystery.There is some missing files while I downloaded MongoDB. Especially Mongod.exe. Thats why I did't get to work.Hope someone find it useful for future reference