1

For Ubuntu 20.04 desktop PC I can change date and time from the UI by using these steps,

  1. Click Date & Time in the sidebar to open the panel.
  2. If I have the Automatic Date & Time switch set to on, my date and time should update automatically if I have an internet connection. To update date and time manually, set this to off.
  3. Click Date & Time, then adjust the time and date.

What I tried from terminal:

sudo date --set="2020-08-15"

But it changed and revert automatically within a second (maybe because Automatic Date and Time option are enabled). So for an internal experiment, I need to change the date back to a specific date using the command line or bash file. How to do that properly?

Pablo Bianchi
  • 14,308
  • 4
  • 74
  • 117
  • [Did you try `timedatectl set-ntp no`](https://www.cyberciti.biz/faq/howto-set-date-time-from-linux-command-prompt/) to disable automatic (ntp) date/time update? – Pablo Bianchi Aug 21 '20 at 05:06

0 Answers0