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

Websocket binds to wrong IP address #3500

Open
galzol72 opened this issue Jan 3, 2025 · 2 comments
Open

Websocket binds to wrong IP address #3500

galzol72 opened this issue Jan 3, 2025 · 2 comments
Labels
legacy Related to Janus 0.x please-test

Comments

@galzol72
Copy link

galzol72 commented Jan 3, 2025

Websocket binds to wrong IP address

What version of Janus is this happening on?
0.15.0 1b40420

Was this working before?
Yes. On our other servers running version 0.15.0, it works normally.

We run several Janus servers (Ubuntu 20.04.6), each equipped with a single network card and assigned two IP addresses (the server in question uses a.b.c.222 and a.b.c.223).

The server is accessed at a.b.c.222 via https on port 8443, with signaling handled via WebSocket on port 443.

In janus.jcfg
interface=“a.b.c.222”

In janus.transport.http.jcfg
http=false
https=true
secure_port=8443
secure_ip=“a.b.c.222”

In janus.transport.websocket.jcfg
ws=false
wss=true
wss_port=443
wss_ip=“a.b.c.222”

Everything was working fine, with wss binding to a.b.c.222

Now we have replaced the server with a new one running Ubuntu 24.04.1 maintaining the same configuration.
After startup, even though “a.b.c.222” is configured, wss binds to “a.b.c.223”. No other service is using port 443.
In netplan, a.b.c.222 is configured as the primary IP address, and a.b.c.223 is configured as the secondary IP address .

ip addr

<iframe src="https://pastebin.com/embed_iframe/04cg5tU4" style="border:none;width:100%"></iframe>

What’s interesting: if the IP addresses in the netplan configuration are listed in reverse order, with a.b.c.223 before a.b.c.222, wss binds to a.b.c.222.

ip addr

<iframe src="https://pastebin.com/embed_iframe/iNh3bS4r" style="border:none;width:100%"></iframe>

We use libwebsocket 4.3.3-1.1build3.

From the log (debug level=6):

<iframe src="https://pastebin.com/embed_iframe/X4wnTp4w" style="border:none;width:100%"></iframe>
@galzol72 galzol72 added the legacy Related to Janus 0.x label Jan 3, 2025
@galzol72 galzol72 changed the title [0.x] Websocket binds to wrong IP address Jan 3, 2025
@galzol72
Copy link
Author

galzol72 commented Jan 3, 2025

Sorry for the iframe-s

@atoppi
Copy link
Member

atoppi commented Jan 8, 2025

@galzol72 should be fixed by the commit above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
legacy Related to Janus 0.x please-test
Projects
None yet
Development

No branches or pull requests

2 participants