Default ulimit for mongo user is 1024, and max connections that mongo uses is 818 which is 80% of 1024. When the next connection reaches 819, mongod will cease and will not accept anymore clients connections. And quick fix to this is to kill the mongod process and start again.
I need a code to recreate this to have all opened connections used .
Is there way we can do this with mongo shell or pymongo ?