LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Fedora
User Name
Password
Fedora This forum is for the discussion of the Fedora Project.

Notices

Reply
 
Search this Thread
Old 05-23-2005, 11:49 AM   #1
ccerino
LQ Newbie
 
Registered: Dec 2004
Posts: 19

Rep: Reputation: 0
ifconfig doesn't work


When I am logged in as a user or as root, I am told that ifconfig isn't a valid command, so I figured that for some reason it wasnt put in my /usr/bin command list so i cd to the sbin dir where it is and tried it from there, still no luck. I have never had this problem before. What is up with this command?
 
Old 05-23-2005, 12:03 PM   #2
Boby
Member
 
Registered: Feb 2004
Location: Sighisoara/Cluj-Napoca (Romania)
Distribution: CentOS 4, Fedora Core 6
Posts: 781

Rep: Reputation: 31
Gain root access with
Code:
su -
.
Then try again ifconfig.

Boby
 
Old 05-23-2005, 01:10 PM   #3
ccerino
LQ Newbie
 
Registered: Dec 2004
Posts: 19

Original Poster
Rep: Reputation: 0
already tried that remember. Pleas read my original post.
 
Old 05-23-2005, 01:13 PM   #4
win32sux
Guru
 
Registered: Jul 2003
Location: Los Angeles
Distribution: Ubuntu
Posts: 9,870

Rep: Reputation: 371Reputation: 371Reputation: 371Reputation: 371
Quote:
Originally posted by ccerino
already tried that remember. Pleas read my original post.
your original post doesn't say you tried the "-" option...
 
Old 05-23-2005, 04:03 PM   #5
ccerino
LQ Newbie
 
Registered: Dec 2004
Posts: 19

Original Poster
Rep: Reputation: 0
Alright here is an update.

while i am longed in as my self i still have the problem. if I su in i still have the problem. if i su - in idont have the problem, and if i directly log in as root i dont have the problem.
 
Old 05-23-2005, 04:10 PM   #6
snarkout
Member
 
Registered: Apr 2005
Location: The Land Of Entrapment
Posts: 77

Rep: Reputation: 15
Are you just running "ifconfig" to see your interfaces, or are you assigning an IP or something? Meaning, is the issue possibly syntax? What do you get if you do a "which ifconfig" or a "type ifconfig"? In /sbin did you execute "ifconfig" or "./ifconfig"?

edit: I missed your last post - your problem is your "environment" and specifically your path. Either log in as root, or use "su -" to remedy the issue (as you've seen). This is not a bug, it's a feature.

Last edited by snarkout; 05-23-2005 at 04:34 PM.
 
Old 05-23-2005, 04:22 PM   #7
terrapin24h
LQ Newbie
 
Registered: Feb 2005
Location: Upstate NY
Distribution: FC3
Posts: 16

Rep: Reputation: 0
ccerino--
reason is that the "su" command grants you root privs, but does NOT load the root user environment(more pointedly, you don't get root's "PATH" variable) doing the "su -" gets you root's path and IIRC home dir too. The same thing as logging in as root. It's not a problem, it's actually by design. By default only root can do ifconfig, and the system will only find it when root's enviro is loaded
 
Old 05-24-2005, 02:33 AM   #8
Boby
Member
 
Registered: Feb 2004
Location: Sighisoara/Cluj-Napoca (Romania)
Distribution: CentOS 4, Fedora Core 6
Posts: 781

Rep: Reputation: 31
Quote:
Either log in as root...
I wouldn't recommend logging in as root in X!

Boby
 
Old 05-24-2005, 09:09 PM   #9
dareino
Member
 
Registered: Mar 2004
Location: S.F.,Ca
Distribution: FC4
Posts: 82

Rep: Reputation: 15
Talking

ccerino--
reason is that the "su" command grants you root privs, but does NOT load the root user environment(more pointedly, you don't get root's "PATH" variable) doing the "su -" gets you root's path and IIRC home dir too. The same thing as logging in as root. It's not a problem, it's actually by design. By default only root can do ifconfig, and the system will only find it when root's enviro is loaded


dang...I just learned something today!!!!! Im such a newb
thxs
dareino
 
Old 08-04-2009, 11:53 PM   #10
brian2009
LQ Newbie
 
Registered: Aug 2009
Posts: 13

Rep: Reputation: 1
Thank You

Just want to say thank you from a newbie on everyone's insight
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ifconfig amounst other commands doesn't work steveman2000 Linux - Newbie 6 10-21-2005 05:15 PM
ifconfig & iwconfig do not work Koneko Linux - Newbie 3 08-06-2005 11:04 PM
ifconfig doesn't work woodland56 Linux - Newbie 7 03-09-2005 02:34 PM
My commands dont work. ifconfig ? slice4e Linux - General 5 05-09-2003 12:51 AM
ifconfig won't work Hollywood W Linux - Newbie 9 04-17-2003 05:07 AM


All times are GMT -5. The time now is 01:00 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration