Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
135 views
in Technique[技术] by (71.8m points)

node.js - Cant set path for mongoDB

i already installed it, but when i run mongod i get:

"NonExistentPath: Data directory C:\data\db\ not found. Create the missing directory or specify another path using (1) the --dbpath command line option, or (2) by adding the 'storage.dbPath' option in the configuration file."}},

so searching i need to create a path to store the data, i want to save in the folder of my project, this is the route:

C:UsersUser_namemern-todo-appackendmongodbdatadb,

so it will be:

"C:Program FilesMongoDBServer4.0inmongod.exe" --dbpath "C:UsersUser_namemern-todo-appackendmongodbdatadb"

but it says that cant find the route, im not good using the console so, if anyone can help me, thanks :)

question from:https://stackoverflow.com/questions/65857283/cant-set-path-for-mongodb

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...