How do I set the system date and system time from the command line?

Updated -

Release Found: Red Hat Enterprise Linux

Symptom:

The system time or date is wrong and/or you need to set it to specific values from the command line.

Solution:

The command date -s <date or time string> will set the system time and/or date. Where <date or time string> should be e...

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content