Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

A host sends UDP broadcast, but its UDP packets are not received by any other hosts in the same subnet. However, its TCP traffic with others hosts are OK. I observed this using tcpdump.

Could it be related with the small buffer size? This host's maximum buffer size is just 131k. Its UDP traffic is pretty low.

share|improve this question
When you say "are not received", what does that mean? Do you mean a listening application doesn't receive them? Do you mean a raw packet dumping tool looking at the interface doesn't see them? Or something else? – David Schwartz Apr 11 '13 at 19:10
I believe there are special conditions for broadcasting to work properly. If you are in the subnet and you send a datagram packet to all other machines in the Network will receive it, but by default every packet that is not specifically addressed to your machine is dropped. Thats why you can't ping for instance, nobody will answer. I have no experience in this topic, but maybe when you bind() your socket to listen to a port you should set some flags or set the address to listen as – Havenard Apr 11 '13 at 20:13
Turn off the firewall momentarily and try again. Does the broadcast work? iptables often has separate entries for TCP and UDP traffic. – Stefan Lasiewski Apr 11 '13 at 20:22
@Stefan broadcast did not work. I will check the iptables. Thanks, – Max Fan Apr 17 '13 at 2:54

How many packets are lost? If it's only a few its worth remembering that UDP does not provide a guarantee of delivery, ordering or duplication protection. All error detection and correction will need to be done in the Application Layer.

If you're not receiving any packets at all you should look for an intermediary device or the hosts firewall that is filtering the packets out. Some less sophisticated IDS systems will interrupt bursts of UDP broadcast traffic as a Denial of Service attack.

share|improve this answer
It's the same subnet. I will check firewall. Thanks, – Max Fan Apr 17 '13 at 3:04
@MaxFan - Do you lose all the packets? Or just a few? – kce Apr 17 '13 at 16:09
all actually, at least to the ports I examined... – Max Fan Apr 17 '13 at 19:42
@MaxFan - It's probably a firewall then. – kce Apr 17 '13 at 21:10

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.