Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Where's ifconfig???? 2

Status
Not open for further replies.

Scanner

MIS
Apr 14, 1999
109
US
I just started running Fedora Core 2 and other than a few hitches, I really like it. My goal is to completely migrate from MS eventually, but there are a few things that bother me. Luckily, I'm only concerned about one right now...

FC2 is installed on my Toshiba laptop and the IP address is assigned via DHCP. I have no problem getting connected to the web, but I need to find out what IP the server assigned me.

How can I find out what my assigned IP address is? I thought it was the ifconfig command, but I can't find it on the system anywhere. I keep getting a "command not found" error.

I've tried running as my user account and as root. I've also tried to do a recursive search from / and the command is nowhere to be found on the system.

Is there another command that I can use, or is ifconfig something that has to be installed after the OS is on? for that matter, am I even spelling it right?

Thanks in advance...

Scanner
 
Usually [tt]/sbin/ifconfig[/tt]. That's where it is on my FC2 box.

----
JBR
 
Also, you say you looked as user and as root. If you were a user, then did [tt]su[/tt] to switch to root, your $PATH will still be the user's $PATH, which doesn't include the sbin directories out of the box. I usually use [tt]su -[/tt]. The '-' means make it a login shell, which means your environment gets re-sourced as the user you are switching to, so you get root's real $PATH with all the sbin dirs.

----
JBR
 
You can try:
Code:
locate ifconfig

If the locate command's database has been updated (which usually happens at around 4:00am, but could potentially happen at any time, of course) this will be much faster than doing a recursive search.

If it's really not there, it should at least be in a package on your distribution CD.

If you can't be bothered with any of that and need your IP right away, ping something; that'll tell you your IP address, too.
 
Thanks for the quick responses!

the "su -" did the trick. I didn't realize the paths were different.

I've got quite a lot to learn. Thanks for helping me out.

BTW...chipperMDW...you were also right. Just for fun, I tried "locate" and it was a bunch quicker than a recursive search.

I managed to get two lessons from one thread :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top