Validation script is giving timeout error

Hi, I am getting below error while running “validate_lab_configuration_file”, any help is appreciated.


vagrant@m103:~/data$ ps -ef | grep mongod
vagrant 9026 9005 10 19:30 pts/1 00:00:02 mongod -f mongod.conf
vagrant 9058 8781 0 19:30 pts/0 00:00:00 grep --color=auto mongod
vagrant@m103:~/data$
vagrant@m103:~/data$ validate_lab_configuration_file
Client experienced a timeout when connecting to the database - check that mongod is running on the correct port, and that your user was created with the correct settings.

vagrant@m103:~/data$ cat mongod.conf
storage:
dbPath: “/data/db”
systemLog:
path: “/data/log/mongod.log”
destination: “file”
net:
bindIp : “localhost,192.168.103.100”
security:
authorization: enabled


Thanks

Is this full config file or partial one?
I don’t see the port in your cfg file
Also did you create the user?
Please go thru your lab requirements again

1 Like

Hi @Seshi_Kishore_05004,

As @Ramachandra_37567 mentioned, you have not specified the port number in your configuration file. If in case the port number is missing then the mongod will use the default port option i.e. 27017. However, in this lab you are supposed to run the mongod instance on port 27000.

Hope it helps!

Thanks,
Shubham Ranjan
Curriculum Services Engineer

Added port 27000 and replication to the config file and re-ran but getting the same error, in the first lab I’d created m103 user and lab completed.

conf file:

vagrant@m103:~$ cat /data/mongod.conf

storage:
dbPath: “/data/db”
systemLog:
path: “/data/log/mongod.log”
destination: “file”
replication:
replSetName: M103
net:
bindIp : “127.0.0.1,192.168.103.100”
port: 27000
security:
authorization: enabled


M103 user:

MongoDB Enterprise > db.getUsers()
[
{
“_id” : “admin.m103-admin”,
“userId” : UUID(“01744ad3-f20f-4138-948c-e4ae272bfb84”),
“user” : “m103-admin”,
“db” : “admin”,
“roles” : [
{
“role” : “root”,
“db” : “admin”
}
]
}
]

Hi Subham, Ramachandra.

I figured out the issue, lab2 completed. thanks for your guidance

Hi @Seshi_Kishore_05004,

I’m glad your issue got resolved.

I will still recommend you to read more about the options that you have used in your configuration file (especially the replication option). Please refer our documentation page on Configuration file options.

Please feel free to get back to us if you have any other query/concerns.

Thanks,
Shubham Ranjan
Curriculum Services Engineer