Re: Wake on Lan with Java
- From: Nigel Wade <nmw@xxxxxxxxxxxx>
- Date: Fri, 04 Jan 2008 16:54:23 +0000
christopher_board@xxxxxxxxxxx wrote:
Hi all, thanks for the replies.
Would the subnet mask be the broadcast address. If not how would I
find it out.
I have put the subnet mask into the program but it is now coming up
with an error which says:
java.net.BindException: Cannot assign requested address: Datagram send
failed
No, the broadcast address is the network address plus a "host" of all 1's,
almost the inverse of the netmask. From your posts it isn't clear what your
network is, you are using the the 10.0.0.0 class A private network but you
don't say whether you've subnet it.
10.0.0.0 would have a default netmask of 255.0.0.0, but is typically subnet to a
class C network with netmask 255.255.255.0. In your case I presume you have the
class C subnet 10.11.12.0 with netmask 255.255.255.0, in which case the
broadcast address is 10.11.12.255. In general, for any IP subnet, the part of
the address representing the host (i.e. the part the netmask masks) can only
have N-2 hosts because "host" 0 is the network address and host N-1 (all 1
bits) is the broadcast address.
--
Nigel Wade, System Administrator, Space Plasma Physics Group,
University of Leicester, Leicester, LE1 7RH, UK
E-mail : nmw@xxxxxxxxxxxx
Phone : +44 (0)116 2523548, Fax : +44 (0)116 2523555
.
- References:
- Wake on Lan with Java
- From: christopher_board
- Re: Wake on Lan with Java
- From: Roedy Green
- Re: Wake on Lan with Java
- From: christopher_board
- Re: Wake on Lan with Java
- From: Nigel Wade
- Re: Wake on Lan with Java
- From: christopher_board
- Wake on Lan with Java
- Prev by Date: Re: Wake on Lan with Java
- Next by Date: Re: compareTo question
- Previous by thread: Re: Wake on Lan with Java
- Next by thread: compareTo question
- Index(es):
Relevant Pages
|
|