Socket error: connect, 0
Sardelka9515 opened this issue · comments
Hi. I'm new here.
I got these text printed on console when following the C# example, what am I missing?
And it just stuck there, can someone help me?
This is my code:
public static void NodeTest()
{
var networkId = 0x8056c2e21c000001;
var node = new ZeroTier.Core.Node();
node.Start(); // Network activity only begins after calling Start()
while (!node.Online)
{
Thread.Sleep(50);
}
Console.WriteLine("Id : " + node.IdString);
Console.WriteLine("Version : " + node.Version);
Console.WriteLine("PrimaryPort : " + node.PrimaryPort);
Console.WriteLine("SecondaryPort : " + node.SecondaryPort);
Console.WriteLine("TertiaryPort : " + node.TertiaryPort);
node.Join(networkId);
Console.WriteLine("Waiting for join to complete...");
while (node.Networks.Count == 0)
{
Thread.Sleep(50);
}
}
I'm using .NET 6, by the way.
What port numbers are you using? Do you have other instances of ZeroTier running on the machine or is there anything blocking traffic on the ports you're using?
Thanks for your response.
I didn't specify a port number at first.(says it would randomly attempt if not specified or 0?)
Then I tried InitSetPortRange(40000,50000), didn't work, either.
I previously had ZeroTier installed, but I tried again after uninstalling it, still the same. Could that be a probem?
I'm on a mobile network( 4G), wondering if that might be causing the issue? Although normal ZeroTier installation works perfectly.
When will this be resolved?