Mongo shard is not getting started. It has a dedicated 10 TB storage out of which it is currently occupying 3.5 TB.Following is error given in logs:Mon Oct 2 22:08:29 [initandlisten] User Assertion: 10309:Unable to create/open lock file: /u01/shard1/mongod.lock errno:30 Read-only file system Is a mongod instance already running?Mon Oct 2 22:08:29 [initandlisten] exception in initAndListen: 10309 Unable to create/open lock file: /u01/shard1/mongod.lock errno:30 Read-only file system Is a mongod instance already running?, terminating
I have tried restarting the machine also. Mongo starts in repair mode. But after some time file system goes into read-only mode and then mongo shard fails to start.
Hi Raidon,
I believe the error messages here are referring to read-only files (or files that cannot be open for write access) rather than a read-only filesystem. MongoDB will not change filesystem mount options.
I suspect you may have run a repair operation as the root user and be running your mongod service with a different user account which does not have write access to some files in your dbPath.
Can you confirm the specific version of MongoDB server and O/S you are using?
Can you also check that the permissions in your dbPath are set correctly? If you aren't sure, please provide the output of ls -la /u01/shard1/mongod.lock and confirm how you normally start your mongod server.
The mongo shard is started in repair mode with the options --repair --nojournal.