Page MenuHomeVyOS Platform

Show conntrack table ipv6 fail
Closed, ResolvedPublicBUG

Description

Command show conntrack table ipv6 fail

The configuration is clean.

vyos@vyos:~$ show conntrack table ipv6
Traceback (most recent call last):
  File "/usr/libexec/vyos/op_mode/conntrack.py", line 139, in <module>
    res = vyos.opmode.run(sys.modules[__name__])
  File "/usr/lib/python3/dist-packages/vyos/opmode.py", line 147, in run
    res = func(**args)
  File "/usr/libexec/vyos/op_mode/conntrack.py", line 122, in show
    conntrack_data = _get_raw_data(family)
  File "/usr/libexec/vyos/op_mode/conntrack.py", line 51, in _get_raw_data
    return _xml_to_dict(xml)
  File "/usr/libexec/vyos/op_mode/conntrack.py", line 39, in _xml_to_dict
    parse = xmltodict.parse(xml, attr_prefix='')
  File "/usr/lib/python3/dist-packages/xmltodict.py", line 327, in parse
    parser.Parse(xml_input, True)
xml.parsers.expat.ExpatError: no element found: line 1, column 0
vyos@vyos:~$ show ver
Version:          VyOS 1.4-rolling-202210090955
Release train:    current

Built by:         [email protected]
Built on:         Sun 09 Oct 2022 09:55 UTC
Build UUID:       e1dc468d-552c-49ba-a072-3f0ca1bf1dde
Build commit ID:  4f7f3ee8142bf6

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

Hardware vendor:  QEMU
Hardware model:   Standard PC (i440FX + PIIX, 1996)
Hardware S/N:
Hardware UUID:    36df08eb-2a09-48a0-90c7-9081fb070579

Copyright:        VyOS maintainers and contributors

Details

Difficulty level
Normal (likely a few hours)
Version
VyOS 1.4-rolling-202210090955
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Perfectly compatible
Issue type
Bug (incorrect behavior)

Event Timeline

I have tested it again. So it happens only if conntrack table is empty.
The same problem with IPv4.

vyos@vyos:~$ reset conntrack
This will clear all currently tracked and expected connections. Continue? [y/N] y
vyos@vyos:~$ show conntrack table ipv4
Traceback (most recent call last):
  File "/usr/libexec/vyos/op_mode/conntrack.py", line 139, in <module>
    res = vyos.opmode.run(sys.modules[__name__])
  File "/usr/lib/python3/dist-packages/vyos/opmode.py", line 147, in run
    res = func(**args)
  File "/usr/libexec/vyos/op_mode/conntrack.py", line 122, in show
    conntrack_data = _get_raw_data(family)
  File "/usr/libexec/vyos/op_mode/conntrack.py", line 51, in _get_raw_data
    return _xml_to_dict(xml)
  File "/usr/libexec/vyos/op_mode/conntrack.py", line 39, in _xml_to_dict
    parse = xmltodict.parse(xml, attr_prefix='')
  File "/usr/lib/python3/dist-packages/xmltodict.py", line 327, in parse
    parser.Parse(xml_input, True)
xml.parsers.expat.ExpatError: no element found: line 1, column 0
vyos@vyos# set interfaces ethernet eth0 address 200::200:200:1/64
[edit]
vyos@vyos# commit

vyos@vyos:~$ ping 200::200:200:2
PING 200::200:200:2(200::200:200:2) 56 data bytes
^C
--- 200::200:200:2 ping statistics ---
3 packets transmitted, 0 received, 100% packet loss, time 2072ms

vyos@vyos:~$ show conntrack table ipv6
Id          Original src    Original dst    Reply src       Reply dst       Protocol    State    Timeout    Mark    Zone
----------  --------------  --------------  --------------  --------------  ----------  -------  ---------  ------  ------
2396430652  200::200:200:1  200::200:200:2  200::200:200:2  200::200:200:1  icmpv6               23         0
vyos@vyos:~$
Viacheslav changed the task status from Open to In progress.Oct 10 2022, 7:59 PM
Viacheslav claimed this task.

PR https://github.com/vyos/vyos-1x/pull/1581

vyos@r14:~$ show conntrack table ipv6
Entries not found
vyos@r14:~$
Viacheslav changed the task status from In progress to Needs testing.Oct 11 2022, 5:46 PM
Viacheslav moved this task from Need Triage to Finished on the VyOS 1.4 Sagitta board.