Fixed monitor script log file rotating bug
Removed faulty lock in monitor script