IfConfig

Greetings,

I recently installed Fedora Core 4 on my desktop and it is duel booting with Windows XP.  When I go to the command prompt as root and type ifconfig it says command not found.  When I do hostname it says localhost.localdomain.  I don't remember in the installation being asked for the machine name.  I can connect to the internet.  I think I may be missing something from /etc/hosts.
LVL 2
palazziniAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

jrs_50Commented:
Guessing: 1) find the actual location of ifconfig using search 2)specify the full path name when attempting to run 3) consider updating your systems 'path.
0
freshprince27Commented:
Don't you mean IPCONFIG.
0
palazziniAuthor Commented:
No Ipconfig for windows ifconfig for linux.  jrs 50 I found ifconfig in sbin but still can't get it to execute.
0
Cloud Class® Course: CompTIA Healthcare IT Tech

This course will help prep you to earn the CompTIA Healthcare IT Technician certification showing that you have the knowledge and skills needed to succeed in installing, managing, and troubleshooting IT systems in medical and clinical settings.

naveedbCommented:
What happens when you try it? Any error message.

What are the permissions on it, can you post your output from ls -l /sbin/ifconfig

Did you try to execute it with /sbin/ifconfig ?
0
giltjrCommented:
When you say "you go to command prompt as root", what do you mean?  If you do just a plain "su" to root from your userid, you get your path, which by default does not include /sbin, which is where ifconfig exists.  If you do a "su -l" you will get roots path, which does include /sbin by default.

If you are logging on as root, then there is a problem as root should have /sbin in its path by default.
0
scrathcyboyCommented:
go to superuser status, then run ifconfig.
0
zzzztjCommented:
The domain that you're getting doesn't relate in any way to your internet connection. That is for the unix yp service (aka NIS). Yp was the original Yellow pages service the syncs users and groups (and other files) across a network.

In your etc hosts all you should have is

127.0.0.0 localhost    # this is a ref to your own machine

xx.xx.xx.xx yourPC     # This is the address of your network card, which appears to be working because you say you can connect to the web
0
palazziniAuthor Commented:
sbin/ifconfig worked.  Is there a way to configure so all I have to type is ifconfig?
0
giltjrCommented:
A couple ways to do it, I modify my .bash_profile (in my home directory) to add /sbin to the path.

0
naveedbCommented:
So you are not loggin in as root user? As suggested by giltjr, update your .bash_profile. You will see something like

PATH:$PATH:$HOME/bin

at the end just add :/sbin so it reads

PATH:$PATH:$HOME/bin:/sbin

0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
zzzztjCommented:
Although I have to point out that adding the /usr/sbin or /sbin (usually symlinked) to a non root user path is generally considered poor practise and also a performance hindrance when not performing root duties.  Better to say "right now I'm doing some admin work" and source a script that changes your environment for admin tasks.

0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux Distributions

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.