I have had the mongod.log file of more than 10 GBs, so I deleted it. However, since then the file has not been recreated - did I mess it up by deleting the file? How to fix that?
1 Answer
It seems like mogodb does not like that, in fact many applications dont. In the future you should either do it the correct way witch is to use the mongodb logrotate directive
OR, you can usually get away with truncating the logfile sudo echo "" > /path/to/logfile.log
This empties the file content but leaves evrything else as is (more on truncate).
It should fix itself if you restart.