Skip to content

working l2vlan sub-interface#49

Open
wungad wants to merge 4 commits intotelekom:mainfrom
wungad:l2vlan-sub-interface
Open

working l2vlan sub-interface#49
wungad wants to merge 4 commits intotelekom:mainfrom
wungad:l2vlan-sub-interface

Conversation

@wungad
Copy link

@wungad wungad commented Jun 19, 2023

This PR adds a working functionality when dealing with iana:l2vlan interface types. It requires that parent-interface exists and that it references an existing entry in the ietf-interfaces:intefaces list.

Without the change, interface plugin fails when doing the initial load:

[INF] ietf-interfaces-plugin: Loading initial system data
[ERR] Mandatory node "parent-interface" instance does not exist. (Schema location "/ietf-interfaces:interfaces/interface/ietf-if-extensions:parent-interface".)
[ERR] Validation failed.
[ERR] ietf-interfaces-plugin: sr_apply_changes() error (9): Validation failed
[ERR] srpc: /src/sysrepo-plugin-interfaces/src/interfaces/src/plugin.c:310 interfaces_running_load(ctx, running_session) error (-1)
[ERR] ietf-interfaces-plugin: Error occured while initializing the plugin (-1)
[ERR] sysrepo-plugind: Plugin "libsrplg-ietf-interfaces" initialization failed (User callback failed).
[INF] No datastore changes to apply.

This PR also makes it possible to add/change/remove ipv4/ipv6 routes using the routing plugin.

Note:
The issue doesn't affect setups that do not use iana:l2vlan (e.g. eth0.231) type interfaces and so could not be detected until now.

wungad added 4 commits June 19, 2023 13:14
load.c: interfaces_interface_load_parent_interface
load.h: interfaces_interface_load_parent_interface
call the new function in two places:
- src/interfaces/src/plugin/api/interfaces/load.c
- src/interfaces/src/plugin/data/interfaces/interface.c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant