Page MenuHomeVyOS Platform

Configuring DHCPv6-PD without a interface to delegate to raises TypeError
Closed, ResolvedPublicBUG

Description

From the forums: https://forum.vyos.io/t/failed-to-commit-with-specific-dhcpv6-options-parameter/5943

The DHCPv6 options require an interface where to delegate the prefix to

+    dhcpv6-options {
+        pd 0 {
+            length 56
+        }
+    }
[email protected]# set interfaces ethernet eth1 dhcpv6-options pd 0 length 56
[edit]
[email protected]# commit
[ interfaces ethernet eth1 ]
VyOS had an issue completing a command.

We are sorry that you encountered a problem while using VyOS.
There are a few things you can do to help us (and yourself):
- Make sure you are running the latest version of the code available at
  https://downloads.vyos.io/rolling/current/amd64/vyos-rolling-latest.iso
- Consult the forum to see how to handle this issue
  https://forum.vyos.io
- Join our community on slack where our users exchange help and advice
  https://vyos.slack.com

When reporting problems, please include as much information as possible:
- do not obfuscate any data (feel free to contact us privately if your
  business policy requires it)
- and include all the information presented below

Report Time:      2020-09-24 21:24:07
Image Version:    VyOS 1.3-rolling-202009201335
Release Train:    equuleus

Built by:         [email protected]
Built on:         Sun 20 Sep 2020 13:35 UTC
Build UUID:       187fd1d5-d402-42f0-b751-404d695196a7
Build Commit ID:  d571b383797719

Architecture:     x86_64
Boot via:         installed image
System type:      VMware guest

Hardware vendor:  VMware, Inc.
Hardware model:   VMware Virtual Platform
Hardware S/N:     VMware-42 3f 67 73 77 df c4 80-42 c9 42 af ff 15 de 0b
Hardware UUID:    73673f42-df77-80c4-42c9-42afff15de0b

Traceback (most recent call last):
  File "/usr/libexec/vyos/conf_mode/interfaces-ethernet.py", line 87, in <module>
    verify(c)
  File "/usr/libexec/vyos/conf_mode/interfaces-ethernet.py", line 60, in verify
    verify_dhcpv6(ethernet)
  File "/usr/lib/python3/dist-packages/vyos/configverify.py", line 116, in verify_dhcpv6
    for interface in vyos_dict_search(f'dhcpv6_options.pd.{pd}.interface', config):
TypeError: 'NoneType' object is not iterable

Details

Difficulty level
Normal (likely a few hours)
Version
1.3-rolling-202009201335
Why the issue appeared?
Implementation mistake
Is it a breaking change?
Stricter validation
Issue type
Bug (incorrect behavior)

Event Timeline

c-po created this task.
c-po updated the task description. (Show Details)

After the fix an error is reported on the CLI:

[email protected]# commit
[ interfaces ethernet eth1 ]
DHCPv6-PD requires an interface where to assign the delegated prefix!
c-po triaged this task as Normal priority.
c-po changed Why the issue appeared? from Will be filled on close to Implementation mistake.
c-po changed Is it a breaking change? from Unspecified (possibly destroys the router) to Stricter validation.
erkin set Issue type to Bug (incorrect behavior).Aug 29 2021, 12:55 PM
erkin removed a subscriber: Active contributors.