Timezone setup for Ubuntu 14 and up
There's a new way of setting up the timezone in Ubuntu -- no more cat.
First, find your timezone by running this command:
timedatectl list-timezones
We are in Eastern Time, so we picked America/New_York. Then we run this command to set the timezone:
timedatectl set-timezone America/New_York
Check to make sure the timezone has been set:
timedatectl
You should get something like this:
Local time: Sun 2017-01-01 17:02:19 EST
Universal time: Sun 2017-01-01 22:02:19 UTC
RTC time: Sun 2017-01-01 22:07:57
Timezone: America/New_York (EST, -0500)
NTP enabled: yes
NTP synchronized: no
RTC in local TZ: no
DST active: no
Last DST change: DST ended at
Sun 2016-11-06 01:59:59 EDT
Sun 2016-11-06 01:00:00 EST
Next DST change: DST begins (the clock jumps one hour forward) at
Sun 2017-03-12 01:59:59 EST
Sun 2017-03-12 03:00:00 EDT
To prevey the clock from drifting, you can setup NTP:
apt-get install ntp
and that's it.