sysctl fails when default router device contains period

Bug #1627770 reported by Drago
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
devstack
Fix Released
Undecided
Drago

Bug Description

My default router is bond0.110

Running sudo sysctl -w net.ipv6.conf.bond0.110.accept_ra=2 fails because the path should be "...conf/bond.110/accept_ra..." but sysctl tries to access ""...conf/bond/110/accept_ra...".

stack.sh output:

++lib/neutron_plugins/services/l3:_neutron_create_public_subnet_v6:328 echo '|' gateway_ip '|' 2001:db8::2 '|' '|' id '|' 36317f8f-ca85-4483-80c3-cd8b6830e6f2 '|'
+lib/neutron_plugins/services/l3:_neutron_configure_router_v6:385 ipv6_id_and_ext_gw_ip='| gateway_ip | 2001:db8::2 | | id | 36317f8f-ca85-4483-80c3-cd8b6830e6f2 |'
+lib/neutron_plugins/services/l3:_neutron_configure_router_v6:386 local ipv6_ext_gw_ip
++lib/neutron_plugins/services/l3:_neutron_configure_router_v6:387 echo '|' gateway_ip '|' 2001:db8::2 '|' '|' id '|' 36317f8f-ca85-4483-80c3-cd8b6830e6f2 '|'
++lib/neutron_plugins/services/l3:_neutron_configure_router_v6:387 get_field 2
++functions-common:get_field:701 local data field
++functions-common:get_field:702 read data
++functions-common:get_field:703 '[' 2 -lt 0 ']'
++functions-common:get_field:706 field='$3'
++functions-common:get_field:708 awk '-F[ \t]*\\|[ \t]*' '{print $3}'
++functions-common:get_field:708 echo '| gateway_ip | 2001:db8::2 | | id | 36317f8f-ca85-4483-80c3-cd8b6830e6f2 |'
++functions-common:get_field:702 read data
+lib/neutron_plugins/services/l3:_neutron_configure_router_v6:387 ipv6_ext_gw_ip=2001:db8::2
+lib/neutron_plugins/services/l3:_neutron_configure_router_v6:388 local ipv6_pub_subnet_id
++lib/neutron_plugins/services/l3:_neutron_configure_router_v6:389 echo '|' gateway_ip '|' 2001:db8::2 '|' '|' id '|' 36317f8f-ca85-4483-80c3-cd8b6830e6f2 '|'
++lib/neutron_plugins/services/l3:_neutron_configure_router_v6:389 get_field 5
++functions-common:get_field:701 local data field
++functions-common:get_field:702 read data
++functions-common:get_field:703 '[' 5 -lt 0 ']'
++functions-common:get_field:706 field='$6'
++functions-common:get_field:708 echo '| gateway_ip | 2001:db8::2 | | id | 36317f8f-ca85-4483-80c3-cd8b6830e6f2 |'
++functions-common:get_field:708 awk '-F[ \t]*\\|[ \t]*' '{print $6}'
++functions-common:get_field:702 read data
+lib/neutron_plugins/services/l3:_neutron_configure_router_v6:389 ipv6_pub_subnet_id=36317f8f-ca85-4483-80c3-cd8b6830e6f2
+lib/neutron_plugins/services/l3:_neutron_configure_router_v6:393 [[ 4+6 == \6 ]]
+lib/neutron_plugins/services/l3:_neutron_configure_router_v6:398 is_service_enabled q-l3
+functions-common:is_service_enabled:2048 local xtrace
++functions-common:is_service_enabled:2049 set +o
++functions-common:is_service_enabled:2049 grep xtrace
+functions-common:is_service_enabled:2049 xtrace='set -o xtrace'
+functions-common:is_service_enabled:2050 set +o xtrace
+functions-common:is_service_enabled:2078 return 0
+lib/neutron_plugins/services/l3:_neutron_configure_router_v6:403 for d in '$default_v6_route_devs'
+lib/neutron_plugins/services/l3:_neutron_configure_router_v6:404 sudo sysctl -w net.ipv6.conf.bond0.110.accept_ra=2
sysctl: cannot stat /proc/sys/net/ipv6/conf/bond0/110/accept_ra: No such file or directory

Output of ip -6 route:

stack@devstack-server:/root$ ip -6 route
2001:4802:78fd:46::/64 dev bond0.103 proto kernel metric 256
fe80::/64 dev bond0 proto kernel metric 256
fe80::/64 dev bond0.103 proto kernel metric 256
fe80::/64 dev bond0.203 proto kernel metric 256
default via 2001:4802:78fd:46::1 dev bond0.103 metric 1024

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to devstack (master)

Fix proposed to branch: master
Review: https://review.openstack.org/377007

Changed in devstack:
assignee: nobody → Drago (dragorosson)
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to devstack (master)

Reviewed: https://review.openstack.org/377007
Committed: https://git.openstack.org/cgit/openstack-dev/devstack/commit/?id=b34d459bbc100e65fbc308438b3b7f72bd5fb5b6
Submitter: Jenkins
Branch: master

commit b34d459bbc100e65fbc308438b3b7f72bd5fb5b6
Author: Drago Rosson <email address hidden>
Date: Mon Sep 26 13:23:23 2016 -0500

    Allow default IPv6 route device names to have dots

    When dots are used with sysctl, they are reinterpreted as slashes.
    Route devices can have dots in their names, so when they are used in a
    sysctl command that also uses dots, its dot will be replaced with a
    slash, causing an error.

    Change-Id: Ie32126a3aa8d646568d7d37ec4874419b9658935
    Closes-Bug: #1627770

Changed in devstack:
status: In Progress → Fix Released
tags: added: newton-backport-potential
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to devstack (stable/newton)

Fix proposed to branch: stable/newton
Review: https://review.openstack.org/407191

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to devstack (stable/newton)

Reviewed: https://review.openstack.org/407191
Committed: https://git.openstack.org/cgit/openstack-dev/devstack/commit/?id=092309647b18adb2b1a67731bafb56b324bc84d1
Submitter: Jenkins
Branch: stable/newton

commit 092309647b18adb2b1a67731bafb56b324bc84d1
Author: Drago Rosson <email address hidden>
Date: Mon Sep 26 13:23:23 2016 -0500

    Allow default IPv6 route device names to have dots

    When dots are used with sysctl, they are reinterpreted as slashes.
    Route devices can have dots in their names, so when they are used in a
    sysctl command that also uses dots, its dot will be replaced with a
    slash, causing an error.

    Change-Id: Ie32126a3aa8d646568d7d37ec4874419b9658935
    Closes-Bug: #1627770
    (cherry picked from commit b34d459bbc100e65fbc308438b3b7f72bd5fb5b6)

tags: added: in-stable-newton
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.