Welcome to Knowage Q&A, where you can ask questions and receive answers from other members of the community.
0 votes
1 view

I have trouble to connect to MongoDB server 4.2

com.mongodb.MongoSocketException: mongodb://127.0.0.1:27017                 at com.mongodb.ServerAddress.getSocketAddress(ServerAddress.java:188)                 at com.mongodb.connection.SocketStreamHelper.initialize(SocketStreamHelper.java:59)                 at com.mongodb.connection.SocketStream.open(SocketStream.java:57)                 at com.mongodb.connection.InternalStreamConnection.open(InternalStreamConnection.java:107)                 at com.mongodb.connection.DefaultServerMonitor$ServerMonitorRunnable.run(DefaultServerMonitor.java:111)                 at java.lang.Thread.run(Thread.java:748)         Caused by: java.net.UnknownHostException: mongodb://127.0.0.1:27017                 at java.net.Inet6AddressImpl.lookupAllHostAddr(Native Method)                 at java.net.InetAddress$2.lookupAllHostAddr(InetAddress.java:929)                 at java.net.InetAddress.getAddressesFromNameService(InetAddress.java:1324)                 at java.net.InetAddress.getAllByName0(InetAddress.java:1277)                 at java.net.InetAddress.getAllByName(InetAddress.java:1193)                 at java.net.InetAddress.getAllByName(InetAddress.java:1127)                 at java.net.InetAddress.getByName(InetAddress.java:1077)                 at com.mongodb.ServerAddress.getSocketAddress(ServerAddress.java:186)                 ... 5 more 07-Jul-2020 09:48:58.743 INFOS [http-nio-8080-exec-8] com.mongodb.diagnostics.logging.JULLogger.log No server chosen by ReadPreferenceServerSelector{readPreference=primary} from cluster description ClusterDescription{type=UNKNOWN, connectionMode=SINGLE, serverDescriptions=[ServerDescription{address=mongodb://127.0.0.1:27017:27017, type=UNKNOWN, state=CONNECTING, exception={com.mongodb.MongoSocketException: mongodb://127.0.0.1:27017}, caused by {java.net.UnknownHostException: mongodb://127.0.0.1:27017}}]}. Waiting for 30000 ms before timing out

Environment windows
in Installation by (120 points)
I have the same problem as you
there is any new  please
thank you .

Please log in or register to answer this question.

...