Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
After a lot of hours of tests and the great help from Mara (thanks again Mara), I came to the conclusion that Linux (at least for the two systems I tested) only accepts UDP broadcast packets sent to these addresses:
I have several machines broadcasting UDP messages to different addresses: 255.255.255.255, 192.168.1.255 and 192.255.255.255. My linux box has these network settings:
With this config, this machine drops every packet addressed to 192.255.255.255. On the other hand, if I change the broadcast address to 192.255.255.255, then the machine drops broadcasted packets to 192.168.1.255. 255.255.255.255 is the only broadcast address really valid for any config.
Is there any way of accepting any kind of broadcast? Windows XP doesn't have this limitation AFAIK. Why is linux supposed to work in this way?
That seems like the proper way to do it to me - why would you want to broadcast to a broadcast address outside your network?
Just because Windows does it doesn't mean it's correct in anyway, shape, nor form :P
I agree with you but many applications broadcast UDP packets to other addresses than the one calculated by the local machine. In theory, a message broadcasted to 10.255.255.255 should be received by any machine within the 10.x.x.x network. Am I wrong?
The 255.255.255.255 address is an exception though. Any packet broadcasted to this address is correctly accepted by any machine, independently of the local broadcast parameter.
The broadcasts to outside "your" broadcast address will NOT be routed to the other networks.
The only situation I see this working would be when you have multiple IP ranges on the same physical network segment. For Example, 5 computers in the 10.10.10.0/8 range and 5 computers in the 192.168.0.0/24 range, but all 10 computers connected to the same switch.
A friend is telling me that his Fedora machines (with boradcast=10.20.1.255) see udp packets broadcasted to either 10.20.1.255 and 10.255.255.255. He says that this is not a *nix limitation in his opinion.
Sorry, this issue has nothing to do with the application definitely. Ethereal reads all packets, even those not addresses to my machine, so forget my precedent post.
FYI, the same application is running fine (does see any packet sent to any broadcast address) on my friend's computer (FC4).
Why are Ubuntu and FC4/5 treating broadcasted packets differently? Don't they share the same tcp/ip stack? Could my machine be filtering the incoming traffic in some way?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.