On previous version of centos , i used the following command to get the current timezone in my bash script
timezone=$(sed 's/ZONE=//g' /etc/sysconfig/clock)
Output is "America/New_York"
"America/New_York"
How can i achieve an exact output on centos 7
Aucun commentaire:
Enregistrer un commentaire