Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IP_MULTICAST_IF fails #990

Closed
ericeil opened this issue Aug 25, 2016 · 11 comments
Closed

IP_MULTICAST_IF fails #990

ericeil opened this issue Aug 25, 2016 · 11 comments

Comments

@ericeil
Copy link

ericeil commented Aug 25, 2016

On rs_preview build 14905:

The following works on Linux, but fails in WSL:

#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <err.h>
#include <errno.h>
#include <stdio.h>

int main(void)
{
    printf("Creating socket\n");
    int s = socket(AF_INET, SOCK_DGRAM, 0);
    if (s < 0)
        err(1, "%d", errno);

    ip_mreqn opt = { .imr_multiaddr = { .s_addr = 0 },
                     .imr_address = { .s_addr = 0 },
                     .imr_ifindex = 0 };

    if (setsockopt(s, IPPROTO_IP, IP_MULTICAST_IF, &opt, sizeof(opt)) != 0)
        err(1, "%d", errno);

    printf("Success!\n");
    return 0;
}

.NET Core has support for setting the multicast interface by either address or interface index, so this impacts .NET Core functionality.

@sunilmut
Copy link
Member

Thanks @ericeil for reporting this. We already have a task tracking the work required for supporting 'IP_MULTICAST_IF'. We don't have an ETA at the moment.

@ankitkk
Copy link

ankitkk commented Oct 6, 2016

I would like to bump this as well - running into exactly this issue running https://github.com/UltraMessaging

@fpqc
Copy link

fpqc commented Oct 6, 2016

@ankitkk Don't worry, @ericeil is a Microsoft developer who is developing .net core. This is probably already a priority.

@makpac
Copy link

makpac commented Feb 12, 2017

@sunilmut Is there anything new about this one. Thanks for the hard work.

@sunilmut
Copy link
Member

sunilmut commented Mar 1, 2017

@makpac - Apologize for the delayed response.

Is there anything new about this one.

No, not yet. It's in the pending list. Just curious, is this blocking any scenario for you?

@makpac
Copy link

makpac commented Mar 2, 2017

@sunilmut, I tried to install and run a server app which use multicast to talk to its clients and it sets IP_MULTICAST_IF as a socket option. It's not a blocking me as ended up installing it on a VM but being able to run the app on the same machine and without using VMs would be super cool. :)

@sunilmut
Copy link
Member

Just an update that support for IP_MULTICAST_IF and IPV6_MULTICAST_IF has been checked in the dev branch and should soon make it to the release branch.

@ghost
Copy link

ghost commented Apr 11, 2017

Hello All,
I am unable to enable multicast when running ifconfig eth2 multicast on insider preview build 16170.
@sunilmut, when you say it has been checked in the dev branch, do you refer to this branch or one that has not been released yet ?
Thank you.

@sunilmut
Copy link
Member

@bbidault2 - Yes. If you keep an eye out on our release notes, we usually publish what's available in an Insider build. We are a bit slow in getting the release notes out for this release, will have it out soon. Apologize for the delay.

Regarding the support for 'IP_MULTICAST_IF', it should come out soon.

Thanks for trying WSL!

@sunilmut
Copy link
Member

Here is the release note for build 16170. Thanks @jackchammons

@sunilmut
Copy link
Member

This should be fixed in Insider build 16176.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants