Windows 7 mongodb:。。。不是有效的Win32应用程序
当我尝试使用以下命令将mongodb安装为windows服务时: c:\wamp\bin\mongodb\bin>mongod--bind\u ip 127.0.0.1--logpath c:\wamp\bin\mongodb \logs--logappend--dbpath c:\wamp\bin\mongodb\data--directoryperdb--install 它表示我的服务已成功安装,并使用命令“netstart'MongoDB'”启动服务 因此,当我键入命令时: “网络启动MongoDB” 我收到这个错误: “发生系统错误193 *不是有效的Win32应用程序。“ 我有一台运行windows 7 32位操作系统的32位笔记本电脑,我确保安装了mongodb 1.6.5 32位版本 有趣的是,我可以通过运行命令“mongod.exe”的命令行启动mongo服务器,并使用“mongo.exe”执行查询 但是,尝试将其作为服务运行时,我遇到一个windows错误Windows 7 mongodb:。。。不是有效的Win32应用程序,windows-7,windows-services,mongodb,Windows 7,Windows Services,Mongodb,当我尝试使用以下命令将mongodb安装为windows服务时: c:\wamp\bin\mongodb\bin>mongod--bind\u ip 127.0.0.1--logpath c:\wamp\bin\mongodb \logs--logappend--dbpath c:\wamp\bin\mongodb\data--directoryperdb--install 它表示我的服务已成功安装,并使用命令“netstart'MongoDB'”启动服务 因此,当我键入命令时: “网络启动Mo
有什么帮助吗?我认为问题在于您下面的空间(请参阅) 就在这里
--logpath c:\wamp\bin\mongodb \logs --logappend
去掉\mongodb和\logs之间的空格。。。如果您使用Windows 7,请确保您正在以“管理员”身份运行命令提示符
注意,如果您需要一个空格,请在dir路径周围使用引号,这样也可以修复它。您完全正确!我在打自己的脸。我花了20分钟在这条线上扮演主角,试图找出问题所在。谢谢贾斯汀!好眼力。我刚刚意识到我的控制台在空间所在的地方有一条新线。这可能是我从未注意到它的原因。另请注意:我必须将“.exe”添加到“c:\..\..\..\bin>mongod…”中,因此它看起来是这样的:
c:\wamp\bin\mongodb\bin>mongod.exe--bind\u ip 127.0.0.1…
--logpath c:\wamp\bin\mongodb \logs --logappend