record state in MEGAM_HOME, all logs are rolled up in <nodename>.log_out, _err