The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Advanced & Expert Users
.
google unix.com



UNIX for Advanced & Expert Users Expert-to-Expert. Learn advanced UNIX, UNIX commands, Linux, Operating Systems, System Administration, Programming, Shell, Shell Scripts, Solaris, Linux, HP-UX, AIX, OS X, BSD.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
How to find out the ipaddress? DineshV UNIX for Dummies Questions & Answers 4 06-08-2009 05:25 AM
ipaddress in HP-UX RockyC123 Shell Programming and Scripting 7 03-25-2008 07:27 AM
Add IpAddress Through Programatically ykmraju High Level Programming 6 07-17-2006 10:48 AM
how to find ipaddress shruti_mgp HP-UX 14 05-04-2006 06:58 AM
change the IPAddress and local name lapnguyen UNIX for Dummies Questions & Answers 2 07-10-2002 01:49 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 05-26-2009
Gopi Krishna P Gopi Krishna P is offline
Registered User
  
 

Join Date: Dec 2008
Posts: 17
how linux knows ipaddress of it?

which kernel data structure stores ipaddress. and how to change the ipaddress other that ifconfig.

in case of dhcp client daemon how linux automatically assigns ipaddress fetched?

Would some one answer these questions please?
  #2 (permalink)  
Old 05-26-2009
pludi's Avatar
pludi pludi is online now Forum Staff  
Moderator
  
 

Join Date: Dec 2008
Location: .at
Posts: 1,849
If I remember correctly all information for IPv4 is defined in include/linux/ip.h in the source tree, used by almost everything in net/ and drivers/net/ (all paths relative to the kernel source path)
As for the DHCP client daemon, it probably sets the IP address via a kernel call.
  #3 (permalink)  
Old 05-28-2009
Gopi Krishna P Gopi Krishna P is offline
Registered User
  
 

Join Date: Dec 2008
Posts: 17
Hey thanks for your info
  #4 (permalink)  
Old 05-28-2009
fpmurphy's Avatar
fpmurphy fpmurphy is offline Forum Staff  
Moderator
  
 

Join Date: Dec 2003
Location: Florida
Posts: 1,924
You can use the ioctl SIOCGIFADDR to get the IP address and SIOCSIFADDR to set the IP address.
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 On




All times are GMT -4. The time now is 02:33 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0