Fedora Linux Support Community & Resources Center

Go Back   FedoraForum.org > Fedora 17/18 > Using Fedora
FedoraForum Search

Forgot Password? Join Us!

Using Fedora General support for current versions. Ask questions about Fedora and it's software that do not belong in any other forum.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 18th May 2012, 04:59 AM
Mainsun Offline
Registered User
 
Join Date: Feb 2012
Location: Hong Kong
Posts: 26
windows_7firefox
Question static ip with Fedora 16 minimal install

Hi all,
I have installed Fedora 16 in text mode. I prefer Fedora using a static ip. I have done the fellowing steps :
1) edit /etc/sysconfig/network-scipts/ifcfg-eth0
PHP Code:
    HWADDR=00:01:02:03:04:05
    TYPE
=Ethernet
    NAME
="Static Ethernet"
    
DEVICE=eth0
    UUID
=5fb16bd2-3bb4-7ffb-45f1-d6edd65f3e53
    BOOTPROTO
=none
    ONBOOT
=yes
    IPADDR
=192.168.1.191    
    GATEWAY
=192.168.1.1
    NETMASK
=255.255.255.0
    DNS1
=1.2.3.4
    DNS2
=2.3.4.5 
2) service network restart
3) ifdown eth0; ifup eth0
The result is what I want!
However, when the machine is rebooted, the ip is using the DHCP (eg 192.168.1.100), I have to run [ ifdown eth0; ifup eth0 ] in order the ip is 192.168.1.191!
Can someone suggest what's wrong?
Reply With Quote
  #2  
Old 18th May 2012, 06:17 AM
RupertPupkin's Avatar
RupertPupkin Offline
Registered User
 
Join Date: Nov 2006
Location: Detroit
Posts: 4,722
linuxfedorafirefox
Re: static ip with Fedora 16 minimal install

I'm not sure if you need the UUID line. Also, try adding the following lines:
Code:
NM_CONTROLLED="no"
USERCTL="no"
Make sure the network service is enabled and started, using these commands (as root):
Code:
systemctl enable network.service
systemctl start network.service
You can check the status of the network service with this command:
Code:
systemctl status network.service
If all that doesn't work then try uninstalling NetworkManager, which in my experience can be flaky with static IPs.
__________________
OS: Fedora 18 x86_64 | CPU: AMD64 3700+ 2.2GHz | RAM: 2GB PC3200 DDR | Disk: 160GB PATA | Video: ATI Radeon 7500 AGP 64MB | Sound: Turtle Beach Santa Cruz CS4630 | Ethernet: Realtek 8110SC
Reply With Quote
  #3  
Old 18th May 2012, 07:43 AM
Mainsun Offline
Registered User
 
Join Date: Feb 2012
Location: Hong Kong
Posts: 26
windows_7firefox
Re: static ip with Fedora 16 minimal install

ths RupertPupkin ,
I have tried to append
NM_CONTROLLED
USERCTRL
to ifcfg-eth0
it doesnt help
I am sure network service is running correctly.
But still , I have to restart the eth0 before the static ip works after each reboot.
ps:
In minimal installation, NetworkManager is not installed in default
Reply With Quote
  #4  
Old 18th May 2012, 02:51 PM
smr54 Online
Registered User
 
Join Date: Jan 2010
Posts: 5,019
linuxfirefox
Re: static ip with Fedora 16 minimal install

In other posts, stevea has pointed out that there are various and sundry files affected by network--for better or worse, I have no idea, but at any rate, his recommendation which I follow in Fedora is to install system-config-network (or system-config-network-tui if you don't want X) and use that. It apparently writes properly to all the necessary files.

I haven't had to do this in RHEL6.x and its clones, but in Fedora I have--more accurately, I tried on a Fedora, say, 13 or 14, it didn't work, and I said the heck with it and used system-config-tui. (Without doublechecking had I mistyped something or any other research).
Reply With Quote
  #5  
Old 18th May 2012, 03:20 PM
jpollard Online
Registered User
 
Join Date: Aug 2009
Location: Waldorf, Maryland
Posts: 6,150
linuxfirefox
Re: static ip with Fedora 16 minimal install

Not all the files used by NetworkManager are documented.

If you want it to work reliably (and have some VMs to boot) disable NetworkManager, and enable network.

This will use the files properly.

Network manager seems to only work with wireless in a reliable manner.
Reply With Quote
  #6  
Old 18th May 2012, 04:39 PM
smr54 Online
Registered User
 
Join Date: Jan 2010
Posts: 5,019
linuxfirefox
Re: static ip with Fedora 16 minimal install

I didn't even mean with NetworkManager.
Actually, with system-config-tui (not sure about the GUI version) it leaves the file controlled by NM. I have to, after running the tool, manually change NM_CONTROLLED to no.

I believe the plan is to eventually make NM the drop in network tool. Judging from these forums however, it seems that my avoidance of it helps me avoid many issues.
Reply With Quote
  #7  
Old 18th May 2012, 06:47 PM
jpollard Online
Registered User
 
Join Date: Aug 2009
Location: Waldorf, Maryland
Posts: 6,150
linuxfirefox
Re: static ip with Fedora 16 minimal install

It used to work fairly well, in Fedora 14, with warnings about using it when running VMs (and it sucked there)

While testing F16 I found it would not setup the network properly if you had two network interfaces (one internal, one DHCP -once it screwed up the default route it would not reset it), not to mention still not working properly with VMs (it seemed to be even worse).

Since I use VMs to test distributions that made it totally unusable.
Reply With Quote
Reply

Tags
fedora, install, minimal, minimal install, static, static ip

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
F14: Minimal install, minimal packages for X, KDE, NVIDIA darlingm Guides & Solutions (No Questions) 5 2nd May 2012 06:37 PM
How to do a minimal install with minimal GNOME3 YellowAries Installation and Live Media 7 15th April 2012 04:44 PM
Fedora 16 Minimal install Adunaic Using Fedora 32 29th March 2012 02:05 PM
Fedora 8 Minimal Install - 247MB after post-install! 27spots Installation and Live Media 1 29th April 2008 01:35 PM


Current GMT-time: 13:06 (Wednesday, 19-06-2013)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat