You are not logged in.

#1 2009-05-05 17:26:31

degmic71
Member
Registered: 2009-02-03
Posts: 122

Cannot get static IP to work

Ive tried so hard to get a static address to stick.  Can anyone help?

/etc/rc.conf :

HOSTNAME="DEATH_STAR"

# Use 'ifconfig -a' or 'ls /sys/class/net/' to see all available interfaces.
#
# Interfaces to start at boot-up (in this order)
# Declare each interface then list in INTERFACES
#   - prefix an entry in INTERFACES with a ! to disable it
#   - no hyphens in your interface names - Bash doesn't like it
# 
# DHCP:     Set your interface to "dhcp" (eth0="dhcp")
# Wireless: See network profiles below
#
eth0="eth0 192.168.1.28 netmask 255.255.255.0 broadcast 192.168.1.255"
INTERFACES=(!eth0)

# Routes to start at boot-up (in this order)
# Declare each route then list in ROUTES
#   - prefix an entry in ROUTES with a ! to disable it
#
gateway="default gw 192.168.0.1"
ROUTES=(!gateway)
# Daemons to start at boot-up (in this order)
#   - prefix a daemon with a ! to disable it
#   - prefix a daemon with a @ to start it up in the background
#
DAEMONS=(syslog-ng !network netfs crond alsa hal networkmanager avahi-daemon networkmanager-dispatcher sshd fam gdm)

I am using network manager but using the GUI of that in "Preferences" menu, it is greyed out for automatically*


Please help

Offline

#2 2009-05-05 17:29:40

djgera
Developer
From: Buenos Aires - Argentina
Registered: 2008-12-24
Posts: 723
Website

Re: Cannot get static IP to work

remove the "!" from INTERFACES ROUTES and DAEMONS wink

Offline

#3 2009-05-05 17:29:54

.:B:.
Forum Fellow
Registered: 2006-11-26
Posts: 5,819
Website

Re: Cannot get static IP to work

Given the fact you uncommented eth0 (see the exclamation mark), it is quite logical it's not working wink. You tell Arch not to set it up...

Edit: djgera is more on top of things lol


Got Leenucks? :: Arch: Power in simplicity :: Get Counted! Registered Linux User #392717 :: Blog thingy

Offline

#4 2009-05-05 17:31:32

degmic71
Member
Registered: 2009-02-03
Posts: 122

Re: Cannot get static IP to work

I believe I did that and no, luck but I will try again, sorry for being new at this.  Do I do "/etc/rc.d/network restart" to try it?

Offline

#5 2009-05-05 17:39:31

degmic71
Member
Registered: 2009-02-03
Posts: 122

Re: Cannot get static IP to work

Remove the ! from the "!network"???  In the network manager wiki on Arch it says not to do that.  I am using network manager for when I manage wireless, but NM will* parse rc.conf, hmmmm

Last edited by degmic71 (2009-05-05 17:40:14)

Offline

#6 2009-05-05 17:45:38

degmic71
Member
Registered: 2009-02-03
Posts: 122

Re: Cannot get static IP to work

I get this now:

[mikeyd@DEATH_STAR ~]$ sudo /etc/rc.d/network restart
:: Stopping Network                                                                                                                        [DONE] 
:: Starting Network                                                                                                                        [BUSY] 
SIOCSIFNETMASK: Cannot assign requested address
SIOCSIFBRDADDR: Cannot assign requested address
SIOCADDRT: No such process

Last edited by degmic71 (2009-05-05 17:46:25)

Offline

#7 2009-05-05 17:48:48

brisbin33
Member
From: boston, ma
Registered: 2008-07-24
Posts: 1,796
Website

Re: Cannot get static IP to work

hmmm ignore me... i just read networkmanager wiki, not what i thought was going on.

i would still verify that it all works with dhcp, then make sure you're picking a static IP _outside_ your routers dynamic range.  you can check that on the routers admin page.

Last edited by brisbin33 (2009-05-05 17:57:51)

Offline

#8 2009-05-05 17:49:39

djgera
Developer
From: Buenos Aires - Argentina
Registered: 2008-12-24
Posts: 723
Website

Re: Cannot get static IP to work

ooh, sorry, I don't know networkmanager, then just ignore me. The "tips" are for standard Arch Linux setup.

Offline

#9 2009-05-05 18:04:13

degmic71
Member
Registered: 2009-02-03
Posts: 122

Re: Cannot get static IP to work

I could remove network manager possibly

Offline

#10 2009-05-05 18:09:30

brisbin33
Member
From: boston, ma
Registered: 2008-07-24
Posts: 1,796
Website

Re: Cannot get static IP to work

degmic71 wrote:

I get this now:

[mikeyd@DEATH_STAR ~]$ sudo /etc/rc.d/network restart
:: Stopping Network                                                                                                                        [DONE] 
:: Starting Network                                                                                                                        [BUSY] 
SIOCSIFNETMASK: Cannot assign requested address
SIOCSIFBRDADDR: Cannot assign requested address
SIOCADDRT: No such process

sidenote: if at that time you were using networkmanager shouldn't you have done

sudo /etc/rc.d/networkmanager restart

to test?

Offline

#11 2009-05-05 18:10:49

degmic71
Member
Registered: 2009-02-03
Posts: 122

Re: Cannot get static IP to work

I believe it is "/etc/rc.d/network restart"???  I am going to remove network manager and just modify rc.conf from now on

Offline

#12 2009-05-05 18:13:10

Hrod beraht
Member
Registered: 2008-09-30
Posts: 186

Re: Cannot get static IP to work

degmic71 wrote:
eth0="eth0 192.168.1.28 netmask 255.255.255.0 broadcast 192.168.1.255"
gateway="default gw 192.168.0.1"

This does not compute. If the static address of your machine and your broadcast are 192.168.1.x then your gateway should also be 1, not 0, as in 192.168.1.1, not 192.168.0.1

Bob

Offline

#13 2009-05-05 18:15:38

brisbin33
Member
From: boston, ma
Registered: 2008-07-24
Posts: 1,796
Website

Re: Cannot get static IP to work

sounds like an ok approach.  i can recommend netcfg to manage wireless... it comes with it's own rc.conf quirks but the wiki is easy to follow.

also, the /etc/rc.d/* scripts are exactly the same as names inside the DAEMONS array (that's what the DAEMONS array calls when you boot).  therefore, if you're blacklisting network (!network) and using networkmanager, then _that's_ what you'll want to restart when testing.  otherwise /etc/rc.d/network restart will restart _that_ daemon (which doesn't like the whole !eth0 !gateway thing that network manager requires)... wow is networking confusing to talk about. 

you've got to pick an approach and go with it, b/c they are, in this case, mutually exclusive

bob, you may have something there... so many archers were blinded by the !'s in odd places...

Last edited by brisbin33 (2009-05-05 18:18:29)

Offline

#14 2009-05-05 18:57:22

perbh
Member
From: Republic of Texas
Registered: 2005-03-04
Posts: 765

Re: Cannot get static IP to work

Here is mine (for whatever it is worth):

eth0="eth0 192.168.1.6 netmask 255.255.255.0 broadcast 192.168.1.255"
INTERFACES=(eth0)
gateway="default gw 192.168.1.1"
ROUTES=(gateway)
#NETWORKS=(main)
DAEMONS=(syslog-ng network netfs crond hal xinetd portmap nfslock nfsd sshd gpm cups)

and note, note, note!!
You _must_ have a valied nameserver in /etc/resolv.conf

Offline

#15 2009-05-05 19:59:41

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,597
Website

Re: Cannot get static IP to work

I'm not using the network manager, but I am using a static IP addy.  See post #12 in this thread for the settings I used to get this working.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#16 2009-05-05 22:54:21

fphillips
Member
From: Austin, TX
Registered: 2009-01-24
Posts: 202

Re: Cannot get static IP to work

From NetworkManager 0.7.1 changes:

"The default "Auto eth0″ connection is now read/write"

So if you're like me and want eth0 to be static you can delete the "auto eth0" that uses DHCP and can't be changed in 0.7.0.

http://blogs.gnome.org/dcbw/2009/04/16/ … nager-071/

Offline

Board footer

Powered by FluxBB