gpt4 book ai didi

MongoDB:启动期间无法设置套接字

转载 作者:IT老高 更新时间:2023-10-28 13:24:25 24 4
gpt4 key购买 nike

我有 Windows 8.1 Enterprise 64 位机器。我已经为具有 SSL 支持的 windows 安装了 mongodb msi。我创建了环境设置所需的所有附加条件。现在使用命令提示符导航到 mongodb 安装文件夹中的 bin 目录并执行以下命令:

mongod.exe --dbpath "c:\data"

我看到以下响应:

C:\mongodb\bin>mongod.exe --dbpath "c:\data"
2016-05-27T17:09:43.362+0530 I CONTROL [initandlisten] MongoDB starting : pid=2
108 port=27017 dbpath=C:\data\db\ 64-bit host=TestServer
2016-05-27T17:09:43.363+0530 I CONTROL [initandlisten] targetMinOS: Windows 7/W
indows Server 2008 R2
2016-05-27T17:09:43.364+0530 I CONTROL [initandlisten] db version v3.2.6
2016-05-27T17:09:43.364+0530 I CONTROL [initandlisten] git version: 05552b562c7
a0b3143a729aaa0838e558dc49b25
2016-05-27T17:09:43.364+0530 I CONTROL [initandlisten] OpenSSL version: OpenSSL
1.0.1p-fips 9 Jul 2015
2016-05-27T17:09:43.364+0530 I CONTROL [initandlisten] allocator: tcmalloc
2016-05-27T17:09:43.364+0530 I CONTROL [initandlisten] modules: none
2016-05-27T17:09:43.364+0530 I CONTROL [initandlisten] build environment:
2016-05-27T17:09:43.364+0530 I CONTROL [initandlisten] distmod: 2008plus-ss
l
2016-05-27T17:09:43.364+0530 I CONTROL [initandlisten] distarch: x86_64
2016-05-27T17:09:43.365+0530 I CONTROL [initandlisten] target_arch: x86_64
2016-05-27T17:09:43.365+0530 I CONTROL [initandlisten] options: {}
2016-05-27T17:09:43.365+0530 E NETWORK [initandlisten] listen(): bind() failed
errno:10048 Only one usage of each socket address (protocol/network address/port
) is normally permitted. for socket: 0.0.0.0:27017
2016-05-27T17:09:43.366+0530 E STORAGE [initandlisten] Failed to set up sockets
during startup.
2016-05-27T17:09:43.366+0530 I CONTROL [initandlisten] dbexit: rc: 48

谁能帮我解决这个问题。

最佳答案

运行

netstat -a -n | find "27017"

检查是否已使用端口 27017

F:\data\bin> netstat -a -n | find "27017"

TCP 0.0.0.0:27017 0.0.0.0:0 LISTENING

或运行 taskmgr 并找到并杀死所有 mongod 进程

关于MongoDB:启动期间无法设置套接字,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37483014/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com