setup historic data logging db for cron job