0

I have made a server that uses UDP multicast sockets.

I am able to run the server on my local host and try with as many clients as I want.

The problem is that i'm new to UDP and multicast and now I need to connect to another pc using the internet.

For example:

group = InetAddress.getByName(sendAdd);
buf = senddata.getBytes();
packet = new DatagramPacket(buf, buf.length, group, senderPort);

Is there anyway to host the UDP multicast server online? What InetAddress should I use in that case?

Cœur
  • 37,241
  • 25
  • 195
  • 267
chelo_c
  • 1,739
  • 3
  • 21
  • 34
  • Unlikely as with IPv4 multicast is optional and frequently disabled to prevent network storms. Of course it is used for various services such as video-on-demand and large scale conferences but strictly limited. – Steve-o Apr 25 '13 at 22:53
  • @Steve-o Strange attitude, isn't it. Multicast was invented to *reduce* network storms. You'd think they would disable UDP that *isn't* multicast, apart from the essential services of course. – user207421 Apr 25 '13 at 23:45
  • @EJP unfortunately multicast has no congestion control, it is a one way resource consumer. Hence many attempts at implementing a standard reliable multicast, e.g. [PGM](http://en.wikipedia.org/wiki/Pragmatic_General_Multicast). Do note that IPv6 mandates multicast by default and so may see better uptake. – Steve-o Apr 25 '13 at 23:51
  • Well can I at least host a UDP server without multicast binded to my machines real ip? – chelo_c Apr 26 '13 at 05:01

1 Answers1

0

The solution I found is that there is no way of hosting a multicast server online. Rather than simulating a local network using f.e "hamachi" or any other software.

chelo_c
  • 1,739
  • 3
  • 21
  • 34