-
Notifications
You must be signed in to change notification settings - Fork 16
can't connect management API #82
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
Comments
The unix socket that has been created does not appear to be in the expected location. This may be an issue with the way the openwrt build is being configured. You should be able to modify the examples to have a The openwrt build probably needs updating to use the correct expected environment |
thanks |
after add management port =xxx ,API connection is normal |
Defining a TCP management port is a reasonable workaround. I have found that the OpenWRT environment does not support the "/run" directory - which is unfortunate since that dir was standardized at least a decade ago. Once I have some time, I will update the OpenWRT build to avoid trying to use "/run" and instead use "/var/run" |
As of the recent merge, the n3nctl program now looks in both places for the management socket |
i run edge on x86 openwrt device , can't connect management api , pls help to check ,thanks
PID:
23422 nobody 676 S n3n-edge start tu3
ll /var/run/n3n/tu3/mgmt
srwxr-xr-x 1 nobody nogroup 0 Mar 19 18:47 /var/run/n3n/tu3/mgmt=
n3nctl -s tu3 -k n3n cmd get_edges
Could not find unix socket (is the session running?)
n3nctl -s tu3 supernodes
Could not find unix socket (is the session running?)
n3nctl -s tu3 edges
Could not find unix socket (is the session running?)
curl --unix-socket /run/n3n/tu3/mgmt http://x/help
curl: (7) Failed to connect to x port 80 after 0 ms: Error
curl --unix-socket /run/n3n/tu3/mgmt http://x/v1 -d '{"jsonrpc": "2.0", "method": "get_edges", "id": 1}'
curl: (7) Failed to connect to x port 80 after 0 ms: Error
curl --version
curl 8.6.0 (x86_64-openwrt-linux-gnu) libcurl/8.6.0 OpenSSL/3.0.13 nghttp2/1.51.0
Release-Date: 2024-01-31
Protocols: file ftp ftps http https ipfs ipns mqtt
Features: alt-svc HSTS HTTP2 HTTPS-proxy IPv6 Largefile SSL threadsafe UnixSockets
The text was updated successfully, but these errors were encountered: