Unix Technical Forum

AIX fix for DST changes.

This is a discussion on AIX fix for DST changes. within the AIX Operating System forums, part of the Unix Operating Systems category; --> Folks, I have couple of system at AIX 5.2 (5200-01) and AIX 5.3 (5300-00), For certain reasons I am ...


Go Back   Unix Technical Forum > Unix Operating Systems > AIX Operating System

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 01-05-2008, 11:17 AM
Hemant Shah
 
Posts: n/a
Default AIX fix for DST changes.


Folks,

I have couple of system at AIX 5.2 (5200-01) and AIX 5.3 (5300-00),
For certain reasons I am not able to update these systems to latest
level. When I went to IBM site and tried to download the appropriate APARS
the Java applet downloaded lots of other fixes as pre-requisites. These
fixes would be upgrading lots of files which I am trying to avoid.

For AIX 4.3.3 IBM suggests that we change TZ variable in /etc/environment
as follows and re-boot:

TZ=CST6CDT,M3.2.0,M11.1.0


Will this work on AIX 5.2 and 5.3 or do I have to update the system?

Thanks.

--
Hemant Shah /"\ ASCII ribbon campaign
E-mail: NoJunkMailshah@xnet.com \ / ---------------------
X against HTML mail
TO REPLY, REMOVE NoJunkMail / \ and postings
FROM MY E-MAIL ADDRESS.
-----------------[DO NOT SEND UNSOLICITED BULK E-MAIL]------------------
I haven't lost my mind, Above opinions are mine only.
it's backed up on tape somewhere. Others can have their own.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 01-05-2008, 11:17 AM
aixdude@yahoo.com
 
Posts: n/a
Default Re: AIX fix for DST changes.

On Feb 15, 3:00 pm, Hemant Shah <s...@typhoon.xnet.com> wrote:
> Folks,
>
> I have couple of system at AIX 5.2 (5200-01) and AIX 5.3 (5300-00),
> For certain reasons I am not able to update these systems to latest
> level. When I went to IBM site and tried to download the appropriate APARS
> the Java applet downloaded lots of other fixes as pre-requisites. These
> fixes would be upgrading lots of files which I am trying to avoid.
>
> For AIX 4.3.3 IBM suggests that we change TZ variable in /etc/environment
> as follows and re-boot:
>
> TZ=CST6CDT,M3.2.0,M11.1.0
>
> Will this work on AIX 5.2 and 5.3 or do I have to update the system?
>
> Thanks.
>
> --
> Hemant Shah /"\ ASCII ribbon campaign
> E-mail: NoJunkMails...@xnet.com \ / ---------------------
> X against HTML mail
> TO REPLY, REMOVE NoJunkMail / \ and postings
> FROM MY E-MAIL ADDRESS.
> -----------------[DO NOT SEND UNSOLICITED BULK E-MAIL]------------------
> I haven't lost my mind, Above opinions are mine only.
> it's backed up on tape somewhere. Others can have their own.



Yes, it works fine. I have tested on AIX 5.1, 5.2 and 5.3
You need to reboot after settting the TZ variable.



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 01-05-2008, 11:17 AM
aixdude@yahoo.com
 
Posts: n/a
Default Re: AIX fix for DST changes.

On Feb 15, 3:00 pm, Hemant Shah <s...@typhoon.xnet.com> wrote:
> Folks,
>
> I have couple of system at AIX 5.2 (5200-01) and AIX 5.3 (5300-00),
> For certain reasons I am not able to update these systems to latest
> level. When I went to IBM site and tried to download the appropriate APARS
> the Java applet downloaded lots of other fixes as pre-requisites. These
> fixes would be upgrading lots of files which I am trying to avoid.
>
> For AIX 4.3.3 IBM suggests that we change TZ variable in /etc/environment
> as follows and re-boot:
>
> TZ=CST6CDT,M3.2.0,M11.1.0
>
> Will this work on AIX 5.2 and 5.3 or do I have to update the system?
>
> Thanks.
>
> --
> Hemant Shah /"\ ASCII ribbon campaign
> E-mail: NoJunkMails...@xnet.com \ / ---------------------
> X against HTML mail
> TO REPLY, REMOVE NoJunkMail / \ and postings
> FROM MY E-MAIL ADDRESS.
> -----------------[DO NOT SEND UNSOLICITED BULK E-MAIL]------------------
> I haven't lost my mind, Above opinions are mine only.
> it's backed up on tape somewhere. Others can have their own.


BTW, the TZ variable does not fix Java
Some java apps may get their time from the JRE, not the OS



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 01-05-2008, 11:17 AM
Ron Hosler
 
Posts: n/a
Default Re: AIX fix for DST changes.

By not applying the updates, your system will handle all current and
future dates correctly, but will be using the 2007 DST rules for past
dates as well. The updates add another entry into a table that allows
AIX to know when DST changes in any year. Setting the timezone variable
forces the 2007 rules for all years.

Excerpt from IBM
What will happen if I fail to update my system?

Systems or applications that rely on date or time processing functions could
make incorrect calculations. Calendar, scheduling, or synchronizing problems
could arise where systems use date or time stamps, or if dates or times are
processed or manipulated in any way. In short, if your system makes date or
time calculations, you may experience calculation errors.
END excerpt

The following perl script
demonstrates this fact.

#!/usr/bin/perl -w

if (check_tz(1142592955, 'Fri Mar 17 06:55:55 2006')) {
print "FWD\n"; # 1142592955 is actually Fri Mar 17 05:55:55 2006
} elsif (check_tz(1174125355, 'Sat Mar 17 05:55:55 2007')) {
print "OK\n";
} else {
print "BAD\n";
}


sub check_tz {
my ($when, $sb) = @_;

my $is = scalar localtime($when);
return ($is eq $sb);
}


On Thu, 15 Feb 2007, Hemant Shah wrote:

>
> Folks,
>
> I have couple of system at AIX 5.2 (5200-01) and AIX 5.3 (5300-00),
> For certain reasons I am not able to update these systems to latest
> level. When I went to IBM site and tried to download the appropriate APARS
> the Java applet downloaded lots of other fixes as pre-requisites. These
> fixes would be upgrading lots of files which I am trying to avoid.
>
> For AIX 4.3.3 IBM suggests that we change TZ variable in /etc/environment
> as follows and re-boot:
>
> TZ=CST6CDT,M3.2.0,M11.1.0
>
>
> Will this work on AIX 5.2 and 5.3 or do I have to update the system?
>
> Thanks.
>
> --
> Hemant Shah /"\ ASCII ribbon campaign
> E-mail: NoJunkMailshah@xnet.com \ / ---------------------
> X against HTML mail
> TO REPLY, REMOVE NoJunkMail / \ and postings
> FROM MY E-MAIL ADDRESS.
> -----------------[DO NOT SEND UNSOLICITED BULK E-MAIL]------------------
> I haven't lost my mind, Above opinions are mine only.
> it's backed up on tape somewhere. Others can have their own.
>

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 01-05-2008, 11:18 AM
Hemant Shah
 
Posts: n/a
Default Re: AIX fix for DST changes.

While stranded on information super highway aixdude@yahoo.com wrote:
> On Feb 15, 3:00 pm, Hemant Shah <s...@typhoon.xnet.com> wrote:
>> Folks,
>>
>> I have couple of system at AIX 5.2 (5200-01) and AIX 5.3 (5300-00),
>> For certain reasons I am not able to update these systems to latest
>> level. When I went to IBM site and tried to download the appropriate APARS
>> the Java applet downloaded lots of other fixes as pre-requisites. These
>> fixes would be upgrading lots of files which I am trying to avoid.
>>
>> For AIX 4.3.3 IBM suggests that we change TZ variable in /etc/environment
>> as follows and re-boot:
>>
>> TZ=CST6CDT,M3.2.0,M11.1.0
>>
>> Will this work on AIX 5.2 and 5.3 or do I have to update the system?
>>
>> Thanks.
>>
>> --
>> Hemant Shah /"\ ASCII ribbon campaign
>> E-mail: NoJunkMails...@xnet.com \ / ---------------------
>> X against HTML mail
>> TO REPLY, REMOVE NoJunkMail / \ and postings
>> FROM MY E-MAIL ADDRESS.
>> -----------------[DO NOT SEND UNSOLICITED BULK E-MAIL]------------------
>> I haven't lost my mind, Above opinions are mine only.
>> it's backed up on tape somewhere. Others can have their own.

>
> BTW, the TZ variable does not fix Java
> Some java apps may get their time from the JRE, not the OS
>


I checked the Java versions, they have the fix for the DST.

>
>


--
Hemant Shah /"\ ASCII ribbon campaign
E-mail: NoJunkMailshah@xnet.com \ / ---------------------
X against HTML mail
TO REPLY, REMOVE NoJunkMail / \ and postings
FROM MY E-MAIL ADDRESS.
-----------------[DO NOT SEND UNSOLICITED BULK E-MAIL]------------------
I haven't lost my mind, Above opinions are mine only.
it's backed up on tape somewhere. Others can have their own.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 01-05-2008, 11:18 AM
Bill Latvin
 
Posts: n/a
Default Re: AIX fix for DST changes.

On Thu, 15 Feb 2007 20:00:35 +0000 (UTC), Hemant Shah wrote:

>
>Folks,
>
> I have couple of system at AIX 5.2 (5200-01) and AIX 5.3 (5300-00),
> For certain reasons I am not able to update these systems to latest
> level. When I went to IBM site and tried to download the appropriate APARS
> the Java applet downloaded lots of other fixes as pre-requisites. These
> fixes would be upgrading lots of files which I am trying to avoid.
>
> For AIX 4.3.3 IBM suggests that we change TZ variable in /etc/environment
> as follows and re-boot:
>
> TZ=CST6CDT,M3.2.0,M11.1.0
>
>
> Will this work on AIX 5.2 and 5.3 or do I have to update the system?
>
> Thanks.
>


After we updated our AIX 4.3 /etc/environment to
TZ=EST5EDT,M3.2.0,M11.1.0, we ran tests with scripts both with and
without TZ=EST5EDT specified first on the ksh command line. The ones
where TZ was not overriden got correct results because the
/etc/environment was used. The ones with TZ=EST5EDT got incorrect
results, as if /etc/environment had not been updated. This was exactly
as expected, because /etc/environment is only used if TZ is not set in
the environment. I think IBM's site about DST updates should make a
point of mentioning this.

If you only update /etc/environment and your system has scripts that
set TZ to timezones affected by the update, you may want to change
those scripts to set the TZ in a way similar to the suggested change
to /etc/environment.

I would presume that the same thing happens on AIX 5.2 and 5.3 if you
only update /etc/environment.

Bill
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 11:21 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com