Networking Forums

Networking Forums > Computer Networking > Linux Networking > API for identifying the DHCP server's IP address.

Reply
Thread Tools Display Modes

API for identifying the DHCP server's IP address.

 
 
lawrieleo@gmail.com
Guest
Posts: n/a

 
      07-25-2005, 12:01 PM
Hi all,

Here we are writing an application, which basically shows the network
configuration parameters of our linux box.
A dhcp client is working which fetches the ip address from the DHCP
server operating in our network. There could be morethan one server
operating. This application also needs to display the DHCP server's IP
address the one that assigned an IP address to our box?
How can our application program identify the DHCP server's IP address?
Any specific API or IOCTL for this purpose?
Please suggest.

Thanks,
Lawrie.

 
Reply With Quote
 
 
 
 
cyclone
Guest
Posts: n/a

 
      07-25-2005, 02:15 PM
scan file /etc/dhcpc/dhcpc-d-ethx.info for
'DHCPSID=x.x.x.x' That should be the server IP that gave
you your address.
Sys V filesystem may hide elswhere, or add a line of code to the dhcp
client software to write a log file of the server IP when it gets one,
perhaps in the /proc folder
RObert


On Mon, 25 Jul 2005 05:01:50 -0700, lawrieleo wrote:

> Hi all,
>
> Here we are writing an application, which basically shows the network
> configuration parameters of our linux box.
> A dhcp client is working which fetches the ip address from the DHCP
> server operating in our network. There could be morethan one server
> operating. This application also needs to display the DHCP server's IP
> address the one that assigned an IP address to our box?
> How can our application program identify the DHCP server's IP address?
> Any specific API or IOCTL for this purpose?
> Please suggest.
>
> Thanks,
> Lawrie.


 
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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Identifying An IP Address Scott Wireless Networks 3 02-03-2007 03:35 PM
identifying the smtp server JahMic Windows Networking 2 09-05-2006 12:05 PM
Issues with DHCp/WINS server IP address Dany C. Windows Networking 4 10-04-2005 06:41 PM
Identifying the DHCP server IP.... sivam Linux Networking 8 11-01-2004 04:45 PM
ISC DHCP server: last address of range? knocte Linux Networking 1 02-17-2004 10:37 AM



1 2 3 4 5 6 7 8 9 10 11