# How to disable multicast and broadcast



## kurugda (Feb 24, 2010)

I need to disable multicast and broadcast on interface. 
`ifconfig ng0 -multicast`
Do not work!
Runing on freebsd 8.0


----------



## SirDice (Feb 24, 2010)

You really do not want to disable broadcasts, this will break pretty much everything. There's also no reason to block multicast.

So the question is, why?


----------



## kurugda (Feb 24, 2010)

My interface is 
`ifconfig -v ng0`


```
ng0: flags=88d1<UP,POINTOPOINT,RUNNING,NOARP,SIMPLEX,MULTICAST> metric 0 mtu 1460
	inet6 fe80::21c:c0ff:fe92:e93%ng0 prefixlen 64 scopeid 0x5
```
I need to disable multicast because our Internet provider brought link down when many multicast packets go.


----------



## kurugda (Feb 24, 2010)

broadcast  is disabled 
How to disable multicast ?


----------



## SirDice (Feb 24, 2010)

Find out where those multicasts are coming from. FreeBSD doesn't use it on it's own. So there must be some application that's generating them. Find that application and re-configure it.

Try to find the source of the problem instead of trying to remove the symptoms.


----------



## copypaiste (Feb 24, 2010)

Also you can use the packet filter to block unwanted traffic.


----------



## kurugda (Feb 24, 2010)

uTorrent generate that packets 
ok I'll make filter, if I can


----------



## SirDice (Feb 24, 2010)

kurugda said:
			
		

> uTorrent generate that packets


Bittorrent clients don't use broadcasts or multicast.


----------



## kurugda (Feb 27, 2010)

I do not why, but when I connect through freebsd server  and use rtorrent or utorrent, ISP always disconnect!
But when I use connection from windows no disconnection. I do not know why it is happening 
ISP do not like freebsd's packet's when using torrents, same problem on linux 

Is there any way to turn off multicast on interface?


----------



## copypaiste (Feb 28, 2010)

@kurugda, maybe you need to investigate what is the real reason of such behavior of your ISP. 
You may find out which traffic causes disconnections using tcpdump or wireshark, both in your win and bsd environments.
There's another point to think about - as far as I know there's a fixed limit on simultaneous tcp connections in windows systems (in WinXP at least), maybe you get disconnected from your ISP because of too much connections coming from your host? The theory looks plausible, because windows tries to limit the amount of sessions, and bsd/linux does not.

PS.: Oh, and of course there's a little probability of your own network equipment causing troubles. I.e. my own ADSL router sometimes causing sluggish network performance on a high load, especially it goes nuts when I run several torrent downloads which spawns many sessions.


----------



## trev (Mar 4, 2010)

kurugda said:
			
		

> I do not why, but when I connect through freebsd server  and use rtorrent or utorrent, ISP always disconnect!
> But when I use connection from windows no disconnection. I do not know why it is happening
> ISP do not like freebsd's packet's when using torrents, same problem on linux
> Is there any way to turn off multicast on interface?



I doubt it is your ISP disconnecting you. It is almost certainly your own modem/router that you use to connect to your ISP. Torrent programs often need careful configuration so that you do not exhaust your modem/router's NAT table memory space with too many concurrent connections. Some modem/routers also enable you to timeout connections faster than the default which helps avoid memory exhaustion.

Given that this is a very well known and common phenomenon for torrent software, I'm not sure why you think it's something to do with broadcast/multicast on your network interface.

As another poster mentioned, the give-away is the fact that Windows does not cause a disconnection because it throttles the number of concurrent connections by default.


----------



## oobayly (May 5, 2010)

I came across this thread while looking for a solution for my own question regarding ppp & IPv6 multicast routing: http://forums.freebsd.org/showthread.php?t=12802. So I thought I'd attempt to disable multicast on the ppp interface, however I had the same problem as kurugda as I was following Linux's ifconfig method of removing flags.

So, does anyone know how to do this, or is it simply not possible. Whilst I'm sure the OP appreciated being told to investigate the cause of the issue rather than use a cludge to fix it, sometimes you need to attempt to use that cludge to determine whether you're on the right track.

If (in this instance) disabling multicast worked, the OP could then work on the source of the multicast packets, if not, then he knows the ISP is probably fobbing him off.

In short, it sometimes helps to tell the OP what he wants to know *as well* as telling him that he's probably looking in the wrong direction and providing your suggestions.


----------



## newland8x (Nov 20, 2015)

Hi Kurugda, how to disable broadcast and multicast?

Thank you.


----------



## max21 (Nov 20, 2015)

newland8x said:


> Hi Kurugda, how to disable broadcast and multicast?
> 
> Thank you.


Good question!  I like to see what and how it break too ...  Broadcast may be needed to stay connected, but  multicast may not be needed by all.


----------

