After some investigation and trial and error I'm left with the sense that 
multicast is not entirely implemented on plan9. Here's what I tried.

I tried setting up a udp announce directly against /net/udp for port 564. 
Before listening I sent an addmulti message as described in the ip manual page. 
According to /net/iproute there is a new route for my multicast address but it 
is not bound to any of my interfaces despite specifying the ip of my adapter in 
the addmulti. There doesn't seem to be a way to specify the interface 
number in the iproute protocol. My process waits but when another process on 
another machine sends on that multicast address it is not received.

I tried pinging 224.0.01 from another machine and my plan 9 box doesn't 
respond to the ping like other machines with multicast enabled.

Finally, after looking at the code in /sys/src/9/ip I find that while a queue 
of multicast IPmulti structs are assembled nothing at the Ethernet/ARP layer 
seems to register the multicast with the adapter so that it can receive packets.

Something else that's puzzling is that I can't seem to have multiple 
processes on the plan9 machine listening on the same udp port. On other OSes 
there are flags that can be set to allow reuse. I'm not seeing anything 
similar here.

I'm hoping that there's something that I'm missing. Has anyone else 
had success setting multicast servers up in any of the plan 9 variants? 
Otherwise, it would be a project to write the code for it. Perhaps ARP will 
suit my need better for detecting hosts on the same Ethernet switch.

Thanks,
Chris

Reply via email to