]> git.proxmox.com Git - mirror_ifupdown2.git/log
mirror_ifupdown2.git
9 years agoCorrect error message for unsupported ifupdown2 attributes
Sam Tannous [Tue, 10 Mar 2015 20:46:07 +0000 (16:46 -0400)]
Correct error message for unsupported ifupdown2 attributes

Ticket: CM-5349
Reviewed By: Trivial
Testing Done: Tested on cel box

Corrected a minor error in how we handle unsupported config attributes.
Instead of

     error: not enough arguments for format string

we will now print this:

     warning: peerlink.4000: unsupported attribute 'clagd-foobar'
(cherry picked from commit 44c6004a33d59ee234f8ee3d5f450e158c9e5bdc)

9 years agoWrong initialization of iface link kind (still puzzled how i had it this
Roopa Prabhu [Thu, 26 Feb 2015 22:26:58 +0000 (14:26 -0800)]
Wrong initialization of iface link kind (still puzzled how i had it this
way)

Ticket:
Reviewed By: trivial
Testing Done: Tested interface upperiface bring up

This was causing the auto upperiface bringup to pick all upperifaces on
malliks setup. This is a large number in a 500 svi setup.

9 years agomove link_set 'up' errors to debug
Roopa Prabhu [Wed, 25 Feb 2015 21:45:37 +0000 (13:45 -0800)]
move link_set 'up' errors to debug

Ticket: CM-5199
Reviewed By: trivial
Testing Done: tested with interfaces file in the bug

9 years agoIncrease LACP bypass period max to 900 seconds
Wilson Kok [Mon, 23 Feb 2015 19:18:34 +0000 (11:18 -0800)]
Increase LACP bypass period max to 900 seconds

Ticket: CM-5000
Reviewed By: Roopa
Testing Done:

9 years agoMerge branch 'CumulusLinux-2.5_br' of ssh://dev.cumulusnetworks.com/home/trac/cumulus...
Roopa Prabhu [Wed, 18 Feb 2015 20:32:05 +0000 (12:32 -0800)]
Merge branch 'CumulusLinux-2.5_br' of ssh://dev.cumulusnetworks.com/home/trac/cumulus into CumulusLinux-2.5_br

9 years agoCall mako renderer before rendering backslashes ('\')
Roopa Prabhu [Wed, 18 Feb 2015 20:28:50 +0000 (12:28 -0800)]
Call mako renderer before rendering backslashes ('\')

Ticket: CM-5104
Reviewed By:
Testing Done: Tested with interfaces file listed in the bug

9 years agoReplace bond-slave "link down" with "link protodown" for CLAG bond proto_down
anuradhak [Wed, 18 Feb 2015 16:03:07 +0000 (08:03 -0800)]
Replace bond-slave "link down" with "link protodown" for CLAG bond proto_down
handling.

Ticket: CM-4802
Reviewed By: CCR-2565
Testing Done: Yes

1. Earlier various clag components where using link admin state for enforcing
proto_down. With the introduction of a seperate proto_down state this is no
longer needed. Now on clag bond "proto_down" the bond and its slaves are
explicitly placed in a proto_down state. This carrier downs the slaves and
oper-downs the clag-bond. Change has been done in clagd, clag-monit script and
bonding driver.
2. Earlier misc tricks where needed in ifupdown2 to prevent slave state changes
for clag bond outside of clagd. These tricks are no longer needed and have been
reverted to keep ifupdown2 handling simple/consistent. This change basically
reverts #6985e1a376b538fbfa2346ef657427ae7e8f117a.

9 years agoifupdown2 must handle JSON input that is non-list
Sam Tannous [Wed, 11 Feb 2015 16:37:41 +0000 (11:37 -0500)]
ifupdown2 must handle JSON input that is non-list

Ticket: CM-4417
Reviewed By: roopa
Testing Done: Build powerpc image and tested alternate json format

ifupdown2 was patched to handle nonlist JSON input since this
is a valid format.
(cherry picked from commit 2597194f6f34344495f3a2b44bfe1d05887e1e77)

9 years agoAdd checks for BRIDGE_VLAN interfaces during link up/down
Roopa Prabhu [Tue, 10 Feb 2015 19:28:53 +0000 (11:28 -0800)]
Add checks for BRIDGE_VLAN interfaces during link up/down

Ticket: CM-4718
Reviewed By:
Testing Done: tested ifup/ifdown of vlan interfaces

9 years agoCheck for zero address on bridge ports before enslaving it to the bridge
Roopa Prabhu [Tue, 10 Feb 2015 19:17:00 +0000 (11:17 -0800)]
Check for zero address on bridge ports before enslaving it to the bridge

Ticket: CM-4859, CM-4382
Reviewed By:
Testing Done: Tested with config which included bond bridge ports with
zero address on the bond.

The bridge driver rejects the port add with -EINVAL.
A bond with no slaves is one usecase where the bond interface
has a zero hw address and is rejected by the bridge.
EINVAL currently is very confusing.

This patch checks for a valid ether add before enslaving the port to the
bridge.

9 years agoAdd dependency on python-argcomplete, python-ipaddr and python-gvgen
Roopa Prabhu [Mon, 9 Feb 2015 21:11:16 +0000 (13:11 -0800)]
Add dependency on python-argcomplete, python-ipaddr and python-gvgen

Ticket: CM-4453
Reviewed By:
Testing Done: Build tested
(cherry picked from commit ee9aa1a1bf510f950030f72cbc12ed41b0bc880d)

9 years agoMove clag_enable setting to ifupdown2 ifenslave.
anuradhak [Mon, 2 Feb 2015 17:54:53 +0000 (09:54 -0800)]
Move clag_enable setting to ifupdown2 ifenslave.

Ticket: CM-4802
Reviewed By:
Testing Done: yes

1. clag_enable needs to be set before slaves are added to the bond. Otherwise
bonding driver will bring the slaves up independent of clagd.
2. also added post_down clagd addon to cleanup the clag-id on ifdown.

9 years ago[Change by Roopa] To prevent ifupdown2 setting clag-bond slave states on ifup.
anuradhak [Mon, 2 Feb 2015 16:46:47 +0000 (08:46 -0800)]
[Change by Roopa] To prevent ifupdown2 setting clag-bond slave states on ifup.

Ticket: CM-4802
Reviewed By: CCR-2507
Testing Done: Yes

1. For clag bonds the slaves are kept down under various conditions (when clagd
is holding the bond in an errDisabled state). ifupdown2 should not set the slave
states for clag bonds.
2. Bonding driver sets the slave states on enslave and release (also for
non-clag bonds) so ifupdown2 doesn't need to set the slave state.

9 years agos/portautoedge/portadminedge/ + configure BA on uplink port
Roopa Prabhu [Thu, 29 Jan 2015 01:06:51 +0000 (17:06 -0800)]
s/portautoedge/portadminedge/ + configure BA on uplink port

Ticket:
Reviewed By:
Testing Done:

9 years agoHandle blank lines correctly in addons.conf
Roopa Prabhu [Thu, 22 Jan 2015 20:56:56 +0000 (12:56 -0800)]
Handle blank lines correctly in addons.conf

Ticket: (Reported by gospo)
Reviewed By:
Testing Done: Tested with blank lines in the file

9 years agoFix typo in comment in default config file
Roopa Prabhu [Fri, 16 Jan 2015 17:54:19 +0000 (09:54 -0800)]
Fix typo in comment in default config file

Ticket:
Reviewed By: trivial
Testing Done: no code change

9 years agoAdded clag-id to the interfaces example file.
anuradhak [Mon, 12 Jan 2015 21:44:54 +0000 (13:44 -0800)]
Added clag-id to the interfaces example file.

Ticket:
Reviewed By:
Testing Done:

9 years agochange ifupdown example for vxlan-learning to the non-default option
Balakrishnan Raman [Wed, 7 Jan 2015 06:12:08 +0000 (22:12 -0800)]
change ifupdown example for vxlan-learning to the non-default option

Ticket: CM-4723
Reviewed By: CCR-2408
Testing Done:

Change example to non-default option - "vxlan-learning off"

9 years agoFix BCM SDK tunnel termination object cleanup on vxlan tunnel delete
Balakrishnan Raman [Wed, 7 Jan 2015 05:16:39 +0000 (21:16 -0800)]
Fix BCM SDK tunnel termination object cleanup on vxlan tunnel delete

Ticket: CM-4723
Reviewed By: CCR-2408
Testing Done: vxlan_fld_test.py:test_bond_vxlinux_convergence_flaps, manual testing

On tunnel delete, tunnel termination object in BCM sdk is not cleaned properly.
As a result, mpls_entry in the hardware is left around even though software has
deleted the tunnel. This prevents subsequent dynamic creation of the same tunnel
and also mac learning, as mpls_entry points to invalid SVP with no CML setting
to do hardware learning.

Also, changes in ifupdown2 to make "vxlan-learning on" as default, so that
user/script doesn't have to explicitly turn on the learning.

9 years agoMove disable ipv6 error to info in mstpctl module (test scripts are
Roopa Prabhu [Sun, 4 Jan 2015 06:35:45 +0000 (22:35 -0800)]
Move disable ipv6 error to info in mstpctl module (test scripts are
still using mstpctl-ports)

Ticket: CM-4622
Reviewed By:
Testing Done: Tested bridge sanity

9 years agoDocument ifreload new option + add it into init.d networking script
Roopa Prabhu [Sat, 3 Jan 2015 08:27:35 +0000 (00:27 -0800)]
Document ifreload new option + add it into init.d networking script

Ticket:
Reviewed By: trivial
Testing Done: Tested build/install/boot + ifupdown2 sanity

9 years agoWarn when bond-min-links is absent or set to '0'
Roopa Prabhu [Sat, 3 Jan 2015 02:20:15 +0000 (18:20 -0800)]
Warn when bond-min-links is absent or set to '0'

Ticket: CM-4327
Reviewed By:
Testing Done: Tested bond config without the bond-min-links attribute

9 years agoAlways set lacp-bypass-allow value to default if lacp-bypass-allow is
Roopa Prabhu [Fri, 2 Jan 2015 04:43:10 +0000 (20:43 -0800)]
Always set lacp-bypass-allow value to default if lacp-bypass-allow is
not given by the user

Ticket: CM-4552
Reviewed By:
Testing Done: Tested with and without lacp-bypass-allow in the file

9 years agoMoved warning to info level
Roopa Prabhu [Thu, 1 Jan 2015 07:47:18 +0000 (23:47 -0800)]
Moved warning to info level

Ticket: CM-4622
Reviewed By:
Testing Done: Tested ifup/ifdown on a bridge

If the file is not present, we will just log it.

9 years agoAdd hack to flap macvlan dev if it already exists and if the route to the vrr network...
Roopa Prabhu [Thu, 1 Jan 2015 07:43:27 +0000 (23:43 -0800)]
Add hack to flap macvlan dev if it already exists and if the route to the vrr network is pointing to it (part of commit 1ef86ab1930d198b0fba7ac33576c22f34d89f14)

Ticket: CM-4639
Reviewed By:
Testing Done: Tested with interfaces file and steps from the bug

This is a Hack to make sure the primary address
is the first in the routing table. Its not a full proof solution.

We use `ip route get` on the vrr network to see which
device the kernel returns. if it is the mac vlan device,
flap the macvlan device to adjust the routing table entry.
flapping the macvlan device makes sure the macvlan
connected route goes through delete + add, hence adjusting
the order in the routing table.

9 years agoAdd hack to flap macvlan dev if it already exists and if the route to
Roopa Prabhu [Thu, 1 Jan 2015 06:51:46 +0000 (22:51 -0800)]
Add hack to flap macvlan dev if it already exists and if the route to
the vrr network is pointing to it

Ticket: CM-4639
Reviewed By:
Testing Done: Tested with interfaces file and steps from the bug

This is a Hack to make sure the primary address
is the first in the routing table. Its not a full proof solution.

We use `ip route get` on the vrr network to see which
device the kernel returns. if it is the mac vlan device,
flap the macvlan device to adjust the routing table entry.
flapping the macvlan device makes sure the macvlan
connected route goes through delete + add, hence adjusting
the order in the routing table.

9 years agoFix link_type flag for objects read from state file + fix link_type
Roopa Prabhu [Wed, 31 Dec 2014 21:58:25 +0000 (13:58 -0800)]
Fix link_type flag for objects read from state file + fix link_type
initializations in a few other places

Ticket: CM-4610
Reviewed By:
Testing Done: Tested with the failing sequence of events described in
the bug

9 years agoMove link_master_slave flag overrides to /sbin/ifupdown + log a msg to
Roopa Prabhu [Tue, 30 Dec 2014 06:07:49 +0000 (22:07 -0800)]
Move link_master_slave flag overrides to /sbin/ifupdown + log a msg to
indicate link_master_slave flag status

Ticket:
Reviewed By:
Testing Done: ifupdown2 sanity tests with link_master_slave feature on/off

9 years agoMoved bond-clag-id attr setting from ifenslave.py to addons/clagd.py
anuradhak [Mon, 29 Dec 2014 19:48:45 +0000 (11:48 -0800)]
Moved bond-clag-id attr setting from ifenslave.py to addons/clagd.py

Ticket:
Reviewed By:
Testing Done:

<DETAILED DESCRIPTION (REPLACE)>
(cherry picked from commit ed008ea9ec176e01b2043b872ad0b8b193f31d0f)

9 years agoChanges to replace clagid setting in the bonding driver with -
anuradhak [Sun, 28 Dec 2014 15:07:47 +0000 (07:07 -0800)]
Changes to replace clagid setting in the bonding driver with -
1. clag_enable flag in the bonding driver
2. And clagid in clagd

Ticket: CM-4091
Reviewed By:
Testing Done: yes

1. Two new commands have been introduced in clagctl - setclagid and showclagid.
These commands will be used by ifupdown2 to set and read/check the clagid.
2. In addition a bit will be maintained per-bond in the bonding driver to
indicate if a bond is a CLAG bond.
(cherry picked from commit cb160bad45d330fe5f544d0d9a40c1c77b9b563f)

9 years agoUpdated in response to review comments in CCR-2301
anuradhak [Mon, 15 Dec 2014 23:32:26 +0000 (15:32 -0800)]
Updated in response to review comments in CCR-2301

Ticket:
Reviewed By:
Testing Done:

<DETAILED DESCRIPTION (REPLACE)>
(cherry picked from commit 48276ee247e230fdd9cd89a33e3b21f13fe85e58)

9 years agoCLAG id for 2.5.0
anuradhak [Tue, 2 Dec 2014 19:32:53 +0000 (11:32 -0800)]
CLAG id for 2.5.0

Ticket:
Reviewed By:
Testing Done: Yes

1. ifupdown2/bonding-driver changes to show/store clag-id (errDisabled/dormant states for bond slaves will follow in 2.5.1)
2. clagd changes for
   a. --forceDynamic - clagid is ignored in this mode
   b. (default) static mode - clagid is matched along with partner mac for dualConnection; also ad_sys_mac is only changed for clag bonds (bonds with a non-zero clag-id).

Conflicts:
patches/kernel/series

9 years agoAdded a few more try-except clauses during bridge config to continue on
Roopa Prabhu [Sun, 28 Dec 2014 04:29:44 +0000 (20:29 -0800)]
Added a few more try-except clauses during bridge config to continue on
failures

Ticket: CM-4382
Reviewed By:
Testing Done: Tested with bridge port addition failure example in the
bug report

9 years agoSuppress 'Network down' warnings when link_master_slave feature is on
Roopa Prabhu [Fri, 26 Dec 2014 17:39:52 +0000 (09:39 -0800)]
Suppress 'Network down' warnings when link_master_slave feature is on

Ticket: CM-4462
Reviewed By:
Testing Done: Tested with interfaces file given in the bug.

The 'network down' msg from the kernel is when the lower device is not
'admin up'. In CM-4462 it is seen when the vlan interface on the bond
is 'admin up' when the bond is still in 'admin down' state.
The bond is also a bridge port so, bond will be 'admin up' when
the bridge it belongs to is brought up.

As link_master_slave feature is on only when all network interfaces
are brought up/down, the states of all interfaces will eventually
converge to 'admin up', so ignoring such transient 'network down' messages.

9 years agoFix error msg strings from rtnetlink module
Roopa Prabhu [Fri, 26 Dec 2014 17:37:42 +0000 (09:37 -0800)]
Fix error msg strings from rtnetlink module

Ticket:
Reviewed By:
Testing Done:

9 years agoFix a bug with disabling of config option link_master_slave + turn off
Roopa Prabhu [Fri, 26 Dec 2014 17:21:50 +0000 (09:21 -0800)]
Fix a bug with disabling of config option link_master_slave + turn off
link master slave feature when '-a' is not specified.

Ticket: CM-4408
Reviewed By:
Testing Done: Tested with ifupdown2.conf link_master_slave on/off

This will make the behaviour change mostly invisible to users

Conflicts:
packages/ifupdown2/ifupdown/ifupdownmain.py

9 years agoAdd rtnetlink api's for 'bridge vlan' and modify 'bridge vlan' commands
Roopa Prabhu [Fri, 26 Dec 2014 17:09:47 +0000 (09:09 -0800)]
Add rtnetlink api's for 'bridge vlan' and modify 'bridge vlan' commands
in vlan module to use rtnetlink api

Ticket: CM-4173
Reviewed By:
Testing Done: Tested new bridge driver svi up/down

This does not move all 'bridge vlan' commands to rtnetlink yet.

9 years agoRework bridge upperiface handling (to fix some problems with the new
Roopa Prabhu [Wed, 24 Dec 2014 20:14:30 +0000 (12:14 -0800)]
Rework bridge upperiface handling (to fix some problems with the new
bridge driver and svi config)

Ticket: CM-3346
Reviewed By:
Testing Done: Tested upper interface handling during ifup of
bonds/bridges/svis

9 years agoMerge branch 'release-2.5' into CumulusLinux-2.5_br
John Berezovik [Wed, 24 Dec 2014 20:20:53 +0000 (12:20 -0800)]
Merge branch 'release-2.5' into CumulusLinux-2.5_br

Conflicts:
build-config/make/local-pkgs.make
packages/cafe/clobjects.py
packages/cafe/clobjects_l3_quagga.py
packages/cl-basefiles/etc/cumulus/datapath/traffic.conf
packages/cl-utilities/etc/monit/monitrc.d/cumulus
packages/clag/ifupdown/clagd.py
packages/ifupdown2/addons/bridge.py
packages/ifupdown2/addons/ifenslave.py
packages/ifupdown2/ifupdown/iface.py
packages/ifupdown2/ifupdown/ifupdownmain.py
packages/ifupdown2/ifupdown/scheduler.py
packages/portwd/portwd
patches/bcm-sdk/series
patches/iproute/bridge-increase-netlink-rcv-buf-size.patch
patches/iproute/series
patches/kernel/driver-support-sff-8436-eeprom.patch
patches/kernel/network-bridge-dont-install-local-mac.patch
patches/kernel/series
patches/lldpd/series
patches/mstpd/clag_port_fsm_reset.patch
patches/mstpd/mstpd_init_system.patch
patches/mstpd/series
patches/quagga/series
rootconf/default/etc/default/cron
switchd/hal.c
switchd/hal_bcm.c
switchd/hal_bcm_config.c
switchd/hal_bcm_config.h
switchd/hal_config.c
switchd/hal_config.h
switchd/hal_int.h
switchd/sync.c
tests/tests/l3/bgp_alpm_test.py
tests/tests/l3/bgp_path_hunting.py
tests/tests/l3/bgp_smoke_test.py
tests/tests/l3/l3_node.py
tests/tests/l3/mc_snoop_test.py
tests/tests/lib/decorators.py
tests/tests/smoke/testifupdown2.py
utilities/ci/pretest.yml
utilities/distro-cmd
utilities/packages/ssim2/setup.py
utilities/packages/ssim2/ssim2/simlib.py

9 years agoAdd check for vlan aware bridge when setting arp_accept to 1
Roopa Prabhu [Wed, 17 Dec 2014 23:09:52 +0000 (15:09 -0800)]
Add check for vlan aware bridge when setting arp_accept to 1

Ticket: CM-4373
Reviewed By:
Testing Done: Tested with address on vlan aware bridge as described in
the bug

9 years agoMultiple fixes and cleanup
Roopa Prabhu [Wed, 17 Dec 2014 20:39:38 +0000 (12:39 -0800)]
Multiple fixes and cleanup

Ticket: CM-3346
Reviewed By:
Testing Done: Tested ifupdown2 sanity

- moved 'admin up' delays that we introduced recently to be
configurable via two ifupdown2.conf attributes
    # Let link master (bridges, bonds) own the link state of slaves
    link_master_slave=1

    # Delay admin state change till the end
    delay_admin_state_change=0

- reduced some redundant traversal of dependency trees

- fixed a few bugs in query check

9 years agofix kernel lacp_fallback_* sysfs file references to use lacp_bypass_*
Roopa Prabhu [Tue, 16 Dec 2014 01:45:49 +0000 (17:45 -0800)]
fix kernel lacp_fallback_* sysfs file references to use lacp_bypass_*

Ticket:
Reviewed By:
Testing Done: Build and sanity test

9 years agobring up bridge ports only after vlan config is done
Roopa Prabhu [Sat, 13 Dec 2014 07:45:31 +0000 (23:45 -0800)]
bring up bridge ports only after vlan config is done

Ticket:
Reviewed By: wkok
Testing Done: unit testing + testing by wkok/purna
(cherry picked from commit 5af90b2893cd54bb21fedaf27ec6dd22de3f2802)

Conflicts:
packages/ifupdown2/addons/bridge.py

9 years agobring up bridge ports only after vlan config is done
Roopa Prabhu [Sat, 13 Dec 2014 07:45:31 +0000 (23:45 -0800)]
bring up bridge ports only after vlan config is done

Ticket:
Reviewed By: wkok
Testing Done: unit testing + testing by wkok/purna

9 years agos/fallback/bypass/
Roopa Prabhu [Sat, 13 Dec 2014 06:56:29 +0000 (22:56 -0800)]
s/fallback/bypass/

Ticket: CM-4452
Reviewed By:
Testing Done: Tested with old and new format

9 years agos/fallback/bypass/
Roopa Prabhu [Sat, 13 Dec 2014 06:56:29 +0000 (22:56 -0800)]
s/fallback/bypass/

Ticket: CM-4452
Reviewed By:
Testing Done: Tested with old and new format

9 years agoMake bridge module the owner of bridge port links (This is to delay
Roopa Prabhu [Fri, 12 Dec 2014 03:06:21 +0000 (19:06 -0800)]
Make bridge module the owner of bridge port links (This is to delay
bridge port up until bridge is up)

Ticket:
Reviewed By:
Testing Done:

9 years agoFix hex flags representation (this was causing wrong evaluation of & and
Roopa Prabhu [Fri, 12 Dec 2014 00:13:25 +0000 (16:13 -0800)]
Fix hex flags representation (this was causing wrong evaluation of & and
| on flags)

Ticket:
Reviewed By:
Testing Done:

Problem seen with ifquery skipping some interfaces because of wrong
evaluation of iface flags

9 years agoAdd a few more trt/except blocks to warn and proceed
Roopa Prabhu [Thu, 11 Dec 2014 05:30:39 +0000 (21:30 -0800)]
Add a few more trt/except blocks to warn and proceed

Ticket:
Reviewed By:
Testing Done:

<DETAILED DESCRIPTION (REPLACE)>
(cherry picked from commit da446f09f0c723852f20ba1c666abcc80b5fe764)

9 years agoAdd a few more trt/except blocks to warn and proceed
Roopa Prabhu [Thu, 11 Dec 2014 05:30:39 +0000 (21:30 -0800)]
Add a few more trt/except blocks to warn and proceed

Ticket:
Reviewed By:
Testing Done:

<DETAILED DESCRIPTION (REPLACE)>

9 years agoRemove stale debug
Roopa Prabhu [Tue, 9 Dec 2014 22:26:11 +0000 (14:26 -0800)]
Remove stale debug

Ticket:
Reviewed By:
Testing Done:
(cherry picked from commit 3ccb3873a995ee7d47134dbbae88ebb424da6d8e)

9 years agoRemove stale debug
Roopa Prabhu [Tue, 9 Dec 2014 22:26:11 +0000 (14:26 -0800)]
Remove stale debug

Ticket:
Reviewed By:
Testing Done:

9 years agoAdd clagd in the default shipped addons.conf and remove the editing of
Roopa Prabhu [Tue, 9 Dec 2014 21:49:23 +0000 (13:49 -0800)]
Add clagd in the default shipped addons.conf and remove the editing of
addons file

Ticket: CM-4423
Reviewed By:
Testing Done: tested ifupdown2 in the presence and absence of clagd

This is a hack to get around an ifupdown2 limitation.
The real fix should come as part of CM-3782
(cherry picked from commit 6fb63d6cdcb660063cf5d07ff28f49c34a306371)

9 years agoFix if condition when propagating link_type (old flags check left over from my previous
Roopa Prabhu [Tue, 9 Dec 2014 20:56:45 +0000 (12:56 -0800)]
Fix if condition when propagating link_type (old flags check left over from my previous
commit)

Ticket: CM-4408
Reviewed By:
Testing Done: Tested with old bridge driver config (bug reported by
satish)
(cherry picked from commit 11e6ae96aae85591e8d32e1062d979e51de9e424)

9 years agoMove LINK_MASTER/LINK_SLAVE to a new field link_type (purna hit some
Roopa Prabhu [Tue, 9 Dec 2014 06:59:41 +0000 (22:59 -0800)]
Move LINK_MASTER/LINK_SLAVE to a new field link_type (purna hit some
issues with having it in flags) + add check for bond slave being already up

Ticket: CM-4408
Reviewed By:
Testing Done: some bond sanity test
(cherry picked from commit 346b62a41fbf4521008cd8a9b0fa227e75a5d994)

9 years agoThis patch moves bond slave link ownership to the bond module and makes
Roopa Prabhu [Tue, 9 Dec 2014 01:15:57 +0000 (17:15 -0800)]
This patch moves bond slave link ownership to the bond module and makes
sure that slaves can never be brought admin up on their own when they
are not in the bond

Ticket: CM-4408
Reviewed By: CCR-2323
Testing Done: Tested ifup/ifdown of bond slaves and bond interface

This patch introduces:
- introduces 2 interface flags, LINK_MASTER and LINK_SLAVE.
- The bond module will set LINK_MASTER on the bond iface object
indicating that the bond module owns the link.
- Which means that all lower devices /slaves of the bond get their
link when the bond (aka LINK_MASTER) is processed in the bond module
- The module that queries dependencies propagates the LINK_SLAVE flags
on the dependents of LINK_MASTER.
- The scheduler now acts on the LINK_SLAVE flag. If LINK_SLAVE is set,
it skips setting admin 'up' on that interface. It also makes sure the
interface is not already in the bond.
    ie if an interface is a LINK_SLAVE (bond slave in this case), admin
up will not be executed when the interface is not inside the bond.
(cherry picked from commit 84b5a07a4f7685c7ae2eac5892889d6c0e08b2eb)

9 years agoAdd clagd in the default shipped addons.conf and remove the editing of
Roopa Prabhu [Tue, 9 Dec 2014 21:49:23 +0000 (13:49 -0800)]
Add clagd in the default shipped addons.conf and remove the editing of
addons file

Ticket: CM-4423
Reviewed By:
Testing Done: tested ifupdown2 in the presence and absence of clagd

This is a hack to get around an ifupdown2 limitation.
The real fix should come as part of CM-3782

9 years agoFix if condition when propagating link_type (old flags check left over from my previous
Roopa Prabhu [Tue, 9 Dec 2014 20:56:45 +0000 (12:56 -0800)]
Fix if condition when propagating link_type (old flags check left over from my previous
commit)

Ticket: CM-4408
Reviewed By:
Testing Done: Tested with old bridge driver config (bug reported by
satish)

9 years agoMove LINK_MASTER/LINK_SLAVE to a new field link_type (purna hit some
Roopa Prabhu [Tue, 9 Dec 2014 06:59:41 +0000 (22:59 -0800)]
Move LINK_MASTER/LINK_SLAVE to a new field link_type (purna hit some
issues with having it in flags) + add check for bond slave being already up

Ticket: CM-4408
Reviewed By:
Testing Done: some bond sanity test

9 years agoThis patch moves bond slave link ownership to the bond module and makes
Roopa Prabhu [Tue, 9 Dec 2014 01:15:57 +0000 (17:15 -0800)]
This patch moves bond slave link ownership to the bond module and makes
sure that slaves can never be brought admin up on their own when they
are not in the bond

Ticket: CM-4408
Reviewed By: CCR-2323
Testing Done: Tested ifup/ifdown of bond slaves and bond interface

This patch introduces:
- introduces 2 interface flags, LINK_MASTER and LINK_SLAVE.
- The bond module will set LINK_MASTER on the bond iface object
indicating that the bond module owns the link.
- Which means that all lower devices /slaves of the bond get their
link when the bond (aka LINK_MASTER) is processed in the bond module
- The module that queries dependencies propagates the LINK_SLAVE flags
on the dependents of LINK_MASTER.
- The scheduler now acts on the LINK_SLAVE flag. If LINK_SLAVE is set,
it skips setting admin 'up' on that interface. It also makes sure the
interface is not already in the bond.
    ie if an interface is a LINK_SLAVE (bond slave in this case), admin
up will not be executed when the interface is not inside the bond.

9 years agoDisable loopback module until we decide and document it
Roopa Prabhu [Thu, 4 Dec 2014 16:24:22 +0000 (08:24 -0800)]
Disable loopback module until we decide and document it

Ticket: CM-3525
Reviewed By:
Testing Done:

9 years agoDisable vrrpd until it is fully supported
Roopa Prabhu [Thu, 4 Dec 2014 16:09:05 +0000 (08:09 -0800)]
Disable vrrpd until it is fully supported

Ticket: CM-3791
Reviewed By:
Testing Done: compile tested
(cherry picked from commit 382c2a165d9927ff26f22ce2a2a57c3742fbbfa5)

9 years agoDisable vrrpd until it is fully supported
Roopa Prabhu [Thu, 4 Dec 2014 16:09:05 +0000 (08:09 -0800)]
Disable vrrpd until it is fully supported

Ticket: CM-3791
Reviewed By:
Testing Done: compile tested

9 years agoFix reserved vlan check + change switchd ifupdown reserved vlan script
Roopa Prabhu [Wed, 3 Dec 2014 22:03:34 +0000 (14:03 -0800)]
Fix reserved vlan check + change switchd ifupdown reserved vlan script
to return reserved vlan range from /etc/cumulus/switchd.conf

Ticket: CM-4367
Reviewed By: wkok
Testing Done: Tested using reserved vlans in old and new bridge
(cherry picked from commit 8626feb08703392b29e234b2f81f4df536ad7f7b)

9 years agoFix reserved vlan check + change switchd ifupdown reserved vlan script
Roopa Prabhu [Wed, 3 Dec 2014 22:03:34 +0000 (14:03 -0800)]
Fix reserved vlan check + change switchd ifupdown reserved vlan script
to return reserved vlan range from /etc/cumulus/switchd.conf

Ticket: CM-4367
Reviewed By: wkok
Testing Done: Tested using reserved vlans in old and new bridge

9 years agoifupdown2: remove up op in config file
Andy Gospodarek [Wed, 3 Dec 2014 03:55:30 +0000 (19:55 -0800)]
ifupdown2: remove up op in config file

Ticket: CM-3525
Reviewed By: CCR-2035
Testing Done: ifup/ifdown, service networking restart, reboot

Need for this change noticed in review.
(cherry picked from commit 231e2cf74b0f55b65f76d315d04f3a9c8279f51b)

9 years agoifupdown2: remove up op in config file
Andy Gospodarek [Wed, 3 Dec 2014 03:55:30 +0000 (19:55 -0800)]
ifupdown2: remove up op in config file

Ticket: CM-3525
Reviewed By: CCR-2035
Testing Done: ifup/ifdown, service networking restart, reboot

Need for this change noticed in review.

9 years agoFix formatting for ifquery check (cosmetic. only fixes prints)
Roopa Prabhu [Tue, 2 Dec 2014 07:19:48 +0000 (23:19 -0800)]
Fix formatting for ifquery check (cosmetic. only fixes prints)

Ticket: CM-3346
Reviewed By:
Testing Done: ifupdown2 sanity + ifquery check tests
(cherry picked from commit ba81bde56d04a8f90a6f5d548518605fd1e5ae5f)

9 years agoFix formatting for ifquery check (cosmetic. only fixes prints)
Roopa Prabhu [Tue, 2 Dec 2014 07:19:48 +0000 (23:19 -0800)]
Fix formatting for ifquery check (cosmetic. only fixes prints)

Ticket: CM-3346
Reviewed By:
Testing Done: ifupdown2 sanity + ifquery check tests

9 years agocontinue passing the object to other modules if one of the modules fails
Roopa Prabhu [Mon, 1 Dec 2014 22:54:12 +0000 (14:54 -0800)]
continue passing the object to other modules if one of the modules fails

Ticket: CM-4336
Reviewed By:
Testing Done: Tested with the missing port testcase from CM-4336
(cherry picked from commit 82a976ada6ba208bde089805d613413a5b016f8d)

9 years agocontinue passing the object to other modules if one of the modules fails
Roopa Prabhu [Mon, 1 Dec 2014 22:54:12 +0000 (14:54 -0800)]
continue passing the object to other modules if one of the modules fails

Ticket: CM-4336
Reviewed By:
Testing Done: Tested with the missing port testcase from CM-4336

9 years agoCheck for unexpected characters (specifically the ones which look like
Roopa Prabhu [Mon, 1 Dec 2014 05:44:46 +0000 (21:44 -0800)]
Check for unexpected characters (specifically the ones which look like
variable names) + also fix a condition that looks incorrect

Ticket:
Reviewed By: wkok
Testing Done: Tested with the failing

This was seen in a case where mako is unable to render the template
or incorrectly renders it due to user template
errors, leaving interface names with
mako variables in them. There is no easy way to
recognize and warn about these. This patch tries to warn the user
of such cases by looking for variable patterns ('$') in interface names.
(cherry picked from commit fc0d45a794a61f7e6a3fd2c2ebce3d621bf0c7b2)

9 years agoCheck for unexpected characters (specifically the ones which look like
Roopa Prabhu [Mon, 1 Dec 2014 05:44:46 +0000 (21:44 -0800)]
Check for unexpected characters (specifically the ones which look like
variable names) + also fix a condition that looks incorrect

Ticket:
Reviewed By: wkok
Testing Done: Tested with the failing

This was seen in a case where mako is unable to render the template
or incorrectly renders it due to user template
errors, leaving interface names with
mako variables in them. There is no easy way to
recognize and warn about these. This patch tries to warn the user
of such cases by looking for variable patterns ('$') in interface names.

9 years agoChange to square brackets (hopefully last change on this before it goes
Roopa Prabhu [Mon, 1 Dec 2014 05:15:10 +0000 (21:15 -0800)]
Change to square brackets (hopefully last change on this before it goes
out)

Ticket: CM-3346
Reviewed By:
Testing Done: Tested ifquery check
(cherry picked from commit d8b03e1d50e2936d87a419f16564b79b908e6ef7)

9 years agoChange to square brackets (hopefully last change on this before it goes
Roopa Prabhu [Mon, 1 Dec 2014 05:15:10 +0000 (21:15 -0800)]
Change to square brackets (hopefully last change on this before it goes
out)

Ticket: CM-3346
Reviewed By:
Testing Done: Tested ifquery check

9 years agoChange case of check strings
Roopa Prabhu [Fri, 28 Nov 2014 20:48:01 +0000 (12:48 -0800)]
Change case of check strings

Ticket: CM-3346
Reviewed By: cosmetic
Testing Done: ifquery check sanity
(cherry picked from commit 556a078a7f551f1f895f0ddc71b6124d960ffb4e)

9 years agoChange case of check strings
Roopa Prabhu [Fri, 28 Nov 2014 20:48:01 +0000 (12:48 -0800)]
Change case of check strings

Ticket: CM-3346
Reviewed By: cosmetic
Testing Done: ifquery check sanity

9 years agoFix a few more s/br/bridge/g
Roopa Prabhu [Wed, 26 Nov 2014 19:09:50 +0000 (11:09 -0800)]
Fix a few more s/br/bridge/g

Ticket: CM-3346
Reviewed By:
Testing Done:
(cherry picked from commit e63e03e90af531ab660dca03f437f8432337c5d3)

9 years agoDelete stale example files
Roopa Prabhu [Wed, 26 Nov 2014 18:59:58 +0000 (10:59 -0800)]
Delete  stale example files

Ticket: CM-3346
Reviewed By:
Testing Done: sanity tests
(cherry picked from commit ea6f72f628abc3758f4bf665a1c90e6d50860aea)

9 years agoadd a helper switchd ifupdown script that returns reserved vlan range
Roopa Prabhu [Wed, 26 Nov 2014 06:25:33 +0000 (22:25 -0800)]
add a helper switchd ifupdown script that returns reserved vlan range

Ticket:
Reviewed By: CCR-2279
Testing Done: tested ifupdown2 reserved vlan checks

THis patch adds a switchd ifupdown script to return the reserved vlan.

Ifupdown will use this to warn the user when he uses a reserved vlan

(THis patch is a result of wilsons request to have a reserved vlan check
if ifupdown)
(cherry picked from commit 4e693849aba1f1821dba9cfdc567c92baeb23db5)

9 years agoFix setup.py to include new example file names
Roopa Prabhu [Wed, 26 Nov 2014 06:05:02 +0000 (22:05 -0800)]
Fix setup.py to include new example file names

Ticket: CM-3346
Reviewed By:
Testing Done:checked build
(cherry picked from commit ab6e46851087ae0302f1fb457eb6adb8900a13d9)

9 years agoChange names and s/br/bridge/
Roopa Prabhu [Wed, 26 Nov 2014 05:53:38 +0000 (21:53 -0800)]
Change names and s/br/bridge/

Ticket: CM-3346
Reviewed By:
Testing Done: Tested ifupdown2 sanity with all example files
(cherry picked from commit 40a3f646548c35bda34f4d41adb2e935374bb029)

9 years agoFix a few more s/br/bridge/g
Roopa Prabhu [Wed, 26 Nov 2014 19:09:50 +0000 (11:09 -0800)]
Fix a few more s/br/bridge/g

Ticket: CM-3346
Reviewed By:
Testing Done:

9 years agoDelete stale example files
Roopa Prabhu [Wed, 26 Nov 2014 18:59:58 +0000 (10:59 -0800)]
Delete  stale example files

Ticket: CM-3346
Reviewed By:
Testing Done: sanity tests

9 years agoadd a helper switchd ifupdown script that returns reserved vlan range
Roopa Prabhu [Wed, 26 Nov 2014 06:25:33 +0000 (22:25 -0800)]
add a helper switchd ifupdown script that returns reserved vlan range

Ticket:
Reviewed By: CCR-2279
Testing Done: tested ifupdown2 reserved vlan checks

THis patch adds a switchd ifupdown script to return the reserved vlan.

Ifupdown will use this to warn the user when he uses a reserved vlan

(THis patch is a result of wilsons request to have a reserved vlan check
if ifupdown)

9 years agoFix setup.py to include new example file names
Roopa Prabhu [Wed, 26 Nov 2014 06:05:02 +0000 (22:05 -0800)]
Fix setup.py to include new example file names

Ticket: CM-3346
Reviewed By:
Testing Done:checked build

9 years agoChange names and s/br/bridge/
Roopa Prabhu [Wed, 26 Nov 2014 05:53:38 +0000 (21:53 -0800)]
Change names and s/br/bridge/

Ticket: CM-3346
Reviewed By:
Testing Done: Tested ifupdown2 sanity with all example files

9 years agoMisc fixes. Add a --skip-upperifaces option to ifup (given the confusion
Roopa Prabhu [Tue, 25 Nov 2014 18:19:35 +0000 (10:19 -0800)]
Misc fixes. Add a --skip-upperifaces option to ifup (given the confusion
over ifup handling of upperifaces by default) + some fixes in the
reserved vlan check

Ticket: CM-3346
Reviewed By:
Testing Done: Tested ifupdown sanity.

9 years agoChange "source" inclusion errors to warns.
Roopa Prabhu [Fri, 21 Nov 2014 19:07:11 +0000 (11:07 -0800)]
Change "source" inclusion errors to warns.

Ticket: CM-3346
Reviewed By:
Testing Done: tested sanity

9 years agoif 'bridge-vlan-aware yes' specified, explicitly set 1 in bridge sysfs
Roopa Prabhu [Fri, 21 Nov 2014 18:17:37 +0000 (10:17 -0800)]
if 'bridge-vlan-aware yes' specified, explicitly set 1 in bridge sysfs
vlan_filtering flags.

Ticket: CM-3346
Reviewed By:
Testing Done: Tested new bridge driver sanity

9 years agoRemove debug print
Roopa Prabhu [Thu, 20 Nov 2014 01:49:44 +0000 (17:49 -0800)]
Remove debug print

Ticket:
Reviewed By:
Testing Done:

9 years agoFix 'source' file error handling
Roopa Prabhu [Thu, 20 Nov 2014 01:48:02 +0000 (17:48 -0800)]
Fix 'source' file error handling

Ticket:
Reviewed By:
Testing Done:

9 years agoFix a few minor ifquery check failures
Roopa Prabhu [Thu, 20 Nov 2014 01:25:26 +0000 (17:25 -0800)]
Fix a few minor ifquery check failures

Ticket: CM-3346
Reviewed By:
Testing Done: Tested ifupdown2 sanity and query check failures.

9 years agoFix ordering of mstpctl attributes by moving to a OrderedDict
Roopa Prabhu [Wed, 19 Nov 2014 22:42:14 +0000 (14:42 -0800)]
Fix ordering of mstpctl attributes by moving to a OrderedDict

Ticket: CM-3737
Reviewed By:
Testing Done: Tested with config given in the bug

9 years agore-add bridgevlan.py which was accidently removed by previous checkins
Roopa Prabhu [Wed, 19 Nov 2014 22:09:45 +0000 (14:09 -0800)]
re-add bridgevlan.py which was accidently removed by previous checkins

Ticket: CM-3346
Reviewed By:
Testing Done:

9 years agoAdd exclude args to /etc/default/networking
Roopa Prabhu [Wed, 19 Nov 2014 00:58:12 +0000 (16:58 -0800)]
Add exclude args to /etc/default/networking

Ticket: CM-3346
Reviewed By:
Testing Done: Tested service networking restart with exclude interface
list

9 years agoFix address module config (mtu, alias etc) when addr_method is dhcp
Roopa Prabhu [Wed, 19 Nov 2014 00:52:00 +0000 (16:52 -0800)]
Fix address module config (mtu, alias etc) when addr_method is dhcp

Ticket: CA-269
Reviewed By:
Testing Done: Tested setting alias on an interface with addr_method dhcp

9 years agoset arp accept to 1 for bridge devices with an ip and new bridge svi
Roopa Prabhu [Tue, 18 Nov 2014 00:23:42 +0000 (16:23 -0800)]
set arp accept to 1 for bridge devices with an ip and new bridge svi
device (forward port of commit

Ticket: CM-4218
Reviewed By:
Testing Done: Tested with address on new bridge svi and old bridge

9 years agoFix clag example
Roopa Prabhu [Mon, 17 Nov 2014 12:45:45 +0000 (04:45 -0800)]
Fix clag example

Ticket: CM-3346
Reviewed By: scotte
Testing Done:

9 years agoUse 'fdb replace' instead of 'fdb add'
Roopa Prabhu [Sun, 16 Nov 2014 07:36:08 +0000 (23:36 -0800)]
Use 'fdb replace' instead of 'fdb add'

Ticket: CM-4178
Reviewed By:
Testing Done: Tested ifupdown2 with 'address-virtual' attributes