NTP server name and ip details on Linux/Solaris

Hi All,
Where can I find all the NTP server names/ip addresses on Linux/Solaris systems. How can I grep these names/IP address from specific files from a specific OS (Linux/Solaris).
I know on linux /etc/ntp.conf and /etc/ntp/ntp.conf on solaris contains these details. Whether I am right about these files or which other files can contain these details.?

Thanks in advance for your valuable inputs.

Usually, you ntp off the nearer gov sites like USNO, or a corporate or site standard that chains back to same. Is your dilemma how to configure a client to listen, or how to configure server to listen to his master sources and serve clients? Often a firewall does this function, as it is on the Internet and can hit gov servers and provide time to the inside.

Hi,
Say if the NTP is configured on a system, how can I fetch the ntp server and IP address from any system conf file? Is there any hostname gievn to the ntp server along with the IP address?
I am not worried about how the server/client is configured. I just want if ntp is set up on a system, how to get the ntp server name and ip address.

thanks for your reply.

NTP servers come in many forms, but usually the configuration can be read. If configured with IP, do an nslookup to see if it reverses. I cannot say whether name or IP is more reliable, but usually a name is used, so there can be multiple IP supporting the name. If you do not have infrastructure guys to tell you what the internal NTP is, you may need to use an Internet one. My ntp is xntpd, and the default config is /etc/ntp.conf, but I cannot open it. However, 'ntpq -dp -ccooked' shows me three time servers! My windows internet time has an amazing huge list of servers, protocols.

A system that gets time, but does not serve time to the network, is a client. It just needs a server or two to call periodically to keep the clock in sync.

One approach would be to parse the ntp.conf file. Typically you will have more than one FQDN or IPv4/v6 address there. A problem with this approach is that if ntp.conf points to a NTP pool, it is not going to tell you which time servers your system is actually using. In that case , you will have to parse the output of the ntpq command.