assign static IP from CLI in Fedora 5

Posted on 2006-07-09
Last Modified: 2008-01-09
I would like to assign static IP address to eth0 from command line interface in Fedora 5. I did look around. I found that:
ifconfig eth0 netmask up
Should do it. However, whenver i typed it returns:
-bash: ifconfig: command not found

Than i tryed:
./ ifconfig eth0 netmask up
-bash: ifconfig: command not found

I tryed other commands(i.e. ifstatus) with the same outcome. How do i assign static IP to eth0 from CLI in Fedora 5?
Thank YOu,
Question by:margotsk
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
LVL 19

Expert Comment

ID: 17071078
It sounds like your environment variable PATH is not including the location of ifconfig. Not a Fedora user myself, but it should be in /sbin

Try /sbin/ifconfig eth0 192.168..... etc
LVL 19

Expert Comment

ID: 17071082
Also, Fedora (at least it used to) has locate installed by default, so try locate ifconfig

It'll be there, somewhere..
LVL 43

Expert Comment

ID: 17071943
You propably trying run this command as regular user. Try as root
Schedule a Tour of the ATEN booth at InfoComm 2017

Tour the ATEN booth to see the the Latest Addition to the Modular Matrix Switch Series, New 4K HDMI Over IP Extender and more! Enter ATEN's Ultimate Giveaway Sweepstakes for a chance to win one of several great prizes, including an ATEN US7220 2-Port Thunderbolt 2 Sharing Switch!

LVL 26

Accepted Solution

jar3817 earned 500 total points
ID: 17071966
You can also edit the /etc/sysconfig/network-scripts/ifcfg-eth0 file. You should make it look something like this:


Then just bring the interface down and up again: /sbin/ifdown eth0 && /sbin/ifup eth0
LVL 24

Expert Comment

ID: 17078362
I prefer to use the system-config tool... there is a system-config-network-tui for CLI.
as ravenpl said.. run as root:

$ su -
enter your root password
# system-config-network-tui

Author Comment

ID: 17079102
Thanks for response,
I followed jar3817 suggestion and it worked. I am sure other sollution may work, but jar3817 suggestion seemed more fit in our case. Thank You for your responses

Featured Post

Easy, flexible multimedia distribution & control

Coming soon!  Ideal for large-scale A/V applications, ATEN's VM3200 Modular Matrix Switch is an all-in-one solution that simplifies video wall integration. Easily customize display layouts to see what you want, how you want it in 4k.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
This video Micro Tutorial shows how to password-protect PDF files with free software. Many software products can do this, such as Adobe Acrobat (but not Adobe Reader), Nuance PaperPort, and Nuance Power PDF, but they are not free products. This vide…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…

718 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question