Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
11-01-2007, 10:23 AM
|
#1
|
LQ Newbie
Registered: Nov 2007
Location: Harare Zimbabwe
Distribution: Red Hat 9
Posts: 17
Rep:
|
bash: ifconfig: command not found
[zeb@localhost zeb]$ ifconfig
bash: ifconfig: command not found
this is wat i get evrytym i use the ifconfig command. i understand i have to change my path. what is the reason for that and why how is that donee.
|
|
|
11-01-2007, 10:28 AM
|
#2
|
LQ Guru
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509
|
The command ifconfig is available to root only. As a normal user you won't use this command for safety reasons, since it may alter or break the network configuration.
|
|
|
11-01-2007, 10:55 AM
|
#3
|
Senior Member
Registered: Aug 2007
Location: South Carolina, U.S.A.
Distribution: Ubuntu, Fedora Core, Red Hat, SUSE, Gentoo, DSL, coLinux, uClinux
Posts: 1,302
Rep: 
|
Re: bash: ifconfig: command not found
Try running
# sudo bash
# which ifconfig
# echo $PATH
That will start bash with root privileges. The second command shows you where ifconfig is located. The third command shows you the setting of root's path.
|
|
|
11-01-2007, 01:12 PM
|
#4
|
Member
Registered: Oct 2006
Location: india
Distribution: fedora 8, ubuntu 10.10
Posts: 318
Rep:
|
hi,
First do a updatedb and then slocate ifconfig.
This will tell you where is the ifconfig executable in your machine. It is generally in /sbin dir.
there is a .bash_profile file in your home dir. ( if you are root then it is /root or else as user1 your home dir is /home/user1.)
open the file in editor and add the following :-
PATH=$PATH:/sbin
You should be through.
nishith
|
|
|
11-01-2007, 01:20 PM
|
#5
|
Member
Registered: Oct 2007
Location: MI
Distribution: Debian Slackware
Posts: 528
Rep:
|
If your running one of the Ubuntu's just type sudo ifconfig give passwd and your set.
Else su to root then ifconfig
|
|
|
11-01-2007, 02:01 PM
|
#6
|
Member
Registered: Oct 2007
Location: Norway
Distribution: Slackware 14.1
Posts: 446
Rep:
|
On ubuntu, all users are allowed to use ifconfig whitout parameters. So I guess he is not on a ubuntu machine.
|
|
|
11-01-2007, 07:20 PM
|
#7
|
Member
Registered: Jan 2006
Distribution: ArchLinux
Posts: 175
Rep:
|
Just type /sbin/ifconfig
|
|
|
11-02-2007, 03:14 AM
|
#8
|
LQ Newbie
Registered: Nov 2007
Location: Harare Zimbabwe
Distribution: Red Hat 9
Posts: 17
Original Poster
Rep:
|
regards
it worked with /sbin/ifconfig
|
|
|
All times are GMT -5. The time now is 01:55 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|