Mongodb installation service has a problem, please ask prawns ~

  mongodb, question

图片描述

As shown in the figure, entering the installation service command does not show the information of successful service creation. . . How to solve it?

First, check what’s wrong with your current method and check the corresponding log files.

Second, in addition, try to use the following method (executed as an administrator) to create services on the Windows operating system:

sc.exe create MongoDB binPath= "\"D:\MongoDB\Server\3.4\bin\mongod.exe\" --service --config=\"D:\MongoDB\Server\3.4\mongod.cfg\"" DisplayName= "MongoDB" start= "auto"

After the creation is completed, MongoDB’s service can be found in the service.

For reference.

Love MongoDB! Have Fun!