7

My default location is GMT+1. I would like Ubuntu to automatically change my default timezone based on the timezone of my connected internet connection.

Example:

When I am in Portugal, and connected to an internet connection, I want Ubuntu to change my timezone setting from GMT+1 to GMT+0.

Moreover, I ensured that the following settings are set but they do not make my timezone change:

enter image description here

enter image description here

4

There is a script in GitHub to detect and update the current time zone, using geolocation from your IP address: https://github.com/cdown/tzupdate

Once python and python-pip are installed, the script can be installed as:

pip install -U tzupdate

And run as

sudo ~/.local/bin/tzupdate

This command could be somehow automatically run on startup.

  • Note that /etc/rc.local won't work for running the script automatically, since at that stage the newtork may not yet be available. – Jose Gómez Apr 14 '16 at 17:58
1

For Ubuntu 18.04 make sure Settings -> Privacy -> Location Services is set to "On."

Solution provide by glortho Auto Timezone doesn't update

It automatically works right away.

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.