I find it’s pretty annoying when you have to go log file spelunking only to find all the timestamps are in UTC. But we can set the timezone of the server so when Rails, cron, scripts, etc run, they output more readable dates.
You can check your current timezone by just running
Thu Mar 21 18:02:49 MST 2012
Or checking the timezone file at
So to change it just run
And follow on screen instructions. Easy.
Also be sure to restart cron as it won’t pick up the timezone change and will still be running on UTC.
$ /etc/init.d/cron start
UPDATE July 2016
In the comments Dan mentions that in 16.04 you use something like: