1
0
mirror of https://github.com/CumulusNetworks/ifupdown2.git synced 2024-05-06 15:54:50 +00:00

104 Commits

Author SHA1 Message Date
5fb588fc9a debian: changelog: add empty 1.2.9-1 entry for next release
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-07-12 12:47:06 +04:00
79ba6a415a debian: changelog: add new changelog entry 1.2.8-1
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-07-12 12:22:36 +04:00
d0df31ff9d Merge pull request #116 from rajendra-dendukuri/dhcp6_duid
addons: dhcp: Policy to specify DUID type to use on dhcpv6 requests
2019-07-12 12:18:02 +04:00
1321d5e357 addons: dhcp: Policy to specify DUID type to use on dhcpv6 requests
Update module description and changelog

Signed-off-by: Rajendra Dendukuri <rajendra.dendukuri@broadcom.com>
2019-07-10 22:43:28 -07:00
cf1dac2ff7 debian: changelog: add new 1.2.7-1 entry
* New: Add bridge-ports-condone-regex option (closes #117)

Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-07-09 19:28:33 +04:00
c9091d7108 debian: changelog: updating 1.2.6-1 entry
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-06-24 15:52:06 +08:00
8cea3591b5 debian: changelog: update 1.2.6-1 entry
* New. policymanager: merge module policy instead of overriding duplicates
* New: set default mtu on user defined device (via link-type)

Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-06-06 19:19:42 +08:00
adf8e888e3 debian: changelog: update 1.2.6-1 entry before release
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-04-22 11:05:12 +08:00
c3f1a1a064 debian: changelog: 1.2.6-1: update changelog entry for new release
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-04-22 10:52:21 +08:00
ec25a08c3a addons: vxlan: add support for vxlan-ttl attribute
New vxlan-ttl attribute: specifies the TTL value to use in outgoing
packets. Valid values: range 1..255 or auto (0)

Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-04-22 10:48:36 +08:00
09f9afc782 debian: changelog: update 1.2.5-1 timestamp entry
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-01-21 11:01:13 +08:00
739f9c7ea0 scheduler: ifupdown2 scripts: log warning on EACCES exception (Fixes #89)
ifupdown2 behaviour significantly diverges from ifupdown on debian stretch.
Original ifupdown uses run-parts which supposedly doesn't run non-executable
files in the directory. However, ifupdown2 doesn't seem to make this
distinction.
This patch will log warning EACCES exceptions (instead of log error) and exit 0

Reported-by: George Diamantopoulos <gedia>
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-01-18 15:52:59 +08:00
35b9d035c1 debian: install sysvinit script (Fixes: #26)
Fixes github issue #26 and debian bug #918775

Reported-by: Joerg Dorchain <joerg@dorchain.net>
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>

Co-authored-by: Joerg Dorchain <joerg@dorchain.net>
Co-authored-by: Julien Fortin <julien@cumulusnetworks.com>
2019-01-17 12:26:47 +08:00
0aa3d31930 debian: postinst: remove diversion after upgrade from stretch
closes: #919443

Reported-by: Andreas Beckmann <anbe@debian.org>
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-01-16 18:35:28 +08:00
9f98f3604e statemanager: configure state_dir via ifupdown2.conf
ifupdown2 used /var/tmp/network/ to store its state file
upstream users reported that when /var/tmp is not mounted
before network configuration ifupdown2 fails. We now let
user define which location they want to use for the state
file.

closes: #918832

Reported-by: Maximilian Wilhelm <max@sdn.clinic>
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2019-01-11 12:08:10 +08:00
72ba456971 log: use stderr if syslog initialization fails
closes: #917534

Reported-by: Joerg Dorchain <joerg@dorchain.net>
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-30 22:45:47 +07:00
e28cc68413 debian: changelog: add debian revision and refactor 1.2.2-1 entry
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-20 11:18:22 +01:00
7a3f3bbefd debian: changelog: add B.A.T.M.A.N. changelog entry
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-20 09:48:43 +01:00
cf98afd144 debian: control: add python-pkg-resources to suggested dependencies-list
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-19 20:34:53 +01:00
ca45d4aaa8 man: remove non-implemented -m option (closes: #905572)
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-19 20:04:33 +01:00
e5019fc9b8 debian: changelog: tag older version with UNRELEASED tag
some of those release were available but under a different name so
technically those version numbers were never released.

Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-19 18:56:31 +01:00
0cbd3d8c05 debian: source: format: moving to non-native package
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-19 18:56:02 +01:00
e38b64a51c debian: control: update debhelper dependency and drop dh-systemd
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-19 18:46:21 +01:00
3b69ce6e62 debian: changelog: new entry for version 1.2.2
ifupdown2 (1.2.2) unstable; urgency=medium

  * Support for new iproute2 format (bridge vlan show)
  * Pypi install: local addons modules should be loaded first
  * Fix: link-down yes on vrf slaves
  * Fix: nlmanager: use strerror to format kernel error
  * Add: new checks for existing device with vxlan attributes
  * Ethtool: FEC: translate None and NotSupported values to link-fec off

 -- Julien Fortin <julien@cumulusnetworks.com>  Thu, 13 Dec 2018 23:42:42 -0800

Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 17:09:46 -08:00
9d50518591 addons: address: new l3_intf_default_gateway_set_onlink policy closes #54
As shown in the following example, ifupdown1 sets the default route with the
onlink attribute. This patch will add this capability to ifupdown2 controlled
by a policy variable in the address module: "l3_intf_default_gateway_set_onlink"
default to on

[19:16:07] root:~ # cat /etc/network/interfaces
auto lo
iface lo inet loopback

auto enp0s3
iface enp0s3 inet static
      address 78.46.193.234/32
      gateway 172.31.1.1
[19:16:19] root:~ # ifup -a -v
ifup: configuring interface enp0s3=enp0s3 (inet)
...
/bin/ip addr add 78.46.193.234/255.255.255.255 broadcast 78.46.193.234	  dev enp0s3 label enp0s3
/bin/ip link set dev enp0s3   up
/bin/ip route add default via 172.31.1.1  dev enp0s3 onlink
...
[19:16:21] root:~ # ip route show
default via 172.31.1.1 dev enp0s3 onlink
10.0.2.0/24 dev enp0s3 proto kernel scope link src 10.0.2.15
169.254.0.0/16 dev enp0s3 scope link metric 1000
[19:16:21] root:~ #

$ cat /etc/network/ifupdown2/policy.d/address.json
{
    "address": {
	"module_globals": {
	    "l3_intf_default_gateway_set_onlink": "yes"
	}
    }
}
$ ifquery swp1
auto swp1
iface swp1 inet static
	address 78.46.193.234/32
	gateway 172.31.1.1

$ ifreload -av |& grep "route add default"
info: executing /bin/ip route add default via 172.31.1.1 proto kernel dev swp1 onlink
$
$
$ emacs -nw /etc/network/ifupdown2/policy.d/address.json
$ cat /etc/network/ifupdown2/policy.d/address.json
{
    "address": {
	"module_globals": {
	    "l3_intf_default_gateway_set_onlink": "no"
	}
    }
}
$ ifdown -a -X eth0
$ ifreload -av |& grep "route add default"
info: executing /bin/ip route add default via 172.31.1.1 proto kernel dev swp1
$

Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:43:57 -08:00
629b46992d debian: changelog: update all entry to unstable distribution
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:43:57 -08:00
2eecfaf3dd debian: changelog: 1.2.1: set RELEASED
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:43:57 -08:00
ebfc7e2952 debian: changelog: update 1.2.1 entry
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:43:57 -08:00
3abe662118 debian: changelog: 1.2.1: update entry date
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:43:57 -08:00
3dcd868f84 debian: watch: removing watch file according to debian-watch-file-in-native-package (lintian warning)
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:43:57 -08:00
1b5c4ba96f debian: changelog: add l3_intf_arp_accept policy to 1.2.1 entry
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:43:57 -08:00
04f83b1adf debian: changelog: add link-fec changelog entry (release 1.2.1)
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:43:57 -08:00
a0ab870e46 debian: changelog: update changelog for release 1.2.1
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:43:57 -08:00
664856a2ba debian: changelog: add ip[6]-forward entry for new validvals
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:43:57 -08:00
fecca2114a debian: changelog: 1.2.1: new entry: point-to-point protocol (ppp)
New addon to create/configure ppp interfaces

Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:43:57 -08:00
23e8546d39 addons: addressvirtual: new policy (bool): addressvirtual_with_route_metric (default: yes)
Ifupdown2 is now setting a default metric on macvlan ips. This policy will let
users disable this new default behavior. addressvirtual_with_route_metric is
boolean policy variable.

  addressvirtual_with_route_metric: yes|no|on|off|1|0 (default to yes)

$ cat /var/lib/ifupdown2/policy.d/addressvirtual.json
{
    "addressvirtual": {
        "module_globals": {
            "addressvirtual_with_route_metric": "no"
        }
    }
}

Reviewed-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:42:35 -08:00
43ea2a97e7 debian: changelog: new entry for version 1.2.1
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:42:35 -08:00
70a6640ce1 bridge: vlan-aware: add new boolean policy "vlan_aware_bridge_address_support"
closes #58

In linux its possible to assign a vlan-aware bridge an ip address
For some use cases is it useful to restrict users from configuring
ips on bridges VA. This patch will let admins and distributions
decide if it is necessary to warn the user in such case.

The patch introduces a new 'address' policy:

 vlan_aware_bridge_address_support: yes|no|on|off|0|1 (default to yes)

[16:46:09] root:~ # cat /var/lib/ifupdown2/policy.d/address.json
{
    "address": {
	"module_globals": {
	    "enable_l3_iface_forwarding_checks": "yes"
	},
	"defaults": {
	    "mtu": "1500",
	    "ip-forward": "on",
	    "ip6-forward": "on"
	}
    }
}
[16:46:16] root:~ # ifquery -a
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet dhcp

auto bridge
iface bridge
	bridge-ports swp1
	bridge-vlan-aware yes
	address 10.10.10.10/32

[16:46:20] root:~ # ifup -a --syntax-check
[16:46:22] root:~ # echo $?
0
[16:46:33] root:~ # nano /var/lib/ifupdown2/policy.d/address.json
[16:46:47] root:~ # cat /var/lib/ifupdown2/policy.d/address.json
{
    "address": {
	"module_globals": {
	    "enable_l3_iface_forwarding_checks": "yes",
	    "vlan_aware_bridge_address_support": "no"
	},
	"defaults": {
	    "mtu": "1500",
	    "ip-forward": "on",
	    "ip6-forward": "on"
	}
    }
}
[16:46:48] root:~ # ifup -a --syntax-check
warning: bridge: ignoring ip address. Assigning an IP address is not allowed on bridge vlan aware interfaces
[16:46:51] root:~ # echo $?
1
[16:46:52] root:~ #

Reviewed-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:42:35 -08:00
7b66b2fc47 debian: changelog: 1.2.0: new entry: metric on macvlan ip
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:42:35 -08:00
7cdb931e5d addons: vrf: add support for 'link-down yes' on VRF slaves
$ ifquery -a
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet dhcp
	vrf mgmt
	link-down yes

auto mgmt
iface mgmt
	vrf-table auto

$ ifup -a -d
...
...
debug: mgmt: pre-up : running module vrf
info: executing /usr/lib/vrf/vrf-helper create mgmt 1001
debug: mgmt: eth0: slave configured with link-down yes
info: mgmt: netlink: ip link set dev mgmt up
...
$ ip link show eth0
2: eth0: <BROADCAST,MULTICAST> mtu 1500 qdisc pfifo_fast master mgmt state DOWN mode DEFAULT group default qlen 1000
    link/ether 08:00:27:80:e2:97 brd ff:ff:ff:ff:ff:ff

Reviewed-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:42:35 -08:00
05a4955081 ifupdownmain: run up/down on manual interfaces, but ignore any errors. (closes #48)
ifupdown changed its original behavior on "manual" address method:
12d333d619

ifupdown2 needs to change it's behavior too.

Reported-by: Alexandre Derumier <aderumier@odiso.com>
Reviewed-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Co-authored-by: Alexandre Derumier <aderumier@odiso.com>
Co-authored-by: Julien Fortin <julien@cumulusnetworks.com>
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:42:35 -08:00
e9b893536f debian: changelog: update/refactor changelog 1.2.0 entry
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:42:35 -08:00
ffdf73e14a ifupdown2.conf: vlan_aware_bridge_address_support: allow ip on vlan-aware bridge (closes #58)
In linux its possible to assign an ip address to a vlan-aware bridge
For some use cases is it useful to restrict users from configuring ips on
bridges VA. This patch will let admins and distributions decide if it is
necessary to warn the user in such case.

The patch introduces a new configuration variable in:
    /etc/network/ifudpown2/ifupdown2.conf

vlan_aware_bridge_address_support: yes|no|on|off|0|1 (default to yes)

[8:30:41] root:~ # cat /etc/network/ifupdown2/ifupdown2.conf | grep "vlan_aware_bridge_address_support"
[8:30:43] root:~ # ifquery bridge
auto bridge
iface bridge
	bridge-ports swp1
	bridge-vlan-aware yes
	address 10.10.10.10

[8:30:46] root:~ # ifup bridge --syntax-check
[8:30:52] root:~ # echo $?
0
[8:30:54] root:~ # echo "vlan_aware_bridge_address_support=no" >> /etc/network/ifupdown2/ifupdown2.conf
[8:31:11] root:~ # ifup bridge --syntax-check
warning: bridge: ignoring ip address. Assigning an IP address is not allowed on bridge vlan aware interfaces
[8:31:14] root:~ # echo $?
1
[8:31:17] root:~ #
[8:31:20] root:~ # ifup -a
[8:31:22] root:~ # echo $?
0
[8:31:25] root:~ # ifquery bridge -c
auto bridge
iface bridge                                                        [fail]
	bridge-vlan-aware yes                                       [pass]
	bridge-ports swp1                                           [pass]
	address 10.10.10.10                                         [fail]

[8:31:29] root:~ # ifdown bridge && ifup bridge -v |& grep "bridge vlan aware interfaces"
info: bridge: ignoring ip address. Assigning an IP address is not allowed on bridge vlan aware interfaces
[8:31:57] root:~ #

Reviewed-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:42:35 -08:00
0897d354c0 debian: changelog: 1.2.0: new entry for ipv6-addrgen attribute
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:42:35 -08:00
db61a1a8a0 debian: changelog: change version to 1.2.0
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 14:42:35 -08:00
d486dd0df0 ifupdown2 2.0.0 release
This is a major update coming all at once from master-next branch
master-next branch was started with --orphan option which is basically a new
branch without history.

The major changes are:
    - repackaging
    - cleanup the directory tree
    - rewritte setup.py to allow install from deb file or pypi (pip install)
    - add a Makefile to make things (like building a deb) easier
    - review all debian files

Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-12-13 11:43:32 -08:00
db65511035 closes: #810844: debian: control: Unlisted dependencies
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2018-03-13 14:48:27 +11:00
9a5c706f45 Merge remote-tracking branch 'cumulus/dev'
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2017-02-23 17:17:26 +07:00
23cba755ed debian: changelog: update changelog for new version cl3u10 (unreleased)
Signed-off-by: Julien Fortin <julien@cumulusnetworks.com>
2017-02-23 17:11:10 +07:00
8a5626d4f4 Merge remote-tracking branch 'origin/dev-next' into dev 2017-02-18 01:46:15 +07:00