Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#24690 - [initscripts] allow static IP address without gateway

Attached to Project: Arch Linux
Opened by Matthias Dienstbier (fs4000) - Saturday, 11 June 2011, 15:46 GMT
Last edited by Tom Gundersen (tomegun) - Sunday, 19 June 2011, 17:02 GMT
Task Type Bug Report
Category Arch Projects
Status Closed
Assigned To Tom Gundersen (tomegun)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

I know you don't intend to extend the network daemon, but could at least the use of static IP without a gateway be implemented?

There are people that don't use the LAN for connecting to the internet.
This task depends upon

Closed by  Tom Gundersen (tomegun)
Sunday, 19 June 2011, 17:02 GMT
Reason for closing:  Fixed
Comment by Dave Reisner (falconindy) - Saturday, 18 June 2011, 15:41 GMT
Despite being an uncommon use case, I think this is a fair request. It's also a +1/-1 patch.
Comment by Tom Gundersen (tomegun) - Saturday, 18 June 2011, 16:05 GMT
@dave: looks good. I'll pull it if it is in your public repo.
Comment by Dave Reisner (falconindy) - Saturday, 18 June 2011, 16:08 GMT
it is, now!
Comment by Matthias Dienstbier (fs4000) - Saturday, 18 June 2011, 16:12 GMT
If gateway is unset it will still fail with "Error: static address defined without gateway!"
And in network_down you can't delete route default if it wasn't set. AFAIK "ip link set dev $interface down" deletes all routes, too.
Comment by Dave Reisner (falconindy) - Saturday, 18 June 2011, 16:17 GMT
Oops. Needs more coffee... Yeah, you're right -- the ip link does bring down the route as well. Not sure why I left this in. My port from net-tools was probably a bit too 1:1.
Comment by jason barney (jasonx) - Sunday, 19 June 2011, 14:04 GMT
still doesnt work, /etc/rc.d/network should not exit if the variable $gateway is not defined (it was actually a +2/-2 patch, hehe)
Comment by Dave Reisner (falconindy) - Sunday, 19 June 2011, 14:16 GMT
I'm bad at this. Ok, new patch pushed to github. I swear I tested it this time, using:

interface=eth0
address=10.0.2.240

# ip addr; ip route
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
link/ether 52:54:00:12:34:56 brd ff:ff:ff:ff:ff:ff
inet 10.0.2.240/24 brd 10.0.2.255 scope global eth0
10.0.2.0/24 dev eth0 proto kernel scope link src 10.0.2.240

https://github.com/falconindy/initscripts-arch/commit/824567cb23ed0bab4ed4568be139ee0c75d7598d
Comment by Tom Gundersen (tomegun) - Sunday, 19 June 2011, 17:02 GMT
New fix pushed out.

Loading...