I am very new to MongoDB. Infact, I am new to MEAN Stack. I have successfully installed the MongoDB server on my Mac. After I run the following command:
mongod
the server starts on the port 27017
. I try to access the server by entering the localhost URL on the chrome window:
http://127.0.0.1:27017/
I get the following error in the terminal window where the server is running:
SSLHandshakeFailed: SSL handshake received but server is started without SSL support.
To solve this, I googled the error and I tried a few following suggestions from this and this link:
openssl genrsa -des3 -out rootSSL.key 2048
This creates a .key
file. Then,
openssl req -x509 -new -nodes -key rootSSL.key -sha256 -days 1024 -out rootSSL.pem
This creates a .pem
file.
I have even added the .pem
file in the System
in Keychain Access
.
Some links suggested that I should create a server.cnf
file, some suggested that I should create a Domain certificate.
Someone also suggested in a question on SO that one should start with Postman, but that is not working either.
Can anybody help me in figuring out this error as all the other suggestions were very confusing and all of them appeared to be beating around the bush.