Re: i/p address (122 Views)
Reply
Honored Contributor
Ganesh Babu
Posts: 1,123
Registered: ‎12-16-2002
Message 1 of 9 (122 Views)
Accepted Solution

i/p address

Guys.. once again.. how to find the i/p address & host names assigned for an network card??

Ganesh
Outstanding Contributor
Pete Randall
Posts: 16,205
Registered: ‎11-03-1996
Message 2 of 9 (122 Views)

Re: i/p address

Ganesh,

ifconfig will give you the ip address: ifconfig lan0, for example.

nslookup will give you the hostname associated with an ip address: nslookup 100.101.102.103, for example.


Pete

Pete
Honored Contributor
John Dvorchak
Posts: 682
Registered: ‎02-19-2001
Message 3 of 9 (122 Views)

Re: i/p address

the info is in /etc/rc.config.d/netconf

You should also have the IP Address and FQDN and short name in /etc/hosts
If it has wheels or a skirt, you can't afford it.
Honored Contributor
Sridhar Bhaskarla
Posts: 6,350
Registered: ‎08-15-2001
Message 4 of 9 (122 Views)

Re: i/p address

Hi Ganesh,

'ifconfig lanx' is the command you are looking for.

netstat -in will also give the information on all the lancards and the IP addresses associated with it.

Hostname will be only one on the box. If the server has multiple lan cards and multiple address, each address may have a different DNS name. An 'nslookup' can give you the name corresponding to the IP address which is displayed in 'netstat -i' output.

'hostname' gives the hostname of the server.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Honored Contributor
Patrick Wallek
Posts: 13,777
Registered: ‎06-21-2000
Message 5 of 9 (122 Views)

Re: i/p address

Use lanscan to get the 'lan?' for each card.

The use 'ifconfig lan?' (where lan? = lan0, lan1, whatever') to get the IP address.

You could then use 'nslookup ip.addy' to get the hostname.
Honored Contributor
Denver Osborn
Posts: 1,749
Registered: ‎06-23-2000
Message 6 of 9 (122 Views)

Re: i/p address

or use

netstat -in
Honored Contributor
Ganesh Babu
Posts: 1,123
Registered: ‎12-16-2002
Message 7 of 9 (122 Views)

Re: i/p address

Thanks Guys..

Ganesh
Frequent Advisor
cl_5
Posts: 62
Registered: ‎01-12-2003
Message 8 of 9 (122 Views)

Re: i/p address

Use lanscan to check out your lancard(s) and then ifconfig lanX

regards
cl
Regular Advisor
Anoop P_2
Posts: 91
Registered: ‎01-21-2004
Message 9 of 9 (122 Views)

Re: i/p address

Hi

IP Address:
1. #ioscan -fnC lan
Find out the device number from the output. Ex.: lan0, lan2 etc.

2. #ifconfig lanX where X is to be substituted accordingly

Hostname: This is unique to a machine and not to a networkcard. For finding out the hostname,

1. #hostname



The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.