Open nomis52 opened 9 years ago
More info:
I can't reproduce the problem if I use ArtNetNode directly, it's only when it's used with olad. I can't reproduce the problem if I change the port to something other than 6454 I can't reproduce the problem with the ESPNet plugin.
I wonder if it's not the act of sending an ArtPoll or some other data.
Ok, I've made some progress. The problem only exists if the firewall is enabled. If I disable the firewall and then run olad netstat doesn't show the socket once olad terminates.
Very weird.
The linux command is netstat -n -A inet | grep 6454, but it sounds like you've isolated it to a Mac issue.
I'm slowly getting to the bottom of this:
It's caused by starting the HTTP thread. If you run with --nohttp the problem doesn't occur. Starting an mDNS thread also doesn't cause the problem.
Steps to repro:
netstat -f inet -n | grep 6454
confirm there is a listening socketI can't figure this out, I've posted on stack overflow: http://stackoverflow.com/questions/25586327/bizarre-firewall-related-socket-leak-on-mac-os-x
Hi @nomis52, Did you ever find a solution? I'm using libartnet in an openFrameworks project and seem to have the same issue on OSX 10.10.
Nope, it's very odd. I suspect it's a OS X kernel bug.
have you figured out a workaround?
Try disabling the OS X firewall.
Someone replied on the stack overflow thread
Just bumped into this as well, and posted some more findings as reply to the Stackoverflow issue linked to above. There seems to be no fix for this, hence you need to disable the firewall.
Thanks for replying here @zonque . @nomis52 did you raise a ticket with Apple at the time, if so they might appreciate @zonque 's simplified case to replicate it, although I wouldn't hold out much hope.
This is really weird, once olad exits, the Artnet UDP socket (6454) is still present. If you restart olad again it fails to receive ArtNet messages. You can see it show up with:
$ netstat -n -f inet | grep 6454 udp4 0 0 .6454 *.
The udp_server example doesn't have this issue, nor does the E1.31 socket on port 5568 doesn't have this problem so it's something specific to how we're using the ArtNet socket.