Networking Forums

Networking Forums > Computer Networking > Linux Networking > Full network level broadcast in Linux

Reply
Thread Tools Display Modes

Full network level broadcast in Linux

 
 
amesser39@hotmail.com
Guest
Posts: n/a

 
      11-08-2003, 12:47 AM
Hello all,

I am somewhat new to Linux networking. I have done a lot of
network programming on Windows. I am trying to do something that is
allowed on Windows but appears to not be allowed on Linux. I would
like to be able to do a full network broadcast (255.255.255.255) on a
simple Ethernet adapter.

When I try to do this I get a "network unreachable" error. I
even tried setting the adapter's broadcast address to 255.255.255.255,
but that is not allowed either. I can broadcast up to the level of the
adapter's broadcast address (i.e. 192.255.255.255).

am trying to help a friend with a problem. He has developed
an environment that works on Linux boxes. His customers are not
usually very tech savvy. They need to be able to hook up a WIndows
laptop (on a cross over cable) to the Linux boxes to configure them.
The problem is, is that the Linux box and the Windows box are, most
likely, configured for completely different networks. I told my friend
he could use UDP broadcasts to do what he wants. Problem is the Linux
boxes won't do it. I can do this with all embedded devices I have
developed and with Windows boxes, but not Linux.

If someone kind person out there can tell me how to do a full
network broadcast on a Linux box I would be very grateful.

TIA,
Adam Messer
(E-Mail Removed)

 
Reply With Quote
 
 
 
 
amesser39@hotmail.com
Guest
Posts: n/a

 
      11-10-2003, 03:51 PM
Hello All,

I discovered my own answer to the question. Just in case
anyone else out there has the same question, here is the answer. You
have to bind to the adapter you want to broadcast on. I have never had
to bind to send before, only to receive, but it makes sense. As long
as the broadcast level you are trying to use falls within the
adapter's set broadcast address, the protocol stack knows which
adapter to use. But, if you want to do a full (what Comer calls a
limited) network broadcast, the stack doesn't know where to send the
packet. So, binding to the appropriate adapter address is what does
the trick. Now, choosing the correct adapter can be another issue.
What I did was get the list of adapters with an ioctl() and choose the
first Ethernet adapter that was capable of broadcasting. In my case,
that will always work. In many more complex environments it may not. I
think you would have to have some outside information (i.e. know which
adapter they connected to) in order to bind properly.

Thanks again,
Adam



On Sat, 08 Nov 2003 01:47:18 GMT, (E-Mail Removed) wrote:

>Hello all,
>
> I am somewhat new to Linux networking. I have done a lot of
>network programming on Windows. I am trying to do something that is
>allowed on Windows but appears to not be allowed on Linux. I would
>like to be able to do a full network broadcast (255.255.255.255) on a
>simple Ethernet adapter.
>
> When I try to do this I get a "network unreachable" error. I
>even tried setting the adapter's broadcast address to 255.255.255.255,
>but that is not allowed either. I can broadcast up to the level of the
>adapter's broadcast address (i.e. 192.255.255.255).
>
> am trying to help a friend with a problem. He has developed
>an environment that works on Linux boxes. His customers are not
>usually very tech savvy. They need to be able to hook up a WIndows
>laptop (on a cross over cable) to the Linux boxes to configure them.
>The problem is, is that the Linux box and the Windows box are, most
>likely, configured for completely different networks. I told my friend
>he could use UDP broadcasts to do what he wants. Problem is the Linux
>boxes won't do it. I can do this with all embedded devices I have
>developed and with Windows boxes, but not Linux.
>
> If someone kind person out there can tell me how to do a full
>network broadcast on a Linux box I would be very grateful.
>
>TIA,
>Adam Messer
>(E-Mail Removed)


 
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Broadcast address / changing subnet mask to full class C help need kentiler Windows Networking 1 02-11-2009 08:09 PM
linux networking at kernel level 84.le0n@gmail.com Linux Networking 1 11-16-2008 11:27 AM
network actual bitrate (application level, tcp packet level) nirnimesh@gmail.com Linux Networking 1 01-24-2005 11:24 PM
Firewalling at the domain users level instead of network level Santos Linux Networking 1 07-18-2004 02:16 PM
Accessing second level network via linksys router and linux box Dave Linux Networking 1 09-14-2003 02:31 AM



1 2 3 4 5 6 7 8 9 10 11