- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- NTP Configuration
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-24-2009 09:05 PM
02-24-2009 09:05 PM
Iam planning to use two ntp server for my hpunix 11.23 and solaris 10 clients.
cisco router as my two ntp sources.
can any body explain how we can configue primary and secondar ntp sources in ntp.conf file and /etc/rc.config.d/netdaemons file.
Pleaase suggest
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-24-2009 09:08 PM
02-24-2009 09:08 PM
Re: NTP Configuration
In Your case.
Login as root to Pluto server and:
1) Edit " /etc/rc.config.d/netdaemons " file on the Pluto Server as follows : export NTPDATE_SERVER=
export XNTPD=1
export XNTPD_ARGS=
2)Edit " /etc/ntp.conf " file in the pluto server with the below entries at the end of the file :
server
3) To Maually start xntpd daemon : # /sbin/init.d/xntpd start
ON Jupiter side :
1)Edit " /etc/rc.config.d/netdaemons " file on the clients side as follows :
export NTPDATE_SERVER=
export XNTPD=1
export XNTPD_ARGS=
2)Edit " /etc/ntp.conf " file on the Jupiter server and add below entries at the end of the file:
server
3)#/sbin/init.d/xntpd start
In case the time synchronisation doesn't start it will definately start at the reboot of respective servers. 95 % it will start w/o reboot.
Regards,
Johnson
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-24-2009 09:31 PM
02-24-2009 09:31 PM
Re: NTP Configuration
can you please tell me how I can mention two ntp source ip adress in ntp.conf and netdaemon file.
means if one ntp source down my client wants to sync to second source automatically.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-24-2009 09:52 PM
02-24-2009 09:52 PM
Re: NTP Configuration
expressing multiple ntpservers either in the etc/rc.config.d/netdaemons , in /etc/ntp.conf , the system shall be choosing the best source to sync the sources.
ON the Clients:
In the /etc/rc.config.d/netdaemons just specify the file names one aside another with a spacebar /TAB between them.
export NTPDATE_SERVER=
In the /etc/ntp.conf file you can just put the multiple server entries as mentioning in the server directive separated by a TAB.
On the Client
#vi /etc/ntp.conf
server
server
server
driftfile /var/adm/drift
regards
sujit
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-24-2009 10:17 PM
02-24-2009 10:17 PM
Re: NTP Configuration
At Server:
The steps to configure a system to be an ntp Server are:
1. Edit the /etc/rc.config.d/netdaemons file to configure the xntpd daemon to startup every time the system boots.
export XNTPD=1 # Set 0 to 1, Start the xntpd daemon every boot "ntp"
export NTPDATE_SERVER= Timer server IP # Set ntp server ip address
export XNTPD_ARGS= ""
For NTP servers, do not set the NTPDATE_SERVER variable (leave it blank).
This variable is for NTP clients.
2. If required Edit the /etc/TIMEZONE file and specify the correct time zone for the system.
TZ=CST6CDT Set the TZ variable to equal the time zone for the system. TO See the /usr/lib/tztab file for a list of all the available time zones.
export TZ
3. Edit the /etc/ntp.conf file and define the NTP server for defining an ntp server to use its local clock:
server 127.127.1.1
fudge 127.127.1.1 stratum 10
4. Start the xntpd daemon manually by executing the following command:
/sbin/init.d/xntpd start
5. Wait. It could take up to 6 minutes for the xntpd daemon to start.
6. Verify the ntp server configuration (and its association with peer NTP servers) by executing the following command:
ntpq -p
In short
At server: U only need to set: the XNTPD variable to equal 1 (/etc/rc.config.d/netdaemon)
Others parameter should keep it be blank.
At client: U must set all below parameter:
export NTPDATE_SERVER='NTP server1 NTP server2'
export XNTPD=1
export XNTPD_ARGS=
and /etc/ntp.conf:
broadcastclient yes
server NTP server
driftfile /etc/ntp.drift
Suraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-25-2009 02:30 AM
02-25-2009 02:30 AM
Re: NTP Configuration
>>>can you please tell me how I can mention two ntp source ip adress in ntp.conf and netdaemon file.
means if one ntp source down my client wants to sync to second source automatically.<<
Example:-
vi /etc/ntp.conf
ntpserver1 192.168.1.1
ntpserver2 192.168.1.2
Hope this Helps,
Thanks,
Johnson
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2009 05:37 AM
02-26-2009 05:37 AM
Re: NTP Configuration
Thnaks for the tips
One more qurey from my end.
For configuring ntp client is it required to run all the servers in same time zone.
because my some of the servers are running in diffrent time zone ie, UAE-4,UAE+4,GMT+4,WAT-4,SAST-2.
In this condition is it required to change all the servers to same time zone.
Expecting some good fast tips.
Thnaks
Jeevaraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2009 07:15 AM
02-26-2009 07:15 AM
Re: NTP Configuration
It is not required to have all servers in same time zone.
NTP will take care of updating the time according to different time zones.
Regards
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-26-2009 10:01 AM
02-26-2009 10:01 AM
Re: NTP Configuration
NTP works on UTC so doesn't are about timezones. It is libc and TZ that takes care of timezones.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-28-2009 06:49 PM
02-28-2009 06:49 PM
Re: NTP Configuration
Could you please explain me more???????
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-01-2009 04:45 AM
03-01-2009 04:45 AM
Solutionâ Variable: char * tzname [2]
The array tzname contains two strings, which are the standard names of the pair of time zones (standard and Daylight Saving) that the user has selected. tzname[0] is the name of the standard time zone (for example, "EST"), and tzname[1] is the name for the time zone when Daylight Saving Time is in use (for example, "EDT"). These correspond to the std and dst strings (respectively) from the TZ environment variable. If Daylight Saving Time is never used, tzname[1] is the empty string.
The tzname array is initialized from the TZ environment variable whenever tzset, ctime, strftime, mktime, or localtime is called. If multiple abbreviations have been used (e.g. "EWT" and "EDT" for U.S. Eastern War Time and Eastern Daylight Time), the array contains the most recent abbreviation.
The tzname array is required for POSIX.1 compatibility, but in GNU programs it is better to use the tm_zone member of the broken-down time structure, since tm_zone reports the correct abbreviation even when it is not the latest one.
Though the strings are declared as char * the user must refrain from modifying these strings. Modifying the strings will almost certainly lead to trouble.
â Function: void tzset (void)
The tzset function initializes the tzname variable from the value of the TZ environment variable. It is not usually necessary for your program to call this function, because it is called automatically when you use the other time conversion functions that depend on the time zone.
The following variables are defined for compatibility with System V Unix. Like tzname, these variables are set by calling tzset or the other time conversion functions.
â Variable: long int timezone
This contains the difference between UTC and the latest local standard time, in seconds west of UTC. For example, in the U.S. Eastern time zone, the value is 5*60*60. Unlike the tm_gmtoff member of the broken-down time structure, this value is not adjusted for daylight saving, and its sign is reversed. In GNU programs it is better to use tm_gmtoff, since it contains the correct offset even when it is not the latest one.
â Variable: int daylight
This variable has a nonzero value if Daylight Saving Time rules apply. A nonzero value does not necessarily mean that Daylight Saving Time is now in effect; it means only that Daylight Saving Time is sometimes in effect.
Thanks,
Johnson
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-01-2009 11:59 AM
03-01-2009 11:59 AM
Re: NTP Configuration
Unix and NTP work on UTC/GMT time, there are no timezones since it is universal.
Johnson has listed some of the Standard C functions that deal with timezones. These are built on top of UTC and the current time_t value. See ctime(3):
http://docs.hp.com/en/B2355-60130/ctime.3C.html
>Johnson: the array contains the most recent abbreviation.
The array contains what the user has set in TZ or /etc/TIMEZONE.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-01-2009 12:43 PM
03-01-2009 12:43 PM
Re: NTP Configuration
> because my some of the servers are running in diffrent time zone ie, UAE-4,UAE+4,GMT+4,WAT-4,SAST-2.
That's perfectly acceptable. As Dennis noted, UNIX and NTP operate in UTC (Coordinated Universal Time), otherwise called Greenwich Mean Time (GMT). UNIX begins time-keeping at its "Epoch" which is defined as Janyary 1, 1970 at 00:00:00 UTC. Time is tracked as the number of seconds since that Epoch.
A timezone is nothing more than a positive or negative offset from UTC. The time you perceive is your LOCAL view of time --- it is the real number of elpased seconds since the Epoch +- some number of (usually) whole hours. Timezones are purely political/social definitions.
As noted, it is the responsiblility of the libC library routines to compute what you see as your LOCAL time based on UTC time.
For your UAE+4 timezone, LOCAL time is +4 hours *behind* UTC whereas in your UAE-4 timezone the LOCAL time is -4 hours *ahead* of UTC. You can see this be setting the TZ variable on the command line _ONLY_ for the duration of a command. This is done thusly:
# TZ=UTC date
Sun Mar 1 20:39:47 UTC 2009
# TZ=UAE+4 date
Sun Mar 1 16:39:53 UAE 2009
# TZ=UAE-4 date
Mon Mar 2 00:39:57 UAE 2009
Thus, if you want, different users could have different timezones set in their login profiles and each would perceive time in their local timezones.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-01-2009 01:02 PM
03-01-2009 01:02 PM
Re: NTP Configuration
UAE+4 (unless in Brazil) isn't a valid TZ value, only UAE-4 is.
GMT can only have the suffix 0, GMT0. Otherwise the name will say GMT but will be 4 hours behind, something very confusing.
>JRF: TZ=UTC date
You should use "date -u" instead.
Actually I think this TZ is incorrect, you must use UTC0, otherwise you will follow US DST rules. Clay's dst.pl script should show this.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-03-2009 10:07 PM
03-03-2009 10:07 PM
Re: NTP Configuration
Actually Clay's script shows it does work but the TZ documentation under environ(5) implies the offset isn't optional.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-07-2009 06:55 AM
03-07-2009 06:55 AM