How to change the system time in Unix based systems cover image

How to change the system time in Unix based systems

Sam Ciaramilaro • February 15, 2016

Snippets

You can check the Unix system date/time with this command.

# To check the Unix system date/time
date

To update it to the correct time, replacing HH with the hours (24 hour), MM with minutes and SS with the seconds.

# To update the system time
date +%T -s "HH:MM:SS"