Configuring Linux to Support Multicast IP

Most Linux systems have multicast IP capability turned off by default. In order to use multicast sockets on my Linux system, I had to reconfigure and build my kernel, and then run the following command as root after re-booting:
route add -net 224.0.0.0 netmask 240.0.0.0 dev lo
Make sure that this route has been added by typing
route -e
You should see output like this:
markw@colossus:/home/markw > su
Password:
markw # route add -net 224.0.0.0 netmask 240.0.0.0 dev lo
colossus:/home/markw # route -e
Kernel IP routing table
Destination   Gateway   Genmask    Flags   MSS Windowirtt Iface
loopback      *         255.0.0.0  U      3584 0          0 lo
224.0.0.0     *         240.0.0.0  U      3584 0          0 lo
markw #
Please note that I ran the route commands as root. I don’t permanently add this route for multicasting to my Linux development system; rather, I manually add the route (as root) when I need to use multicast IP. Re-configuring and building the kernel is also fairly simple. On my Linux system, I use the following steps to configure and build a new kernel with multicast IP support:
1. cd /usr/src/linux
2. make menuconfig
select networking options
check the box labeled “enable multicast IP”
save and exit from menuconfig
3. make dep; make clean; make zImage
4. cp /vmlinux /vmlinux_good
5. cp arch/i386/boot/zImage /vmlinux
6. cd /etc
7. edit lilo.conf, adding a new entry for the /vmlinux_good kernel
8. lilo
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值