Project Home
Project Home
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - porting ntpd: (3 Items)
   
porting ntpd  
Hi

     I am new to ntp. What is the difference between ntp client and server? Is ntpd available in qnx 6.4.0 is ntp server
 or ntp client. If available ntpd is server means do I need to port the ntp client to qnx 6.4?

Requirement:
My application should  get the notification from ntpd whenever the time synchronizes or ntpd is unable to reach the 
public server. So do I need to change the code of ntpd. I downloaded code for ntp  (ntp-4.2.4p6.tar.gz) from www.ntp.org
. Where I will get the information about how to port ntpd client after modifying the code. If anyone knows where to 
change the code to get the notification from ntpd please let me know.
RE: porting ntpd  
The ntpd is both a client and a server depending how you view it. When
your ntpd is to sync with outside time resources (say to time servers on
the internet), it is a client. And when other devices (say a box in your
LAN) wants to sync its time to your ntpd, your ntpd is a server to those
devices. So to your first question, you don't need to port anything from
the ntp package you downloaded. All in the package have already been
ready for you on nto, and for all cpu platform we support.

The ntpd does not possitively broadcast its status. The design is to get
its status through query. The ntpq is for this purpose. So for your
case, I think you may need to modify the ntpd (so it can possitively
notify certain boxes that registered to him) and to write your client
code (started from ntpq) so that your client can communicate with your
modifed ntpd as you want. 

Thanks
Weijie


-----Original Message-----
From: RAHUL SABLE [mailto:community-noreply@qnx.com] 
Sent: March 9, 2009 2:35 AM
To: general-networking
Subject: porting ntpd

Hi

     I am new to ntp. What is the difference between ntp client and
server? Is ntpd available in qnx 6.4.0 is ntp server or ntp client. If
available ntpd is server means do I need to port the ntp client to qnx
6.4?

Requirement:
My application should  get the notification from ntpd whenever the time
synchronizes or ntpd is unable to reach the public server. So do I need
to change the code of ntpd. I downloaded code for ntp
(ntp-4.2.4p6.tar.gz) from www.ntp.org. Where I will get the information
about how to port ntpd client after modifying the code. If anyone knows
where to change the code to get the notification from ntpd please let me
know.


_______________________________________________
General
http://community.qnx.com/sf/go/post23870
Re: RE: porting ntpd  
Thanks Weijie.I will try to follow your suggestions.