Page MenuHomeVyOS Platform

Error on removing dhcpv6 address from interface
Closed, ResolvedPublicBUG

Description

Reproducing steps:

  1. Get address from DHCPv6
set interfaces ethernet eth0 address 'dhcp'
set interfaces ethernet eth0 address 'dhcpv6'
  1. Delete and commit dhcpv6
vyos@vyos# delete interfaces ethernet eth0 address dhcpv6 
[edit]
vyos@vyos# commit
[ interfaces ethernet eth0 address dhcpv6 ]
Traceback (most recent call last):
  File "/usr/libexec/vyos/system/normalize-ip", line 32, in <module>
    address_string, prefix_length = re.match(r'(.+)/(.+)', sys.argv[1]).groups()
AttributeError: 'NoneType' object has no attribute 'groups'
Stopping daemon...
Killed old client process
Deleting related files...

Details

Difficulty level
Normal (likely a few hours)
Version
1.2.7-epa1
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Unspecified (possibly destroys the router)

Event Timeline

Unknown Object (User) created this task.Mar 8 2021, 4:26 PM

Does not reproducing on eve-ng.

1.jpg (285×429 px, 40 KB)

A similar problem, only for ipv4 https://phabricator.vyos.net/T1053
As we can see ipv6 address before normalization without prefix
DEBUG: 2001:db8::191 before normalize
https://github.com/vyos/vyatta-cfg-system/blob/165e56e88763c40f13e6ef77f5df1c888fdfb899/scripts/vyatta-address#L38

set interfaces ethernet eth1 address 'dhcp'

set interfaces ethernet eth1 address 'dhcpv6'
commit
sudo sleep 5

vyos@r2-lts# del interfaces ethernet eth1 address
[edit]
vyos@r2-lts# commit
[ interfaces ethernet eth1 address dhcp ]

*** ipv4
DEBUG: ARG 2 is: eth1
DEBUG: ARG 3 is: dhcp
DEBUG: 192.168.101.146/24 before normalize
DEBUG: 192.168.101.146/24  after normalize
***

Stopping DHCP client on eth1 ...

[ interfaces ethernet eth1 address dhcpv6 ]
*** ipv6
DEBUG: ARG 2 is: eth1
DEBUG: ARG 3 is: dhcpv6
DEBUG: 2001:db8::191 before normalize

Traceback (most recent call last):
  File "/usr/libexec/vyos/system/normalize-ip", line 36, in <module>
    address_string, prefix_length = re.match(r'(.+)/(.+)', sys.argv[1]).groups()
AttributeError: 'NoneType' object has no attribute 'groups'
DEBUG:   after normalize
***
Stopping daemon...
Killed old client process
Deleting related files...

Normalize dhcpv6 address

vyos@r2-lts# /usr/libexec/vyos/system/normalize-ip 2001:db8::191
Traceback (most recent call last):
  File "/usr/libexec/vyos/system/normalize-ip", line 32, in <module>
    address_string, prefix_length = re.match(r'(.+)/(.+)', sys.argv[1]).groups()
AttributeError: 'NoneType' object has no attribute 'groups'
[edit]
vyos@r2-lts#
Viacheslav changed the task status from Open to In progress.Oct 29 2021, 6:02 PM