this post was submitted on 26 Feb 2025
43 points (90.6% liked)

Selfhosted

43028 readers
364 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 2 years ago
MODERATORS
 

Hello, I've been messing around with prosody and snikket and that means I've been messing around with nginx. I was having some issues so I decided to uninstall nginx and after anothet round of messing around with snikket, decided to install nginx again. It showed this error and I don't really know what to do, since I'm really not that good with self-hosting yet. Please help. I will give more info as needed.

top 9 comments
sorted by: hot top controversial new old
[–] [email protected] 37 points 3 days ago (2 children)

Only one program can listen on a port at a given time usually. Something's listening on port 443 (the standard HTTPS port), and when nginx starts up it tries to listen on that port and can't. You can figure out what's already listening on that port with commands like lsof or netstat, see here for examples:

https://superuser.com/questions/42843/finding-the-process-that-is-using-a-certain-port-in-linux

[–] [email protected] 20 points 3 days ago

Thanks! Turns out nginx proxy manager was using 443. Changed the port and now nginx throws no errors!

[–] [email protected] 8 points 3 days ago (2 children)

Just to clarify, you can attach one listener per IP and port tuple. This means you can have separate processes listening on, for example, 127.0.0.1:80 and 192.168.0.1:80.

[–] [email protected] 3 points 3 days ago

And ports are per-protocol. Some DNS servers use TCP 53 and UDP 53, for example.

[–] somethingsomethingidk 1 points 2 days ago (1 children)

That's really interesting. What about 0.0.0.0? Does it resolve to localhost or the "public" ip?

[–] CriticalMiss 4 points 2 days ago

0.0.0.0 means listen on all IPs

[–] [email protected] 8 points 3 days ago (1 children)

your running something on port 443 already, if its nginx thats still running kill it. If not, then found out what is running on port 443 and kill it use ss -nlp to find the process name

[–] [email protected] 4 points 3 days ago

Run it with sudo in case you don't see the process name with the above command.

sudo ss -patln | grep 443

[–] Cyberflunk -1 points 2 days ago