Server Time

Taking care of your Linux box.
Post Reply
mejam
Havaldaar
Posts: 127
Joined: Sat Oct 18, 2008 12:30 pm
Location: Lahore
Contact:

Server Time

Post by mejam »

I am having this problem from past week or so....time of all the servers in my network is set to EST and every time i set it with date --set "NEW_DATE_TIME"...the settings get vanished after some time....please tell me how can i set time of my local servers to Pakistan Stanadard Time..
Regards
Abdulrehman
lambda
Major General
Posts: 3452
Joined: Tue May 27, 2003 7:04 pm
Location: Lahore
Contact:

Post by lambda »

it depends on the linux distribution, but usually you have to do something like

Code: Select all

cp /usr/share/zoneinfo/Asia/Karachi /etc/localtime
then turn off ntpd if it's running, and type

Code: Select all

ntpdate time.apple.com
(or time.windows.com, or ntp.ubuntu.com -- they all should be synchronized). you'll probably have to restart a few services (mail daemons, etc) for them to get the new time.

after that, enable ntpd and make sure it runs all the time.
Watch out for the Manners Taliban!
Isn't it amazing how so many people can type "linuxpakistan.net" into their browsers but not "google.com"?
mejam
Havaldaar
Posts: 127
Joined: Sat Oct 18, 2008 12:30 pm
Location: Lahore
Contact:

Post by mejam »

thanks lambda bhai...it helped me alot
Regards
Abdulrehman
Post Reply