LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   ip address (https://www.linuxquestions.org/questions/linux-general-1/ip-address-1317/)

Bashkir 03-15-2001 12:32 AM

I'm on a school network and the ip isn't static, so how do I find out my ip in linux...? I'm a linux newbie, just running it for a counter-strike server, although it'll probably be a good skill for jobs later if I'm ambitious in learning it..:)

bretthoward 03-15-2001 05:29 AM

Finding your IP addy
 
Try running "/sbin/ifconfig"

You should get an output like the following:
eth0 Link encap:Ethernet HWaddr 00:A0:C9:DB:AB:E6
inet addr:140.211.139.173 Bcast:140.211.139.255
(With more down below this)

ETH0 is the first network card! I didnt show the rest because there are a few network cards in this machine. You will notice an interface called lo at the bottom that is your loopback interface but the value you are looking for is (inet addr:) as you can see at the moment the IP address of my first network card is 140.211.139.173 hope this helps.

ejtbrown 03-20-2001 08:18 PM

Chances are that your school is using DHCP (Dynamic Host Contiguration Protocol) or BOOTP (I can't remember what this one stands for) which are mostly compatible. DHCP is a newer, slicker version of the same protocol. I know that Linux supports both of these protocols, but there *is* a mini-HOW-TO on DHCP (check http://www.linuxdoc.org).


All times are GMT -5. The time now is 05:16 PM.