LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 11-26-2008, 09:53 PM   #1
andy1974
Member
 
Registered: Jun 2007
Posts: 85

Rep: Reputation: 15
static ip on F10 box


hello all i am testing F10 and having a issue with setting up the static ip on the box.


ip 192.168.1.50
subnet mask 255.255.255.0
default gateway 192.168.1.1

when i try to save the settings the subnet mask changes to 192.168.1.1
therefor not making a connection.


anyone else having a issue?
 
Old 11-27-2008, 09:56 AM   #2
hans21
Member
 
Registered: Sep 2005
Location: Serbia
Distribution: Centos 5.2-x86_64, Fedora 10, RHEL 5
Posts: 60

Rep: Reputation: 15
Have you stopped the NetworkManager service?

Personally, I've never liked Network Manager, though, someone told me once that Network Manager is very useful for laptops and handling wireless network connections.

Since I won't be installing F10 for another few days, I don't know how helpful will I be. Letting Network manager set up network in anaconda and throughout the installation process makes me a bit sceptical.

Last edited by hans21; 11-27-2008 at 10:01 AM.
 
Old 11-27-2008, 11:07 AM   #3
nbcohen
Member
 
Registered: Mar 2003
Location: Northern Virginia
Distribution: RH Enterprise, Fedora
Posts: 96

Rep: Reputation: 17
I have installed F10 from both the live CD and the DVD. In both cases, I was unable to set up the static IP information using system-config-network - it simply would not save the file.
I manually edited the ifcfg-eth0 file in sysconfig/networking...

But I still had to stop the NetworkManager (remove it from /etc/init.d) in order to get the network to start (you have to enable the /etc/init.d/network function too).

I have installed KDE but not Gnome - maybe you need Gnome to run NetworkManger??
But doing the network setup manually did work...

Hope that helps,

nbc
 
Old 11-27-2008, 12:51 PM   #4
andy1974
Member
 
Registered: Jun 2007
Posts: 85

Original Poster
Rep: Reputation: 15
Yea i dont like the NetworkManager at all . i did stop it. i will manually edit the config and see how it goes but it looks like the system-config-network in gui is buggy. can you help me out ? which file do i edit the one in the default folder? or the the devices folder?? also what should the config format look like for a static ip?

Last edited by andy1974; 11-27-2008 at 12:59 PM.
 
Old 11-27-2008, 02:50 PM   #5
hans21
Member
 
Registered: Sep 2005
Location: Serbia
Distribution: Centos 5.2-x86_64, Fedora 10, RHEL 5
Posts: 60

Rep: Reputation: 15
Ok, now, this is the content of my /etc/sysconfig/network-scripts/ifcfg-eth0 file which defines network parameters:

DEVICE=eth0
BOOTPROTO=none
BROADCAST=192.168.1.255
HWADDR=00:1a:92:b0:4f:10
IPADDR=192.168.1.2
IPV6INIT=no
IPV6_AUTOCONF=yes
NETMASK=255.255.255.0
NETWORK=192.168.1.0
ONBOOT=yes
NM_CONTROLLED=no
TYPE=Ethernet
USERCTL=no
PEERDNS=yes
GATEWAY=192.168.1.1

DNS2=82.117.194.3
SEARCH=sbb.rs
DNS1=82.117.194.2

This is the static configuration which I use on my system. Relevant lines for your case would be and would look something like:

BOOTPROTO=none (or static, just not "dhcp")
BROADCAST=192.168.1.255
IPADDR=192.168.1.50
NETMASK=255.255.255.0
NETWORK=192.168.1.0
ONBOOT=yes
NM_CONTROLLED=no
GATEWAY=192.168.1.1

Now go ahead, backup your /etc/sysconfig/network-scripts/ifcfg-eth0 and then alter it to your needs. Also, you'll probably need to add some lines to /etc/resolv.conf (i.e. addresses of your DNS servers)

My /etc/resolv.conf contains:

search sbb.rs

nameserver 82.117.194.2
nameserver 82.117.194.3

(of course, these IP addresses should be replaced with addresses of your DNS servers)

Oh, yea, you'll have to becom priviledged user to do this. Also, make sure you deactivate Network Manager before you proceed by typing:

chkconfig NetworkManager off - this prevents it from starting at boot time

and make sure you do a

service NetworkManger stop - in the current session to stop currently running network manager on your system

then you do

service network restart

and it should work.



Best Regards

Last edited by hans21; 11-27-2008 at 02:55 PM. Reason: Some additions
 
Old 11-27-2008, 09:56 PM   #6
PreacherBill
Member
 
Registered: Nov 2006
Location: Louisville, KY
Distribution: CentOS 6
Posts: 41

Rep: Reputation: 15
I had this same problem. Here's what I did using Gnome as the desktop:

1. I allowed the machine to boot using dhcp to confirm that everything on the network was properly working (it was).

2. Went in to system-config-network via the system->administration->network menu item, giving the root password when asked.

3. Switched from "automatically obtain ip address..." to "statically set ip address..." and set the appropriate values in each field.

4. Made sure that "activate device when computer starts" was checked and that "controlled by network manager" was not checked.

5. Saved everything, exited system-config-network, opened a terminal window, became root, and shut down network managed (service NetworkManaged stop).

6. Opened up /etc/sysconfig/network-scripts/ifcfg-eth0 (immediately saving a backup copy), corrected the NETMASK value in the file, and added BROADCAST and DNS1 settings and their values (based on the information I have, I assume that these last two settings need to be there. I didn't try it without them). Saved the file and exited the editor.

7. Made sure network manager wouldn't srtart on boot (chkconfig NetworkManager off), exited everything, and rebooted the system.

When the system rebooted, I had to go back into system-config-network and tell it to activate eth0 - even though the config file said it should be active on boot, it didn't activate the first time. I rebooted again, and the network came up just fine.

It seems fairly obvious here that someone writing the code put the wrong variable in a certain spot, and no one caught it. I know it's easy to do - I've done it. But this is still such an obvious thing that it should have been caught. I can't believe that no one in all the testing didn't try to set a static ip address. But at least it's easily fixable!

Anyway - it worked for me.

Bill
 
Old 11-27-2008, 10:10 PM   #7
PreacherBill
Member
 
Registered: Nov 2006
Location: Louisville, KY
Distribution: CentOS 6
Posts: 41

Rep: Reputation: 15
Well...I guess I should have paid attention to the post in front of my last one, since I pretty much repeated what had already bee said. Just put it doen to senility

On another note, i just checked another machine running fedora 9 using network manager, and everything is working as it should. So this was working in 9, and now seems to be broken in 10!

I guess that's just the way things go.

Again, sorry about duplicating the previous post

Bill
 
Old 11-28-2008, 08:24 AM   #8
andy1974
Member
 
Registered: Jun 2007
Posts: 85

Original Poster
Rep: Reputation: 15
yea , somewhere along the line there was somthing changed and missed.

Last edited by andy1974; 11-28-2008 at 08:28 AM.
 
Old 11-28-2008, 05:18 PM   #9
PreacherBill
Member
 
Registered: Nov 2006
Location: Louisville, KY
Distribution: CentOS 6
Posts: 41

Rep: Reputation: 15
Well, I obviously spoke too soon. I had to reboot the machine here a few minutes ago, and eth0 interface did not come up on its own. I once again had to manually start it. This is irritating at best since I have several nfs shares mounted from other machines on this one that mount at boot time. It's not a killer, but it is frustrating, particularly when this worked fine in fedora 9.

So if anyone has any other suggestions, please speak up!

Bill
 
Old 11-28-2008, 08:49 PM   #10
nbcohen
Member
 
Registered: Mar 2003
Location: Northern Virginia
Distribution: RH Enterprise, Fedora
Posts: 96

Rep: Reputation: 17
Same thing happened to me. I installed Webmin and used that to mark the 'network' command as being started on boot and that seems to have taken care of the problem...

nbc
 
Old 11-28-2008, 10:30 PM   #11
PreacherBill
Member
 
Registered: Nov 2006
Location: Louisville, KY
Distribution: CentOS 6
Posts: 41

Rep: Reputation: 15
Quote:
Originally Posted by nbcohen View Post
Same thing happened to me. I installed Webmin and used that to mark the 'network' command as being started on boot and that seems to have taken care of the problem...

nbc
OK - I'll give that a try tomorrow and see if it solves the problem.
 
Old 11-30-2008, 04:26 PM   #12
hans21
Member
 
Registered: Sep 2005
Location: Serbia
Distribution: Centos 5.2-x86_64, Fedora 10, RHEL 5
Posts: 60

Rep: Reputation: 15
Hello again,

by now I've installed Fedora 10 and configured my NIC with static IP address. It worked without a glitch. Here is the
/etc/sysconfig/network-scripts/ifcfg-eth0


# Marvell Technology Group Ltd. 88E8001 Gigabit Ethernet Controller
DEVICE=eth0
HWADDR=00:1a:92:b0:4f:10
ONBOOT=yes
BOOTPROTO=none
NETMASK=255.255.255.0
IPADDR=192.168.1.2
NETWORK=192.168.1.0
USERCTL=no
PEERDNS=yes
IPV6INIT=no
NM_CONTROLLED=no
GATEWAY=192.168.1.1
TYPE=Ethernet


One more thing, You are definitely right about graphical network configuration - it sucks. When configuring my NIC with address of 192.168.1.2, subnet 255.255.255.0, and gateway 192.168.1.1, and saving configuration -> subnet field gets assigned with 192.168.1.1 value?!?
Therefore, I resorted to changing the file directly via vim editor and everything went well. Of course, once again, you'll have to edit /etc/resolv.conf too.

Best Regards.
 
Old 01-27-2009, 04:19 AM   #13
beawolf
LQ Newbie
 
Registered: Jan 2009
Posts: 1

Rep: Reputation: 0
Autostart of Network

If you deactivate NetworkManager you may need the network service automatically start on boot. Just follow these steps (You may need to be root to do these):

1. On terminal, type "ntsysv" without quotes.
2. Highlight "network" by using arrow keys, and press Spacebar to mark it.
3. Press Tab to highlight "Ok", and press Enter to save and exit.
 
Old 01-27-2009, 08:03 PM   #14
DinoFly
Member
 
Registered: Nov 2007
Distribution: Fedora, CentOS,
Posts: 72

Rep: Reputation: Disabled
Quote:
Originally Posted by hans21 View Post
One more thing, You are definitely right about graphical network configuration - it sucks.

Best Regards.
Definetly it sucks but you can use system-config-network-tui wich will give you back plain old network configuration tool.

By the way I think it will not work if you have a NetworkManager managing that device keep in mind follow what PrecherBill sugested (that is how I fixed the same problem), so you should turn that think off, by entring into a NetworkManager and editing a device (eth0) and I don't know for sure but I think the second tick is to enable and disable that feature just read it and you will see it. Than proceed with useful tips from the other guys editing /etc/sysconfig/network-scripts/ifcfg-ethX and restart the network service.

Don't have to reboot the system simply restart the network service with service network restart command.

By the way you wont have this problem if you run Fedora 10 on runlevel 3, at least I am not haveing it on that runlevel.

Quote:
Personally, I've never liked Network Manager, though, someone told me once that Network Manager is very useful for laptops and handling wireless network connections.
It is a life saviour if you use it with laptops and wireles and different network profiles, but only once you get it working right
 
  


Reply

Tags
fedora, ip, setup, static


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
Disable F10 for menu drop down titanandrews Linux - General 1 03-30-2011 12:31 PM
disable F10 from login screen? slvjerome Linux - Desktop 0 08-27-2008 11:23 AM
How do I assign a static IP to an interface on a Fedora Linux box? robcast Linux - Newbie 4 03-18-2008 12:37 PM
How to run Dyn. DNS on a static IP for a box on dhcp chuddy117 Linux - Networking 2 10-04-2004 08:10 AM
Setting up a static IP on linux box which obtains an IP via DHCP vxc69 Linux - Networking 19 07-13-2004 05:18 AM


All times are GMT -5. The time now is 07:40 PM.

Main Menu
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