I am trying to set current date in Ubuntu 22.04 using:
date -s YY/MM/DD
but I am getting error:
date: invalid date ‘YY/MM/DD’
I am trying to set current date in Ubuntu 22.04 using:
date -s YY/MM/DD
but I am getting error:
date: invalid date ‘YY/MM/DD’
2
Answers
you want to change the systemtime?
then you need to use timedatectl.
for example:
you can check if it worked by
you don’t seem to be setting in values, rather you’re passing in the format
perhaps try this solution: