A multicast socket is a bi-directional communications endpoint used for the sending of packets to multiple receivers via multicast (typically IP) or for receiving multicast packets.
Questions tagged [multicastsocket]
156 questions
2
votes
1 answer
MulticastSocket.receive() hangs when I try to receive packets from a server on a network with an IP that is not 192.168.X.X
I'm having this issue on my Windows 7 machine where a call to MulticastSocket.receive() in Java will hang indefinitely (it never receives the packets) when I try to listen in on a server connected to a non-192.168.X.X network. Provided that the…

Justin
- 742
- 5
- 17
- 34
2
votes
1 answer
seems that my receive method does't get packet on multicast socket in java
I have a problem with receive method while using multicast socket in java. there are some hosts that they want to have a group chat using multicast socket.two threads (Read & Write) are started on each host, and both of them using multicast socket…

Farzane
- 173
- 1
- 8
2
votes
1 answer
ipv6 multicast reception
I'm unable to receive the multicast packets sent by the server. I could see the packets being received via tcpdump. Can anyone please let me know what am I doing wrong here.Thanks.
struct ipv6_mreq mreq;
struct sockaddr_in6 servaddr;
sock =…

foo_l
- 591
- 2
- 10
- 28
2
votes
0 answers
How to disable loopback in a Windows PGM socket?
I'm using the standard Windows PGM socket implementation (also known as the "MSMQ PGM"), with RDM socket type. I have noticed that, as per this Microsoft link, the MulticastLoopBack socket option cannot be set.
In other words, the rather familiar…

vanni.torelli
- 91
- 4
1
vote
1 answer
Java MulitcastSocket receive Method "Blocks a Program"?
I am writing a class in Java to simplify the process of connecting to, joining, sending, and receiving data from a multicast group. At this point, I am having trouble with the receive() method in Java's MulticastSocket class. Whenever I use this…

Oliver Spryn
- 16,871
- 33
- 101
- 195
1
vote
2 answers
Multicast loopback to sender socket
I am writing a C program which multicasts a packet. The same socket used for multicasting is subscribed to the multicast group on all interfaces. This would mean that the sender would receive is own packet back. I expect to the socket to receive the…

pransin
- 15
- 4
1
vote
0 answers
When doing a Java Multicast send/receive to a python server the receive gets the same data that was sent
I have a python3.7 server as follows:
#! /usr/bin/python3.7
MYPORT = 5000
MYGROUP_4 = '224.5.6.7'
MYTTL = 1 # Increase to reach other networks
import time
import struct
import socket
import sys
def main():
group = MYGROUP_4
…

AixNPanes
- 1,170
- 3
- 14
- 33
1
vote
1 answer
Socket option IP_MULTICAST_IF with static multicast route switches from multicast to unicast MAC addressing
I would like experts' advice on the usage of the socket option IP_MULTICAST_IF ("set multicast interface") combined with static multicast routes.
On a LAN, a multicast IP datagram is commonly sent in a multicast Ethernet frame (IP/MAC multicast…

Thierry Lelegard
- 423
- 2
- 11
1
vote
0 answers
Slow performance of multicast over loopback (WinSock)
I am porting an embedded distributed system to windows and I need to send multicast and unicast packets over loopback, I found out that for some unknown reason sending multicast takes 2x time than sending unicast.
My environment is quite simple, I…

PrzemekK
- 11
- 1
1
vote
2 answers
PHP multipoint loopback
I'm trying to implement simple application using PHP (unfortunately it must be in PHP) with sockets. I have one page - let's say multi.php and many instances of page client.php
I wan't to send some data to all instances of client.php from one…

Lukasz Spas
- 595
- 2
- 9
- 23
1
vote
0 answers
NetMQ Publish Subscribe with Microsoft Message Queue (MSMQ) Example
I have been trying to use NetMQ using IP Multicasting ("PGM"). I can successfully send and receive messages to/from the publisher and subscriber. However, I can't see that it is actually using MSMQ, which is installed along with its Multicasting…

Joel
- 103
- 4
1
vote
1 answer
Which method do you suggest for reading multicast stream in Linux?
I have written a program in Linux using C/C++ that reads multicast packets and tries to understand that a specific event occurred or not as quickly as possible. Latency is the key point here.
In the protocol, first two bytes represent the message…

xyzt
- 1,201
- 4
- 18
- 44
1
vote
2 answers
java NIO join to multicast channel on the default network interface
I am using java.nio.channels.DatagramChannel to send and receive UDP multicast messages. The box, my program is running on can have multiple network interfaces.
I can specify network interface manually using socket option for outgoing…

Sandro
- 2,707
- 2
- 20
- 30
1
vote
1 answer
Why is the time-to-live(ttl) packed using struct?
I stumbled upon some code in the book PyMOTW3 (https://pymotw.com/3/socket/multicast.html) and I could not understand why the time to live(ttl) argument was packed as struct.pack('b',1).
I tried searching the manuals to see if the arguments are…

DJay
- 25
- 1
- 5
1
vote
1 answer
How to set default HopLimit value for multicast in armLinux?
I'm trying to send packets via socket to multicast address. hopLimit by default == 1. I need hopLimit == 255 by default.
I can change hopLimit for all packets that was sent through this socket using IPV6_MULTICAST_HOPS setsockopt.
But I need…

YP_
- 13
- 4