Linux vps how to modify the time zone linux vps time zone setting

  

According to NTP network timing Java code

Code is as follows: #date -R

Sunday, November 18, 2012 19:33 23 seconds CSTLinux system using the network time tool is ntpdate, if you do not install ntpdate, you need to install ntpdate: under Centos: Java code

Code is as follows: #yum -y install ntpdate ntp

Under Debian or Ubuntu: Java code #sudo apt-get install -y ntpdate ntpntpdate After installation, you can use ntpdate to update the Linux system time (we use windows time server): Java code
< The code is as follows: #ntpdate time.windows.com

Changing the time zone of the VPS If the VPS defaults to a non-Chinese time zone, the following command can be used to change to the Chinese time zone:

Java code

The code is as follows: #cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime

Note: In Openvz VPS, only the time zone can be modified, but the VPS time cannot be modified. Because Openvz's time is synchronized with the VPS server. If you find that your Openvz VPS time is wrong, you can tell the VPS vendor to be right.

Copyright © Windows knowledge All Rights Reserved