Page MenuHomeVyOS Platform

Flow-accounting IPv6 server/receiver bug
Closed, ResolvedPublicBUG

Description

When we use IPv6 address as Netflow server uacctd generates plugin name with "colons" ::
Example VyOS configuration

set system flow-accounting interface 'eth0'
set system flow-accounting interface 'eth1'
set system flow-accounting netflow engine-id '100'
set system flow-accounting netflow sampling-rate '1'
set system flow-accounting netflow server 2001:db8::1 port '2055'
set system flow-accounting netflow source-ip 2001:db8::2
set system flow-accounting netflow timeout expiry-interval '60'
set system flow-accounting netflow version '9'

uacctd doesn't like this format:

root@r1:/home/vyos# pmacctd -f /etc/pmacct/uacctd.conf -i eth0
ERROR: [/etc/pmacct/uacctd.conf:14] Syntax error: illegal brackets. Exiting.
root@r1:/home/vyos#

Generated config:

root@r1:/home/vyos# cat /etc/pmacct/uacctd.conf 
# Genereated from VyOS configuration
daemonize: true
promisc: false
pidfile: /var/run/uacctd.pid
uacctd_group: 2
uacctd_nl_size: 2097152
snaplen: 128
aggregate: in_iface,src_mac,dst_mac,vlan,src_host,dst_host,src_port,dst_port,proto,tos,flows
plugin_pipe_size: 10485760
plugin_buffer_size: 10485
imt_path: /tmp/uacctd.pipe
imt_mem_pools_number: 169
plugins: nfprobe[nf_2001:db8::1],memory
nfprobe_receiver[nf_2001:db8::1]: 2001:db8::1:2055  <== line 14
nfprobe_version[nf_2001:db8::1]: 9
nfprobe_engine[nf_2001:db8::1]: 100
sampling_rate[nf_2001:db8::1]: 1
nfprobe_source_ip[nf_2001:db8::1]: 2001:db8::2
nfprobe_timeouts[nf_2001:db8::1]: expint=60

To fix it we have to use dash or underscore

Also, it must use brackets
Wrong format:

nfprobe_receiver[nf_2001:db8::1]: 2001:db8::1:2055

Expected format:

nfprobe_receiver[nf_2001-db8--1]: [2001:db8::1]:2055

Details

Difficulty level
Normal (likely a few hours)
Version
VyOS 1.3-stable-202207110427
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Unspecified (possibly destroys the router)
Issue type
Bug (incorrect behavior)

Related Objects

Mentioned In
1.3.2
1.3.2

Event Timeline

Viacheslav renamed this task from Flow-accounting ipv6 server/receiver bug to Flow-accounting IPv6 server/receiver bug.Jul 14 2022, 12:54 PM
Viacheslav changed the task status from Open to In progress.
Viacheslav created this task.
Viacheslav edited projects, added VyOS 1.3 Equuleus (1.3.2); removed VyOS 1.3 Equuleus.
Viacheslav updated the task description. (Show Details)