Page MenuHomeVyOS Platform

Howto perform IGMP memebership management?
OpenPublic

Asked by aopdal on Nov 27 2017, 1:18 PM.

Details

In my testlab I have observed a issue regarding multicast.
I'm using VRRP and OSPF which is both depending on multicast.

First time I observied it was when testing OSPF and did not get routing updates as expected.
In the log /var/log/messages i found:
Nov 23 16:22:53 o6-nav-test ospfd[2433]: can't setsockopt IP_ADD_MEMBERSHIP (fd 8, addr 172.18.160.98, ifindex 19, AllDRouters): No buffer space available; perhaps a kernel limit on # of multicast group memberships has been exceeded?

The file /proc/sys/net/ipv4/igmp_max_memberships has a value of 20 which is default in the kernel.

Using VRRP and OSPF you reach 20 groups quite easy

When i create a new interface I get the error loged, if I reboot it starts to work. If I remnove the interface - reboot and add the interface the error comes again.
If I do echo 40 > /proc/sys/net/ipv4/igmp_max_memberships
Then add the interface I don't get the error.

We need to handle this, and perhaps we should have a /config/scripts/preconfig.script which could be run before the config is applied.

I don't have a proposed solution, but a lot of problems related to routing, VRRP, sync of connection tracking could be depending on this.

The router I observed this has the following configuration:

vyos@o6-nav-test:~$ sh configuration commands
set interfaces ethernet eth0 address 'dhcp'
set interfaces ethernet eth0 duplex 'auto'
set interfaces ethernet eth0 hw-id '00:50:56:a7:e7:3f'
set interfaces ethernet eth0 mtu '1524'
set interfaces ethernet eth0 smp_affinity 'auto'
set interfaces ethernet eth0 speed 'auto'
set interfaces ethernet eth0 vif 206 address '172.18.41.21/24'
set interfaces ethernet eth0 vif 206 ip ospf cost '10'
set interfaces ethernet eth0 vif 206 ip ospf dead-interval '4'
set interfaces ethernet eth0 vif 206 ip ospf hello-interval '1'
set interfaces ethernet eth0 vif 206 ip ospf priority '1'
set interfaces ethernet eth0 vif 206 ip ospf retransmit-interval '5'
set interfaces ethernet eth0 vif 206 ip ospf transmit-delay '1'
set interfaces ethernet eth0 vif 206 mtu '1524'
set interfaces ethernet eth1 duplex 'auto'
set interfaces ethernet eth1 hw-id '00:50:56:a7:44:93'
set interfaces ethernet eth1 mtu '1524'
set interfaces ethernet eth1 smp_affinity 'auto'
set interfaces ethernet eth1 speed 'auto'
set interfaces ethernet eth1 vif 1700 address '172.18.160.1/29'
set interfaces ethernet eth1 vif 1700 ip ospf cost '1'
set interfaces ethernet eth1 vif 1700 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1700 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1700 ip ospf priority '1'
set interfaces ethernet eth1 vif 1700 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1700 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1701 address '172.18.160.9/29'
set interfaces ethernet eth1 vif 1701 ip ospf cost '1'
set interfaces ethernet eth1 vif 1701 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1701 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1701 ip ospf priority '1'
set interfaces ethernet eth1 vif 1701 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1701 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1702 address '172.18.160.17/29'
set interfaces ethernet eth1 vif 1702 ip ospf cost '1'
set interfaces ethernet eth1 vif 1702 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1702 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1702 ip ospf priority '1'
set interfaces ethernet eth1 vif 1702 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1702 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1703 address '172.18.160.25/29'
set interfaces ethernet eth1 vif 1703 ip ospf cost '1'
set interfaces ethernet eth1 vif 1703 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1703 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1703 ip ospf priority '1'
set interfaces ethernet eth1 vif 1703 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1703 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1704 address '172.18.160.33/29'
set interfaces ethernet eth1 vif 1704 ip ospf cost '1'
set interfaces ethernet eth1 vif 1704 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1704 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1704 ip ospf priority '1'
set interfaces ethernet eth1 vif 1704 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1704 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1705 address '172.18.160.41/29'
set interfaces ethernet eth1 vif 1705 ip ospf cost '1'
set interfaces ethernet eth1 vif 1705 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1705 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1705 ip ospf priority '1'
set interfaces ethernet eth1 vif 1705 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1705 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1706 address '172.18.160.49/29'
set interfaces ethernet eth1 vif 1706 ip ospf cost '1'
set interfaces ethernet eth1 vif 1706 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1706 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1706 ip ospf priority '1'
set interfaces ethernet eth1 vif 1706 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1706 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1712 address '172.18.160.98/29'
set interfaces ethernet eth1 vif 1712 ip ospf cost '1'
set interfaces ethernet eth1 vif 1712 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1712 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1712 ip ospf priority '1'
set interfaces ethernet eth1 vif 1712 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1712 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1712 mtu '1524'
set interfaces ethernet eth1 vif 1721 address '172.18.160.170/29'
set interfaces ethernet eth1 vif 1721 ip ospf cost '1'
set interfaces ethernet eth1 vif 1721 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1721 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1721 ip ospf priority '1'
set interfaces ethernet eth1 vif 1721 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1721 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1722 address '172.18.160.178/29'
set interfaces ethernet eth1 vif 1722 ip ospf cost '1'
set interfaces ethernet eth1 vif 1722 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1722 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1722 ip ospf priority '1'
set interfaces ethernet eth1 vif 1722 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1722 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1727 address '172.18.160.217/29'
set interfaces ethernet eth1 vif 1727 ip ospf cost '1'
set interfaces ethernet eth1 vif 1727 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1727 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1727 ip ospf priority '1'
set interfaces ethernet eth1 vif 1727 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1727 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1729 address '172.18.160.237/29'
set interfaces ethernet eth1 vif 1729 ip ospf cost '1'
set interfaces ethernet eth1 vif 1729 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1729 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1729 ip ospf priority '1'
set interfaces ethernet eth1 vif 1729 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1729 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1729 vrrp vrrp-group 5 advertise-interval '1'
set interfaces ethernet eth1 vif 1729 vrrp vrrp-group 5 preempt 'false'
set interfaces ethernet eth1 vif 1729 vrrp vrrp-group 5 priority '150'
set interfaces ethernet eth1 vif 1729 vrrp vrrp-group 5 virtual-address '172.18.160.236/29'
set interfaces ethernet eth1 vif 1737 address '172.18.161.42/29'
set interfaces ethernet eth1 vif 1737 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1737 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1737 ip ospf priority '1'
set interfaces ethernet eth1 vif 1737 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1737 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1737 mtu '1524'
set interfaces ethernet eth1 vif 1743 address '172.18.161.106/29'
set interfaces ethernet eth1 vif 1743 ip ospf cost '1'
set interfaces ethernet eth1 vif 1743 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1743 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1743 ip ospf priority '1'
set interfaces ethernet eth1 vif 1743 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1743 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1743 mtu '1524'
set interfaces ethernet eth1 vif 1746 address '172.18.161.130/29'
set interfaces ethernet eth1 vif 1746 ip ospf cost '1'
set interfaces ethernet eth1 vif 1746 ip ospf dead-interval '40'
set interfaces ethernet eth1 vif 1746 ip ospf hello-interval '10'
set interfaces ethernet eth1 vif 1746 ip ospf priority '1'
set interfaces ethernet eth1 vif 1746 ip ospf retransmit-interval '5'
set interfaces ethernet eth1 vif 1746 ip ospf transmit-delay '1'
set interfaces ethernet eth1 vif 1746 mtu '1524'
set interfaces ethernet eth2 duplex 'auto'
set interfaces ethernet eth2 hw-id '00:50:56:a7:35:ae'
set interfaces ethernet eth2 smp_affinity 'auto'
set interfaces ethernet eth2 speed 'auto'
set interfaces loopback lo address '172.18.255.62/32'
set protocols ospf area 0.0.0.0 network '172.18.0.0/16'
set protocols ospf parameters abr-type 'cisco'
set protocols ospf parameters router-id '172.18.255.62'
set protocols ospf redistribute static metric '10'
set protocols ospf redistribute static metric-type '2'
set protocols static route 172.16.136.0/24 next-hop '172.18.41.16'
set protocols static route 172.18.254.76/31 next-hop '172.18.161.44'
set protocols static route 172.18.255.76/32 next-hop '172.18.161.44'
set protocols static route 172.18.255.77/32 next-hop '172.18.161.44'
set protocols static route 172.18.255.252/31 next-hop '172.18.161.44'
set protocols static route 172.24.0.120/29 next-hop '172.18.41.16'
set protocols static route 172.31.0.0/19 next-hop '172.18.161.108'
set protocols static route 192.168.223.64/28 next-hop '172.18.41.1'
set service ssh 'disable-host-validation'
set service ssh port '22'
set system config-management commit-revisions '20'
set system host-name 'o6-nav-test'
set system name-server '172.18.65.20'
set system name-server '172.18.65.30'
set system ntp server '0.pool.ntp.org'
set system ntp server '1.pool.ntp.org'
set system ntp server '2.pool.ntp.org'
set system package auto-sync '1'
set system package repository community components 'main'
set system package repository community distribution 'helium'
set system package repository community password ''
set system package repository community url 'http://packages.vyos.net/vyos'
set system package repository community username ''
set system syslog global facility all level 'notice'
set system syslog global facility protocols level 'debug'
set system time-zone 'Europe/Oslo'

Answers

c-po
Updated 2,254 Days Ago

/proc/sys/net/ipv4/igmp_max_memberships can easily be tweaked using /etc/sysctl.conf which is already adjusted for some other purposes IIRC.

New Answer