Bug 246629 - Multicast stack problem - MRT_ADD_VIF Address already in use
Summary: Multicast stack problem - MRT_ADD_VIF Address already in use
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: 12.1-STABLE
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-net mailing list
URL:
Keywords: regression
Depends on:
Blocks:
 
Reported: 2020-05-21 11:35 UTC by Ozkan KIRIK
Modified: 2020-05-24 00:04 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ozkan KIRIK 2020-05-21 11:35:20 UTC
Hello, 


I'm using FreeBSD 12.1-STABLE. 

# uname -a
FreeBSD test.test.com 12.1-STABLE FreeBSD 12.1-STABLE #8 1f999e39f46(v2)-dirty: Wed Apr 22 08:40:36 +03 2020    test@test.test.com:/usr/obj/usr/src/amd64.amd64/sys/amd64

After restarting multicast routing daemon, daemon can't start with this error: "Failed adding VIF 1 (MRT_ADD_VIF) for iface em1: Address already in use". pimd tries to disable all vifs from kernel (shown in output below) but still throws the same error.

I tried with both mrouted and pimd. Both of them shows same behavior.
My opinion is kernel doesn't disable VIFs. 

I opened a bug report for netstat -g also ( bug #246626 ), I think there is 
corruption about the multicast stack in the kernel.

There is no problem on FreeBSD 11.2.

To reproduce error:
# pimd
# killall pimd
# pimd -d -s debug
debug level 0xffffffff (dvmrp_detail,dvmrp_prunes,dvmrp_routes,dvmrp_neighbors,dvmrp_timers,igmp_proto,igmp_timers,igmp_members,trace,timeout,packets,interfaces,kernel,cache,rsrr,pim_detail,pim_hello,pim_register,pim_join_prune,pim_bootstrap,pim_asserts,pim_cand_rp,pim_routes,pim_timers,pim_rpf)
11:52:23.035 pimd version 2.3.2 starting ...
11:52:23.035 Got 262144 byte send buffer size in 0 iterations
11:52:23.035 Got 262144 byte recv buffer size in 0 iterations
11:52:23.035 Got 262144 byte send buffer size in 0 iterations
11:52:23.035 Got 262144 byte recv buffer size in 0 iterations
11:52:23.035 Getting vifs from kernel
11:52:23.035 Installing em0 (10.2.4.20 on subnet 10.2.4/24) as vif #0 - rate 0
11:52:23.035 Installing em1 (192.168.58.1 on subnet 192.168.58) as vif #1 - rate 0
11:52:23.035 Installing em2 (192.168.59.1 on subnet 192.168.59) as vif #2 - rate 0
11:52:23.035 Installing em1.1600 (192.168.16.1 on subnet 192.168.16) as vif #3 - rate 0
11:52:23.035 Installing em1.1700 (192.168.17.1 on subnet 192.168.17) as vif #4 - rate 0
11:52:23.035 Disabling all vifs from kernel
11:52:23.035 Getting vifs from /usr/local/etc//pimd.conf
11:52:23.035 Local Cand-BSR address 192.168.59.1, priority 5
11:52:23.035 Local Cand-RP address 192.168.59.1, priority 20, interval 30 sec
11:52:23.035 spt-threshold packets 0 interval 100
11:52:23.035 Local static RP: 169.254.0.1, group 232.0.0.0/8
11:52:23.035 IGMP query interval  : 12 sec
11:52:23.035 IGMP querier timeout : 41 sec
11:52:23.035 **Failed adding VIF 1 (MRT_ADD_VIF) for iface em1: Address already in use**
Comment 1 Ozkan KIRIK 2020-05-23 06:43:23 UTC
There is no problem FreeBSD 12.1-p5

Latest SVN base/stable/12 kernel produces this problem.
Comment 2 Ozkan KIRIK 2020-05-23 11:58:10 UTC
Problem started after this commit: 
https://svnweb.freebsd.org/base?view=revision&revision=356621
Comment 3 Mark Linimon freebsd_committer freebsd_triage 2020-05-24 00:04:46 UTC
Notify committer of r356621.