ifstate 1.11.8__tar.gz → 1.12.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {ifstate-1.11.8 → ifstate-1.12.0}/PKG-INFO +1 -1
- {ifstate-1.11.8 → ifstate-1.12.0}/ifstate.egg-info/PKG-INFO +1 -1
- {ifstate-1.11.8 → ifstate-1.12.0}/ifstate.egg-info/SOURCES.txt +1 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/__init__.py +7 -3
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/address/__init__.py +12 -3
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/exception.py +5 -1
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/link/__init__.py +1 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/link/base.py +32 -18
- ifstate-1.12.0/libifstate/link/dsa.py +10 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/link/veth.py +6 -2
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/log.py +22 -8
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/routing/__init__.py +13 -4
- {ifstate-1.11.8 → ifstate-1.12.0}/schema/ifstate.conf.schema.json +199 -8
- {ifstate-1.11.8 → ifstate-1.12.0}/LICENSE +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/README.md +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/ifstate/__init__.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/ifstate/ifstate.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/ifstate/shell.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/ifstate/vrrp.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/ifstate.egg-info/dependency_links.txt +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/ifstate.egg-info/entry_points.txt +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/ifstate.egg-info/requires.txt +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/ifstate.egg-info/top_level.txt +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/bpf/__init__.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/bpf/ctypes.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/bpf/map.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/brport/__init__.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/fdb/__init__.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/link/physical.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/link/tun.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/neighbour/__init__.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/netns/__init__.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/parser/__init__.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/parser/base.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/parser/yaml.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/sysctl/__init__.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/tc/__init__.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/util.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/wireguard/__init__.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/libifstate/xdp/__init__.py +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/setup.cfg +0 -0
- {ifstate-1.11.8 → ifstate-1.12.0}/setup.py +0 -0
@@ -1,4 +1,4 @@
|
|
1
|
-
from libifstate.exception import LinkDuplicate
|
1
|
+
from libifstate.exception import LinkDuplicate, NetnsUnknown
|
2
2
|
from libifstate.link.base import ethtool_path, Link
|
3
3
|
from libifstate.address import Addresses
|
4
4
|
from libifstate.fdb import FDB
|
@@ -48,7 +48,7 @@ import json
|
|
48
48
|
import errno
|
49
49
|
import logging
|
50
50
|
|
51
|
-
__version__ = "1.
|
51
|
+
__version__ = "1.12.0"
|
52
52
|
|
53
53
|
|
54
54
|
class IfState():
|
@@ -519,7 +519,11 @@ class IfState():
|
|
519
519
|
if link_dep.netns is None:
|
520
520
|
self._apply_iface(do_apply, self.root_netns, link_dep, by_vrrp, vrrp_type, vrrp_name, vrrp_state)
|
521
521
|
else:
|
522
|
-
|
522
|
+
if link_dep.netns not in self.namespaces:
|
523
|
+
logger.warning("add link {} failed: netns '{}' is unknown".format(link_dep.ifname, link_dep.netns))
|
524
|
+
return
|
525
|
+
else:
|
526
|
+
self._apply_iface(do_apply, self.namespaces[link_dep.netns], link_dep, by_vrrp, vrrp_type, vrrp_name, vrrp_state)
|
523
527
|
|
524
528
|
# configure routing
|
525
529
|
logger.info("")
|
@@ -1,7 +1,7 @@
|
|
1
1
|
from libifstate.util import logger, IfStateLogging
|
2
2
|
from libifstate.exception import netlinkerror_classes
|
3
3
|
from ipaddress import ip_interface
|
4
|
-
from pyroute2.netlink.rtnl.ifaddrmsg import IFA_F_PERMANENT
|
4
|
+
from pyroute2.netlink.rtnl.ifaddrmsg import IFA_F_DADFAILED, IFA_F_PERMANENT
|
5
5
|
|
6
6
|
|
7
7
|
class Addresses():
|
@@ -25,20 +25,29 @@ class Addresses():
|
|
25
25
|
# get active ip addresses
|
26
26
|
ipr_addr = {}
|
27
27
|
addr_add = []
|
28
|
+
addr_renew = []
|
28
29
|
for addr in self.netns.ipr.get_addr(index=idx):
|
30
|
+
flags = addr.get_attr('IFA_FLAGS', 0)
|
29
31
|
ip = ip_interface(addr.get_attr('IFA_ADDRESS') +
|
30
32
|
'/' + str(addr['prefixlen']))
|
33
|
+
if flags & IFA_F_DADFAILED == IFA_F_DADFAILED:
|
34
|
+
logger.debug('{} has failed dad'.format(ip), extra={'iface': self.iface, 'netns': self.netns})
|
35
|
+
addr_renew.append(ip)
|
31
36
|
ipr_addr[ip] = addr
|
32
37
|
|
33
38
|
for addr in self.addresses:
|
34
|
-
if addr in ipr_addr:
|
39
|
+
if addr in ipr_addr and addr not in addr_renew:
|
35
40
|
logger.log_ok('addresses', '= {}'.format(addr.with_prefixlen))
|
36
41
|
del ipr_addr[addr]
|
37
42
|
else:
|
38
43
|
addr_add.append(addr)
|
44
|
+
for ip in ipr_addr.keys():
|
45
|
+
if addr.ip == ip.ip:
|
46
|
+
addr_renew.append(ip)
|
47
|
+
break
|
39
48
|
|
40
49
|
for ip, addr in ipr_addr.items():
|
41
|
-
if not any(ip in net for net in ignore):
|
50
|
+
if ip in addr_renew or not any(ip in net for net in ignore):
|
42
51
|
if not ign_dynamic or ipr_addr[ip]['flags'] & IFA_F_PERMANENT == IFA_F_PERMANENT:
|
43
52
|
logger.log_del('addresses', '- {}'.format(ip.with_prefixlen))
|
44
53
|
try:
|
@@ -104,5 +104,9 @@ class ParserParseError(Exception):
|
|
104
104
|
def exit_code(self):
|
105
105
|
return 2
|
106
106
|
|
107
|
-
class
|
107
|
+
class RouteDuplicate(Exception):
|
108
108
|
pass
|
109
|
+
|
110
|
+
class NetnsUnknown(Exception):
|
111
|
+
def __init__(self, netns):
|
112
|
+
self.args = (None, "netns '{}' is unknown".format(netns))
|
@@ -1,5 +1,5 @@
|
|
1
1
|
from libifstate.util import logger, IfStateLogging, LinkDependency
|
2
|
-
from libifstate.exception import ExceptionCollector, LinkTypeUnknown, netlinkerror_classes
|
2
|
+
from libifstate.exception import ExceptionCollector, LinkTypeUnknown, NetnsUnknown, netlinkerror_classes
|
3
3
|
from libifstate.brport import BRPort
|
4
4
|
from libifstate.routing import RTLookups
|
5
5
|
from abc import ABC, abstractmethod
|
@@ -76,6 +76,12 @@ class Link(ABC):
|
|
76
76
|
0x88a8: '802.1ad',
|
77
77
|
0x8100: '802.1q',
|
78
78
|
},
|
79
|
+
# === vxlan ===
|
80
|
+
'vxlan_df': {
|
81
|
+
0: 'unset',
|
82
|
+
1: 'set',
|
83
|
+
2: 'inherit',
|
84
|
+
},
|
79
85
|
}
|
80
86
|
attr_value_lookup = {
|
81
87
|
'group': RTLookups.group,
|
@@ -93,6 +99,7 @@ class Link(ABC):
|
|
93
99
|
'ip6gre',
|
94
100
|
'ip6gretap',
|
95
101
|
'geneve',
|
102
|
+
'sit',
|
96
103
|
'wireguard',
|
97
104
|
'xfrm',
|
98
105
|
]
|
@@ -240,14 +247,16 @@ class Link(ABC):
|
|
240
247
|
return ret
|
241
248
|
|
242
249
|
info = self.iface.get_attr('IFLA_LINKINFO')
|
243
|
-
|
244
|
-
|
250
|
+
op = getattr(info, 'get_attr', None)
|
251
|
+
if callable(op):
|
252
|
+
ret = op(nla)
|
245
253
|
if not ret is None:
|
246
254
|
return ret
|
247
255
|
|
248
|
-
info =
|
249
|
-
|
250
|
-
|
256
|
+
info = op('IFLA_INFO_DATA')
|
257
|
+
op = getattr(info, 'get_attr', None)
|
258
|
+
if callable(op):
|
259
|
+
ret = op(nla)
|
251
260
|
if not ret is None:
|
252
261
|
return ret
|
253
262
|
|
@@ -382,6 +391,9 @@ class Link(ABC):
|
|
382
391
|
if self.bind_netns is None:
|
383
392
|
return self.ifstate.root_netns
|
384
393
|
|
394
|
+
if not self.bind_netns in self.ifstate.namespaces:
|
395
|
+
raise NetnsUnknown(self.bind_netns)
|
396
|
+
|
385
397
|
return self.ifstate.namespaces.get(self.bind_netns)
|
386
398
|
|
387
399
|
def bind_needs_recreate(self, item):
|
@@ -389,13 +401,6 @@ class Link(ABC):
|
|
389
401
|
return False
|
390
402
|
|
391
403
|
bind_netns = self.get_bind_netns()
|
392
|
-
if bind_netns is None:
|
393
|
-
logger.warning('bind_netns "%s" is unknown',
|
394
|
-
self.bind_netns,
|
395
|
-
extra={
|
396
|
-
'iface': self.settings['ifname'],
|
397
|
-
'netns': self.netns})
|
398
|
-
return False
|
399
404
|
|
400
405
|
fn = self.get_bind_fn(item.netns.netns, item.index)
|
401
406
|
try:
|
@@ -462,11 +467,15 @@ class Link(ABC):
|
|
462
467
|
item = self.search_link_registry()
|
463
468
|
|
464
469
|
# check if bind_netns option requires a recreate
|
465
|
-
|
466
|
-
self.
|
467
|
-
|
470
|
+
try:
|
471
|
+
if item is not None and self.bind_needs_recreate(item):
|
472
|
+
self.idx = item.index
|
473
|
+
self.recreate(do_apply, sysctl, excpts)
|
468
474
|
|
469
|
-
|
475
|
+
self.settings = osettings
|
476
|
+
return excpts
|
477
|
+
except NetnsUnknown as ex:
|
478
|
+
excpts.add('apply', ex)
|
470
479
|
return excpts
|
471
480
|
|
472
481
|
# move interface into netns if required
|
@@ -528,7 +537,12 @@ class Link(ABC):
|
|
528
537
|
logger.log_add('link', oper)
|
529
538
|
|
530
539
|
settings = copy.deepcopy(self.settings)
|
531
|
-
|
540
|
+
try:
|
541
|
+
bind_netns = self.get_bind_netns()
|
542
|
+
except NetnsUnknown as ex:
|
543
|
+
excpts.add(oper, ex)
|
544
|
+
return excpts
|
545
|
+
|
532
546
|
if bind_netns is not None and bind_netns.netns != self.netns.netns:
|
533
547
|
logger.debug("handle link binding", extra={
|
534
548
|
'iface': self.settings['ifname'],
|
@@ -1,6 +1,6 @@
|
|
1
1
|
from libifstate.util import logger
|
2
2
|
from libifstate.link.base import Link
|
3
|
-
from libifstate.exception import LinkCannotAdd
|
3
|
+
from libifstate.exception import LinkCannotAdd, NetnsUnknown
|
4
4
|
|
5
5
|
class VethLink(Link):
|
6
6
|
def __init__(self, ifstate, netns, name, link, ethtool, vrrp, brport):
|
@@ -18,7 +18,11 @@ class VethLink(Link):
|
|
18
18
|
'''
|
19
19
|
result = super().create(do_apply, sysctl, excpts, oper)
|
20
20
|
|
21
|
-
|
21
|
+
try:
|
22
|
+
bind_netns = self.get_bind_netns()
|
23
|
+
except NetnsUnknown as ex:
|
24
|
+
excpts.add(oper, ex)
|
25
|
+
return excpts
|
22
26
|
peer_link = next(iter(bind_netns.ipr.get_links(ifname=self.settings['peer'])), None)
|
23
27
|
self.ifstate.link_registry.add_link(bind_netns, peer_link)
|
24
28
|
|
@@ -2,6 +2,7 @@ import logging
|
|
2
2
|
from logging.handlers import QueueHandler, QueueListener
|
3
3
|
import os
|
4
4
|
import queue
|
5
|
+
import stat
|
5
6
|
import sys
|
6
7
|
|
7
8
|
logger = logging.getLogger('ifstate')
|
@@ -10,6 +11,8 @@ logger.log_add = lambda option, oper='add': logger.info(oper, extra={'option': o
|
|
10
11
|
logger.log_change = lambda option, oper='change': logger.info(oper, extra={'option': option, 'style': IfStateLogging.STYLE_CHG})
|
11
12
|
logger.log_ok = lambda option, oper='ok': logger.info(oper, extra={'option': option, 'style': IfStateLogging.STYLE_OK})
|
12
13
|
logger.log_del = lambda option, oper='del': logger.info(oper, extra={'option': option, 'style': IfStateLogging.STYLE_DEL})
|
14
|
+
logger.log_err = lambda option, oper='warn': logger.error(oper, extra={'option': option})
|
15
|
+
logger.log_warn = lambda option, oper='warn': logger.warning(oper, extra={'option': option})
|
13
16
|
|
14
17
|
formatter = logging.Formatter('%(bol)s%(prefix)s%(style)s%(message)s%(eol)s')
|
15
18
|
|
@@ -96,14 +99,25 @@ class IfStateLogging:
|
|
96
99
|
handlers.append(stream)
|
97
100
|
|
98
101
|
# log to syslog
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
102
|
+
socket_filename = '/dev/log'
|
103
|
+
try:
|
104
|
+
if not stat.S_ISSOCK(os.stat(socket_filename).st_mode):
|
105
|
+
socket_filename = None
|
106
|
+
except OSError:
|
107
|
+
socket_filename = None
|
108
|
+
|
109
|
+
if socket_filename is not None:
|
110
|
+
syslog = logging.handlers.SysLogHandler(socket_filename, facility=logging.handlers.SysLogHandler.LOG_DAEMON)
|
111
|
+
if action is None:
|
112
|
+
syslog.ident = 'ifstate[{}] '.format(os.getpid())
|
113
|
+
else:
|
114
|
+
syslog.ident = 'ifstate-{}[{}] '.format(action, os.getpid())
|
115
|
+
syslog.addFilter(IfStateLogFilter(False))
|
116
|
+
syslog.setFormatter(formatter)
|
117
|
+
handlers.append(syslog)
|
118
|
+
|
119
|
+
if len(handlers) == 0:
|
120
|
+
handlers.append(logging.NullHandler())
|
107
121
|
|
108
122
|
qu = queue.SimpleQueue()
|
109
123
|
queue_handler = QueueHandler(qu)
|
@@ -1,5 +1,5 @@
|
|
1
1
|
from libifstate.util import logger, IfStateLogging
|
2
|
-
from libifstate.exception import
|
2
|
+
from libifstate.exception import RouteDuplicate, netlinkerror_classes
|
3
3
|
from ipaddress import ip_address, ip_network, IPv6Network
|
4
4
|
from pyroute2.netlink.rtnl.fibmsg import FR_ACT_VALUES
|
5
5
|
from pyroute2.netlink.rtnl import rt_type
|
@@ -90,7 +90,7 @@ class RTLookup():
|
|
90
90
|
return self.str2id[key]
|
91
91
|
|
92
92
|
def lookup_str(self, key):
|
93
|
-
return self.id2str.get(key, key)
|
93
|
+
return self.id2str.get(key, str(key))
|
94
94
|
|
95
95
|
|
96
96
|
class RTLookups():
|
@@ -309,8 +309,17 @@ class Tables(collections.abc.Mapping):
|
|
309
309
|
|
310
310
|
for route in croutes:
|
311
311
|
if 'oif' in route and type(route['oif']) == str:
|
312
|
-
|
312
|
+
oif = next(
|
313
313
|
iter(self.netns.ipr.link_lookup(ifname=route['oif'])), None)
|
314
|
+
if oif is None:
|
315
|
+
if 'gateway' in route:
|
316
|
+
logger.log_warn(log_str, '! {}: dev {} is unknown'.format(route['dst'], route['oif']))
|
317
|
+
del route['oif']
|
318
|
+
else:
|
319
|
+
logger.log_err(log_str, '! {}: dev {} is unknown'.format(route['dst'], route['oif']))
|
320
|
+
continue
|
321
|
+
else:
|
322
|
+
route['oif'] = oif
|
314
323
|
found = False
|
315
324
|
identical = False
|
316
325
|
matched = vrrp_match(route, by_vrrp, vrrp_type, vrrp_name, vrrp_state)
|
@@ -554,7 +563,7 @@ class Rules():
|
|
554
563
|
if ignore:
|
555
564
|
continue
|
556
565
|
|
557
|
-
logger.log_del(
|
566
|
+
logger.log_del('#{}'.format(rule['priority']))
|
558
567
|
try:
|
559
568
|
if do_apply:
|
560
569
|
self.netns.ipr.rule('del', **rule)
|
@@ -2,7 +2,7 @@
|
|
2
2
|
"$id": "https://ifstate.net/schema/ifstate.conf.schema.json",
|
3
3
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
4
4
|
"title": "ifstate.conf",
|
5
|
-
"description": "IfState 1.11.
|
5
|
+
"description": "IfState 1.11.9 Configuration Schema",
|
6
6
|
"type": "object",
|
7
7
|
"required": [
|
8
8
|
"interfaces"
|
@@ -1783,7 +1783,8 @@
|
|
1783
1783
|
"items": {
|
1784
1784
|
"type": "object",
|
1785
1785
|
"required": [
|
1786
|
-
"name"
|
1786
|
+
"name",
|
1787
|
+
"link"
|
1787
1788
|
],
|
1788
1789
|
"additionalProperties": false,
|
1789
1790
|
"properties": {
|
@@ -1887,7 +1888,9 @@
|
|
1887
1888
|
"items": {
|
1888
1889
|
"type": "object",
|
1889
1890
|
"additionalProperties": false,
|
1890
|
-
"required": [
|
1891
|
+
"required": [
|
1892
|
+
"lladdr"
|
1893
|
+
],
|
1891
1894
|
"properties": {
|
1892
1895
|
"lladdr": {
|
1893
1896
|
"description": "destination link layer address",
|
@@ -1959,6 +1962,9 @@
|
|
1959
1962
|
"link": {
|
1960
1963
|
"description": "link settings of the interface",
|
1961
1964
|
"type": "object",
|
1965
|
+
"required": [
|
1966
|
+
"kind"
|
1967
|
+
],
|
1962
1968
|
"oneOf": [
|
1963
1969
|
{
|
1964
1970
|
"description": "Intermediate Functional Block device",
|
@@ -2737,6 +2743,51 @@
|
|
2737
2743
|
}
|
2738
2744
|
}
|
2739
2745
|
},
|
2746
|
+
{
|
2747
|
+
"description": "DSA interface",
|
2748
|
+
"required": [
|
2749
|
+
"kind",
|
2750
|
+
"link"
|
2751
|
+
],
|
2752
|
+
"additionalProperties": false,
|
2753
|
+
"properties": {
|
2754
|
+
"kind": {
|
2755
|
+
"const": "dsa",
|
2756
|
+
"description": "link type"
|
2757
|
+
},
|
2758
|
+
"address": {
|
2759
|
+
"$ref": "#/$defs/iface-link_address"
|
2760
|
+
},
|
2761
|
+
"group": {
|
2762
|
+
"$ref": "#/$defs/iface-link_group"
|
2763
|
+
},
|
2764
|
+
"permaddr": {
|
2765
|
+
"description": "select interface by permanent address [ethtool -P]",
|
2766
|
+
"$ref": "#/$defs/iface-link_address"
|
2767
|
+
},
|
2768
|
+
"state": {
|
2769
|
+
"$ref": "#/$defs/iface-link_state"
|
2770
|
+
},
|
2771
|
+
"master": {
|
2772
|
+
"$ref": "#/$defs/iface-link_master"
|
2773
|
+
},
|
2774
|
+
"mtu": {
|
2775
|
+
"$ref": "#/$defs/iface-link_mtu"
|
2776
|
+
},
|
2777
|
+
"txqlen": {
|
2778
|
+
"$ref": "#/$defs/iface-link_txqlen"
|
2779
|
+
},
|
2780
|
+
"ifalias": {
|
2781
|
+
"$ref": "#/$defs/iface-link_ifalias"
|
2782
|
+
},
|
2783
|
+
"link": {
|
2784
|
+
"$ref": "#/$defs/iface-link_link"
|
2785
|
+
},
|
2786
|
+
"link_netns": {
|
2787
|
+
"$ref": "#/$defs/iface-link_link-netns"
|
2788
|
+
}
|
2789
|
+
}
|
2790
|
+
},
|
2740
2791
|
{
|
2741
2792
|
"description": "Dummy network interface",
|
2742
2793
|
"required": [
|
@@ -2805,7 +2856,7 @@
|
|
2805
2856
|
"null"
|
2806
2857
|
],
|
2807
2858
|
"description": "specifies the peer's netns name or null if the peer isn't in a netns namespace"
|
2808
|
-
|
2859
|
+
},
|
2809
2860
|
"state": {
|
2810
2861
|
"$ref": "#/$defs/iface-link_state"
|
2811
2862
|
},
|
@@ -2920,17 +2971,154 @@
|
|
2920
2971
|
"$ref": "#/$defs/iface-link_ifalias"
|
2921
2972
|
},
|
2922
2973
|
"vxlan_id": {
|
2923
|
-
"type":
|
2924
|
-
"integer"
|
2925
|
-
],
|
2974
|
+
"type": "integer",
|
2926
2975
|
"minimum": 0,
|
2927
2976
|
"maximum": 16777215,
|
2928
2977
|
"description": "specifies the VNI"
|
2929
2978
|
},
|
2979
|
+
"vxlan_ageing": {
|
2980
|
+
"type": "integer",
|
2981
|
+
"minimum": 0,
|
2982
|
+
"maximum": 4294967296,
|
2983
|
+
"description": "specifies the lifetime in seconds of FDB entries learnt by the kernel (0: none)",
|
2984
|
+
"default": 300
|
2985
|
+
},
|
2986
|
+
"vxlan_df": {
|
2987
|
+
"enum": [
|
2988
|
+
0,
|
2989
|
+
"unset",
|
2990
|
+
1,
|
2991
|
+
"set",
|
2992
|
+
2,
|
2993
|
+
"inherit"
|
2994
|
+
],
|
2995
|
+
"default": "unset",
|
2996
|
+
"description": "specifies the usage of the DF bit in outgoing packets with IPv4 headers"
|
2997
|
+
},
|
2998
|
+
"vxlan_label": {
|
2999
|
+
"type": "integer",
|
3000
|
+
"minimum": 0,
|
3001
|
+
"maximum": 1048575,
|
3002
|
+
"description": "specifies a fixed flowlabel"
|
3003
|
+
},
|
3004
|
+
"vxlan_learning": {
|
3005
|
+
"type": "integer",
|
3006
|
+
"minimum": 0,
|
3007
|
+
"maximum": 1,
|
3008
|
+
"description": "specifies if unknown source link layer addresses and IP addresses are entered into the VXLAN device fdb",
|
3009
|
+
"default": 1
|
3010
|
+
},
|
3011
|
+
"vxlan_limit": {
|
3012
|
+
"type": "integer",
|
3013
|
+
"minimum": 0,
|
3014
|
+
"maximum": 4294967296,
|
3015
|
+
"description": "specifies the maximum number of FDB entries (0: none)",
|
3016
|
+
"default": 0
|
3017
|
+
},
|
3018
|
+
"vxlan_proxy": {
|
3019
|
+
"type": "integer",
|
3020
|
+
"minimum": 0,
|
3021
|
+
"maximum": 1,
|
3022
|
+
"description": "specifies if ARP proxy is turned on",
|
3023
|
+
"default": 0
|
3024
|
+
},
|
3025
|
+
"vxlan_rsc": {
|
3026
|
+
"type": "integer",
|
3027
|
+
"minimum": 0,
|
3028
|
+
"maximum": 1,
|
3029
|
+
"description": "specifies if route short circuit is turned on",
|
3030
|
+
"default": 0
|
3031
|
+
},
|
3032
|
+
"vxlan_l2miss": {
|
3033
|
+
"type": "integer",
|
3034
|
+
"minimum": 0,
|
3035
|
+
"maximum": 1,
|
3036
|
+
"description": "specifies if netlink LLADDR miss notifications are generated",
|
3037
|
+
"default": 0
|
3038
|
+
},
|
3039
|
+
"vxlan_l3miss": {
|
3040
|
+
"type": "integer",
|
3041
|
+
"minimum": 0,
|
3042
|
+
"maximum": 1,
|
3043
|
+
"description": "specifies if netlink IP ADDR miss notifications are generated",
|
3044
|
+
"default": 0
|
3045
|
+
},
|
3046
|
+
"vxlan_udp_csum": {
|
3047
|
+
"type": "integer",
|
3048
|
+
"minimum": 0,
|
3049
|
+
"maximum": 1,
|
3050
|
+
"description": "specifies if UDP checksum is calculated for tx packets over IPv4",
|
3051
|
+
"default": 1
|
3052
|
+
},
|
2930
3053
|
"vxlan_link": {
|
2931
3054
|
"$ref": "#/$defs/iface-link_tun-dev"
|
3055
|
+
},
|
3056
|
+
"vxlan_local": {
|
3057
|
+
"type": "string",
|
3058
|
+
"description": "tunnel source ip address",
|
3059
|
+
"oneOf": [
|
3060
|
+
{
|
3061
|
+
"format": "ipv4"
|
3062
|
+
},
|
3063
|
+
{
|
3064
|
+
"format": "ipv6"
|
3065
|
+
}
|
3066
|
+
]
|
3067
|
+
},
|
3068
|
+
"vxlan_group": {
|
3069
|
+
"type": "string",
|
3070
|
+
"description": "remote unicast destination or multicast group IPv4 address",
|
3071
|
+
"format": "ipv4"
|
3072
|
+
},
|
3073
|
+
"vxlan_group6": {
|
3074
|
+
"type": "string",
|
3075
|
+
"description": "remote unicast destination or multicast group IPv6 address",
|
3076
|
+
"format": "ipv6"
|
3077
|
+
},
|
3078
|
+
"vxlan_tos": {
|
3079
|
+
"type": "integer",
|
3080
|
+
"description": "specifies the TOS value to use in outgoing packets (0: inherit)",
|
3081
|
+
"minimum": 0,
|
3082
|
+
"maximum": 255,
|
3083
|
+
"default": 0
|
3084
|
+
},
|
3085
|
+
"vxlan_ttl": {
|
3086
|
+
"type": "integer",
|
3087
|
+
"description": "specifies the TTL value to use in outgoing packets (0: auto)",
|
3088
|
+
"minimum": 0,
|
3089
|
+
"maximum": 255,
|
3090
|
+
"default": 0
|
3091
|
+
},
|
3092
|
+
"vxlan_ttl_inherit": {
|
3093
|
+
"type": "boolean",
|
3094
|
+
"description": "control whether TTL is propagated",
|
3095
|
+
"default": false
|
2932
3096
|
}
|
2933
|
-
}
|
3097
|
+
},
|
3098
|
+
"anyOf": [
|
3099
|
+
{
|
3100
|
+
"oneOf": [
|
3101
|
+
{
|
3102
|
+
"required": [
|
3103
|
+
"vxlan_group"
|
3104
|
+
]
|
3105
|
+
},
|
3106
|
+
{
|
3107
|
+
"required": [
|
3108
|
+
"vxlan_group6"
|
3109
|
+
]
|
3110
|
+
}
|
3111
|
+
]
|
3112
|
+
},
|
3113
|
+
{
|
3114
|
+
"not": {
|
3115
|
+
"required": [
|
3116
|
+
"vxlan_group",
|
3117
|
+
"vxlan_group6"
|
3118
|
+
]
|
3119
|
+
}
|
3120
|
+
}
|
3121
|
+
]
|
2934
3122
|
},
|
2935
3123
|
{
|
2936
3124
|
"description": "IPIP interface",
|
@@ -2993,6 +3181,9 @@
|
|
2993
3181
|
"address": {
|
2994
3182
|
"$ref": "#/$defs/iface-link_address"
|
2995
3183
|
},
|
3184
|
+
"bind_netns": {
|
3185
|
+
"$ref": "#/$defs/iface-link_bind-netns"
|
3186
|
+
},
|
2996
3187
|
"group": {
|
2997
3188
|
"$ref": "#/$defs/iface-link_group"
|
2998
3189
|
},
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|