您的位置:首页 > 数据库 > Oracle

如何修改Oracle Enterprise Linux时区?

2018-02-05 00:22 375 查看
修改/etc/sysconfig/clock

[root@psdyy-2 ~]# cat /etc/sysconfig/clock

ZONE="Asia/Shanghai"

UTC=true

[root@psdyy-2 ~]# date

Thu May 18 10:22:35 EDT 2017

备份并修改/etc/localtime

[root@psdyy-2 ~]# ls -l /etc/localtime

-rw-r--r--. 1 root root 3519 Jun 14  2016 /etc/localtime

[root@psdyy-2 ~]# mv /etc/localtime /etc/localtime.ohs

[root@psdyy-2 ~]# date

Thu May 18 14:22:50 UTC 2017

[iapsdyy@psdyy-man ~]$ file /usr/share/zoneinfo/Asia/Shanghai

/usr/share/zoneinfo/Asia/Shanghai: timezone data, version 2, 2 gmt time flags, 2 std time flags, no leap seconds, 16 transition times, 2 abbreviation chars

[iapsdyy@psdyy-man ~]$

[root@psdyy-2 ~]# cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime

[root@psdyy-2 ~]# date

Thu May 18 22:23:03 CST 2017

[root@psdyy-2 ~]# 

 
 

来自 <http://www.ohsdba.cn/index.php?m=Article&a=show&id=258>

 
 
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: