Messages in this thread | ![/](/images/icornerl.gif) | | Date | Mon, 3 Mar 2003 15:39:37 +0100 | Subject | Re: IGMP problem with 2.5 kernels | From | Niels den Otter <> |
| |
Richard,
On Monday, 3 March 2003, Richard B. Johnson wrote: > Did you try to use bind() to bind your socket to a specific interface? > Using `route` to obtain side-effects is not the correct way. The > application needs to bind the socket to a specific interface if the > applications requires a specific interface (which you seem to > require). Otherwise, the first interface found will be used as the > default. If you can't rebuild the programs, you might work- around the > problem by modifying start-up so that your ethernet interfaces are > started before loop-back. > > You can expriment without rebooting... > > Remove all routing entries first. > route del -default xxx > route del -net xxx, etc. > > `ifconfig eth0 down` > `ifconfig lo down` > > Completely reconfigure eth0 first.... > Then configure lo. > > If you don't remove all the routing entries first, you don't really > end up with a new configuration. Something 'remembers' and the order > of entries doesn't get changed.
I have tried both your method and also booting Linux without any interfaces enabled, then enable eth0 and after that also lo.
When only eth0 was enabled, I got the following error from sdr: pangsit:~> sdr setsockopt - IP_ADD_MEMBERSHIP: No such device setsockopt - IP_ADD_MEMBERSHIP: No such device sd_listen: setsockopt IP_ADD_MEMBRSHIP err, addr: 224.2.127.254
I can send strace if this helps.
This is the same problem I see with other multicast applications. It really doesn't want to bind to the ethernet interface. pangsit:~> ifconfig eth0 eth0 Link encap:Ethernet HWaddr 00:08:74:22:48:CF inet addr:192.87.109.130 Bcast:192.87.109.255 Mask:255.255.255.0 inet6 addr: 2001:610:508:109:208:74ff:fe22:48cf/64 Scope:Global inet6 addr: fe80::208:74ff:fe22:48cf/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:32863 errors:0 dropped:0 overruns:1 frame:0 TX packets:150 errors:0 dropped:0 overruns:0 carrier:1 collisions:0 txqueuelen:100 RX bytes:16213097 (15.4 MiB) TX bytes:16428 (16.0 KiB) Interrupt:11 Base address:0xec80
After bringing up the loopback interface again the applications binds to this interface.
-- Niels - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| ![\](/images/icornerr.gif) |