2 / 35
Sep 2023

App is listening on port 5001

/Users/olumayokunogunfowora/Desktop/complete-node-bootcamp-master/4-natours/starter/node_modules/mongoose/node_modules/mongodb/lib/cmap/connect.js:367 return new error_1.MongoNetworkError(err); ^ MongoNetworkError: 80203CF601000000:error:0A000438:SSL routines:ssl3_read_bytes:tlsv1 alert internal error:../deps/openssl/openssl/ssl/record/rec_layer_s3.c:1586:SSL alert number 80 at connectionFailureError (/Users/olumayokunogunfowora/Desktop/complete-node-bootcamp-master/4-natours/starter/node_modules/mongoose/node_modules/mongodb/lib/cmap/connect.js:367:20) at TLSSocket.<anonymous> (/Users/olumayokunogunfowora/Desktop/complete-node-bootcamp-master/4-natours/starter/node_modules/mongoose/node_modules/mongodb/lib/cmap/connect.js:290:22) at Object.onceWrapper (node:events:628:26) at TLSSocket.emit (node:events:513:28) at emitErrorNT (node:internal/streams/destroy:151:8) at emitErrorCloseNT (node:internal/streams/destroy:116:3) at process.processTicksAndRejections (node:internal/process/task_queues:82:21) { cause: [Error: 80203CF601000000:error:0A000438:SSL routines:ssl3_read_bytes:tlsv1 alert internal error:../deps/openssl/openssl/ssl/record/rec_layer_s3.c:1586:SSL alert number 80 ] { library: 'SSL routines', reason: 'tlsv1 alert internal error', code: 'ERR_SSL_TLSV1_ALERT_INTERNAL_ERROR' }, connectionGeneration: 1, [Symbol(errorLabels)]: Set(1) { 'ResetPool' } } Node.js v18.16.1 [nodemon] app crashed - waiting for file changes before starting...

Good afternoon, welcome!

You can pass information about your connection, how you are creating, if you are using Atlas or your own servers. This will help people understand the problem.

One possible cause to this for Mongo Atlas in particular, is if your IP is not whitelisted. In that case, the SSL handshake fails. The error is a little misleading, but I was getting an “ERR_SSL_TLSV1_ALERT_INTERNAL_ERROR” until I whitelisted my IP address.

8 days later
23 days later

Here

“One possible cause to this for Mongo Atlas in particular, is if your IP is not whitelisted. In that case, the SSL handshake fails. The error is a little misleading, but I was getting an “ERR_SSL_TLSV1_ALERT_INTERNAL_ERROR” until I whitelisted my IP address.”

6 months later
25 days later

if you are using Any VPN or any shield like Macfree etc . off it from your settings and once try again. For me it worked.

3 months later
13 days later

after your mongo url add “databaseName?retryWrites=true&w=majority” this help in clearing the error::

2024-08-14T10:32:43.997Z26634a0dMongoDB connection error: MongoServerSelectionError: 809C140952780000:error:0A000438:SSL routines:ssl3_read_bytes:tlsv1 alert internal error:../deps/openssl/openssl/ssl/record/rec_layer_s3.c:1590:SSL alert number 80 2024-08-14T10:32:43.999Z26634a0d arbiters: [], 2024-08-14T10:32:43.999Z26634a0d code: undefined
26 days later

i already whitelisted my ip but still error but if i set ip to 0.0.0.0/0 it works but i dont want to set it to 0.0.0.0/0 i want to set it to my own ip address. do you have any solution?

It happened to me when I upgraded mongo node.js driver from 6.3.0 to 6.9.0.
Downgrading back to 6.3.0 and the issue is gone.

update: I updated my node version the latest LTS (v20.17.0) and everything is working fine with the new driver