Monday, 3 December 2012

Changing Date time in Linux and in CRS

Chaning Date in Linux and in oracle grid 11.2


1) Chanage the timezone file

vi /etc/sysconfig/clock

Chnage the ZONE accordingly to set the timezone.

Here we have set the ZONE="SGT" , save and close the file.

2) Check the date

# date
Tue Nov 27 19:21:02 PST 2012


2) Create a link between the timezone and the localtime files.

ln -sf /usr/share/zoneinfo/Singapore /etc/localtime

3) Now checke the date

Wed Nov 28 11:22:22 SGT 2012

The date has been changed now.

Change timezone in Grid
=======================

1) Stop the crs.


2) Take the backup of the current timezone file.

cd /grid/11.2.0.3/crs/install
cp s_crsconfig_gridtest2_env.txt s_crsconfig_gridtest2_env.txt_bkp

3) Edit the file as per the timezone required.

vi s_crsconfig_gridtest2_env.txt

Change the TZ=SGT (set according to your timezone) and save and close the file.

4) Start the CRS.



Now check the time in instance.

SQL> select systimestamp from dual;

SYSTIMESTAMP
---------------------------------------------------------------------------
28-NOV-12 11.33.03.349919 AM +08:00

SQL> ! date
Wed Nov 28 11:33:08 SGT 2012



No comments:

Post a Comment