10-20-2005
In Solaris TZ variable is defined in /etc/TIMEZONE file
use manpage TIMEZONE
10 More Discussions You Might Find Interesting
1. UNIX for Advanced & Expert Users
I'm running on UNIX with Solaris. I need to change the Timezone on the box and was going to make the changes to the files and then reboot the box.
Someone warned me that this method should not be used and that a util (unconfig.sys I think it was) should be used to make the changes.
Any ideas... (2 Replies)
Discussion started by: Lextar
2 Replies
2. UNIX for Dummies Questions & Answers
Hello again,
under hp-ux i have a file /etc/TIMEZONE. here is definied which timezone i am.
i dont know who reads this file to set after reading the timezone under /usr/lib/tztab.
my 2 questions, who reads the file /etc/TIMEZONE ( which service ) and do i need in the first line to set my... (6 Replies)
Discussion started by: ortsvorsteher
6 Replies
3. UNIX for Dummies Questions & Answers
Hi,
I got an question about changing timezone thrue command line on a SunOS Release 4.1.2 without restarting the computer.
Now it's set on WET and I want to set the timezone to CET (GMT +1)
Plz somebody help me.
Regards
Novisern:confused: (5 Replies)
Discussion started by: Novisern
5 Replies
4. UNIX for Dummies Questions & Answers
Hi,
i am searching to change the timezone on a HP-UX11 system. Since last weekend the summertime started i am not able to change the time to the new time, every day the time changes back to wintertime. I think the problem is that the server is on the wrong timezone. Can someone help me please?... (1 Reply)
Discussion started by: eddyvdv
1 Replies
5. AIX
Hi
On several AIX 5.3 LPARs the timezone is currrently set to:
TZ=NZST-12NZDT,M9.5.0/02:00,M4.1.0/03:00
Daylight savings in NZ starts on Sun 28th Sep 2008, which is the fourth Sunday. Do I need to change my TZ variable to NZST-12NZDT,M9.4.0/02:00,M4.1.0/03:00 or will AIX interpret the fifth... (2 Replies)
Discussion started by: KiwiP
2 Replies
6. Shell Programming and Scripting
Hi All,
While installing Red Hat Linux, I tried changing the timezone to Japan for testing.But the timezone was not set to Japan.
I tried other timezones , but they didn't work as well.
I am guessing the problem might be due to some missing rpm.Does anyone has any idea or faced a similar... (1 Reply)
Discussion started by: nua7
1 Replies
7. Solaris
Hi Everyone,
We have Solaris server which displays the time in CET and our application is used across the globe.(Users are in singapore, poland, US).
At present in order to display Timezone we are manually manupulating time based on country in a enviromental file.
I want to know , do we... (2 Replies)
Discussion started by: gehlnar
2 Replies
8. Solaris
Hi,
On my server timezone is IST, so I have configured the sudo for user to change the date, but when he is changing the date time zone is also getting changed from ist to gmt. using solaris 10. I have checked in /etc/TIMEZONE file in that it is showing TZ=Asia/Calcutta, wheather any other file... (1 Reply)
Discussion started by: manoj.solaris
1 Replies
9. Solaris
hii there...
can you guys help me with TIMEZONE setting on my solaris box
i tried to edit cat /etc/TIMEZONE..but i think it will work after rebooting,
but something i did which took me to GMT
my problem is i have this issue on a server, and i have to fix this without rebooting.
thanks for... (1 Reply)
Discussion started by: 6pound
1 Replies
10. UNIX for Dummies Questions & Answers
HI Gurus,
I have a issue. One of our applications needs the data loads with the timezone (CST) but our zones run on GMT. I tried to change the TZ value under /etc/default/init value but it seems to effect the the whole zone. Is there any way I can just set up the TZ as CST for a particular user.... (2 Replies)
Discussion started by: rama krishna
2 Replies
LEARN ABOUT SUNOS
gettimeofday
gettimeofday(3C) Standard C Library Functions gettimeofday(3C)
NAME
gettimeofday, settimeofday - get or set the date and time
SYNOPSIS
#include <sys/time.h>
int gettimeofday(struct timeval *tp, void *tzp);
int settimeofday(struct timeval *tp, void *tzp);
DESCRIPTION
The gettimeofday() function gets and the settimeofday() function sets the system's notion of the current time. The current time is
expressed in elapsed seconds and microseconds since 00:00 Universal Coordinated Time, January 1, 1970. The resolution of the system clock
is hardware dependent; the time may be updated continuously or in clock ticks.
The tp argument points to a timeval structure, which includes the following members:
long tv_sec; /* seconds since Jan. 1, 1970 */
long tv_usec; /* and microseconds */
If tp is a null pointer, the current time information is not returned or set.
The TZ environment variable holds time zone information. See TIMEZONE(4).
The tzp argument to gettimeofday() and settimeofday() is ignored.
Only privileged processes can set the time of day.
RETURN VALUES
Upon successful completion, 0 is returned. Otherwise, -1 is returned and errno is set to indicate the error.
ERRORS
The settimeofday() function will fail if:
EINVAL The structure pointed to by tp specifies an invalid time.
EPERM The {PRIV_SYS_TIME} privilege was not asserted in the effective set of the calling process.
The gettimeofday() function will fail for 32-bit interfaces if:
EOVERFLOW The system time has progressed beyond 2038, thus the size of the tv_sec member of the timeval structure pointed to by tp is
insufficient to hold the current time in seconds.
USAGE
If the tv_usec member of tp is > 500000, settimeofday() rounds the seconds upward. If the time needs to be set with better than one second
accuracy, call settimeofday() for the seconds and then adjtime(2) for finer accuracy.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Interface Stability |gettimeofday() is Standard. |
+-----------------------------+-----------------------------+
|MT-Level |MT-Safe |
+-----------------------------+-----------------------------+
SEE ALSO
adjtime(2), ctime(3C), gethrtime(3C), TIMEZONE(4), attributes(5), privileges(5), standards(5)
SunOS 5.10 1 Aug 2003 gettimeofday(3C)