Linux下怎样添加组播

  1. Looks to me like multicast isn't enabled properly.  
  2.   
  3. First, check using "ifconfig -a" that multicast is enabled on your network interfaces.  
  4.   
  5. eth0 Link encap:Ethernet HWaddr 00:E0:81:51:41:39  
  6. inet addr:192.168.0.6 Bcast:192.168.255.255 Mask:255.255.0.0  
  7. UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1  
  8. RX packets:14003 errors:0 dropped:0 overruns:0 frame:0  
  9. TX packets:13294 errors:0 dropped:0 overruns:0 carrier:0  
  10. collisions:0 txqueuelen:1000  
  11. RX bytes:10695433 (10.1 Mb) TX bytes:1728797 (1.6 Mb)  
  12. Interrupt:16 Base address:0x3000 Memory:c2220000-c2240000  
  13.   
  14. lo Link encap:Local Loopback  
  15. inet addr:127.0.0.1 Mask:255.0.0.0  
  16. UP LOOPBACK RUNNING MTU:16436 Metric:1  
  17. RX packets:1398 errors:0 dropped:0 overruns:0 frame:0  
  18. TX packets:1398 errors:0 dropped:0 overruns:0 carrier:0  
  19. collisions:0 txqueuelen:0  
  20. RX bytes:174382 (170.2 Kb) TX bytes:174382 (170.2 Kb)  
  21.   
  22. Then, do "route -n" and make sure you have something like this line:  
  23.   
  24. 224.0.0.0 0.0.0.0 240.0.0.0 U 0 0 0 eth0  
  25.   
  26. If that's missing, you need to add a route. Su to root and do:  
  27.   
  28. route add -net 224.0.0.0 netmask 240.0.0.0 dev eth0  
  29.   
  30. Or similar, depending on what name your network device has.  

你可能感兴趣的:(Linux)