Summary: | sys-apps/openrc-0.7.0 : ipv6 route configuration broken when using "-f <family>" | ||
---|---|---|---|
Product: | Gentoo Hosted Projects | Reporter: | Olivier Huber <oli.huber> |
Component: | OpenRC | Assignee: | OpenRC Team <openrc> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | gentoobugs, jmbsvicetto |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | openrc:oldnet | ||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 394205 | ||
Attachments: |
patch proposal
log |
Description
Olivier Huber
2011-03-10 13:50:05 UTC
i cant see how your new "shift" works when the code right after it checks -A/-f/etc... + # get rid of the first argument, it's useless with the iproute2 module + shift + if [ "$1" = "-A" -o "$1" = "-f" -o "$1" = "-family" ]; then family="-f $2" shift; shift fi Created attachment 265509 [details]
log
This is part of the output given by /etc/init.d/net.eth0 --debug restart
The arguments given to _add_route are -host -f inet6 default via 2001:41d0:1:efff:ff:ff:ff:ff
In this case, shift removes -host from the list of argument.
Sorry if this wasn't clear enough.
Why does your conf.d/net even have the -f inet6? routes_eth0="default via 2001:41d0:1:efff:ff:ff:ff:ff" Works perfectly for me. (In reply to comment #3) > Why does your conf.d/net even have the -f inet6? > routes_eth0="default via 2001:41d0:1:efff:ff:ff:ff:ff" > Works perfectly for me. you're right. I think this comes from the fact that to show the ipv6 routes, ip needs the "-6" switch (for instance ip -6 r). When I tried to add my ipv6 route, I look at the examples, but I wasn't satisfied with it, so I looked at the code and I saw the family detection code ... i dont think the proposed patch is the way we want to go. rather than blindly shifting away arguments, we should avoid adding wrong ones in the first place. can you please install openrc-9999, ensure you get commit 879e1ac or newer, and then test this, posting the output from the commands. 1. ip -f inet6 route add default via 2001:41d0:1:efff:ff:ff:ff:ff dev eth0 ip -f inet6 route del default via 2001:41d0:1:efff:ff:ff:ff:ff dev eth0 2. Ensure this entry is in your conf.d/net: routes_eth0="default via 91.121.174.254 -f inet6 default via 2001:41d0:1:efff:ff:ff:ff:ff" 3. /etc/init.d/net.eth0 --verbose stop 4. /etc/init.d/net.eth0 --verbose start No feedback from user. I'm pretty sure it works, and it's in for the next release. |