Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I've read that OS sends broadcast packets via the 1st interface with IFF_BROADCAST and that you can set/clear this flag with ifconfig [-]broadcast (without an address). But this doesn't work.

In my case packets to are sent via the WAN interface and I want them to go to LAN. The WAN interface is pppoe and has a p-t-p, not broadcast address. The LAN interface has the default broadcast address, but changing it to has no effect.

What seems to work is: route add -host dev br-lan

Then I don't understand what the broadcast address of a network interface is for. Maybe to filter the received broadcast packets? I mean This line:

          inet addr:  Bcast:  Mask:
share|improve this question
Why do you want to do this? –  devicenull Dec 29 '13 at 1:58
Why aren't you sending to Maybe I'm misunderstanding, but you give the exact use case of having per-interface broadcast addresses, and then say you don't get what they're for. They're for doing what you are trying to do. –  Bandrami Dec 29 '13 at 21:44
@Bandrami it's not me, it's the router firmware configuring network –  basin Dec 30 '13 at 8:05
@Bandrami I don't send to, because the program wol sends to by default and I want it to work with default options –  basin Dec 30 '13 at 8:08
The "broadcast address" is only another way of saying "we have a 24bit netmask" so it has no relevance for interface selection. –  guntbert Jan 5 at 19:42

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.