Skip to content

SocketException running on AspNet Core on Linux #83

Description

@tessarolli

This code works fine on windows, but throws this error on linux.

I'm suspecting I might be missing some .deb's on the linux box, but not sure how to find out which..

Can you help me?

Thanks

Exception:
Unhandled Exception: System.Net.Sockets.SocketException: Protocol not available
at System.Net.Sockets.Socket.UpdateStatusAfterSocketErrorAndThrowException(SocketError error, String callerName)
at System.Net.Sockets.Socket.SetSocketOption(SocketOptionLevel optionLevel, SocketOptionName optionName, Int32 optionValue, Boolean silent)
at System.Net.Sockets.Socket.SetSocketOption(SocketOptionLevel optionLevel, SocketOptionName optionName, Int32 optionValue)
at Rssdp.SocketFactory.CreateUdpMulticastSocket(Int32 multicastTimeToLive, Int32 localPort)
at Rssdp.Infrastructure.SsdpCommunicationsServer.BeginListeningForBroadcasts()
at Rssdp.Infrastructure.SsdpDevicePublisherBase..ctor(ISsdpCommunicationsServer communicationsServer, String osName, String osVersion, ISsdpLogger log)
at TessarolliSolutions.Zeus.Program.Main(String[] args) in C:\VSTS\TS\src\Zeus API\Zeus\Program.cs:line 69

Code:
_Publisher = new SsdpDevicePublisher(new SsdpCommunicationsServer(new SocketFactory(HardwareInfo.GetIPAddress().ToString())));
_Publisher.StandardsMode = SsdpStandardsMode.Relaxed;
_Publisher.AddDevice(PublishDevice());

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions