fix wrong logfile
fix sleep time