Solutions: Change and Update Time Zone (Bangkok ICT) on CentOS/Debian or other Linux

rm -f /etc/localtime
ln -s /usr/share/zoneinfo/Asia/Bangkok /etc/localtime
#or
export TZ=Asia/Bangkok
vim /usr/local/lib/php.ini
date.timezone = "Asia/Bangkok"
#or
<?php date('d/m/Y H:i:s', time()+25200); ?>

Update Timezone (CentOS)

yum -y install ntp

Update Timezone (Debian)

aptitude -y install ntpdate
ntpdate pool.ntp.org
#or
aptitude install ntp

replace some ntp server below

vim /etc/ntp.conf
server 1.th.pool.ntp.org
server 0.asia.pool.ntp.org
server 2.asia.pool.ntp.org

Recheck your localtime

date
ntpdate pool.ntp.org

share: Change Localtime and Update Linux