fix crontab and add logging