[GH-ISSUE #354] Internal Error after requesting Cert: bind() to [::]:80 failed (13: Permission denied) #304

Closed
opened 2026-02-26 06:32:11 +03:00 by kerem · 15 comments
Owner

Originally created by @orangebutblue on GitHub (Apr 8, 2020).
Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/354

I've tested this on two separate machines on my network already. Once in Debian, once in Ubuntu. I used the normal NPM container (latest) and used the suggested ports (8080:8080, 8181:8181, 8443:8443)

I login, change the default password, create a new proxy-host and request a new certificate and hit save.

Then I get 'Internal Error'. According to the logs, the cert was successfully requested, NPM is trying to restart nginx - but fails with this error:

[nginx] starting...,
nginx: [emerg] bind() to [::]:80 failed (13: Permission denied)

Which is weird, because it's not supposed to be listening on 80 anyway. So now, NPM wont even start anymore.

Then I went to /docker/appdata/nginx-proxy-manager/nginx/proxy_host/1.conf and looked at the config which says:

    listen 8080;
listen [::]:80;

When I change that to listen [::]:8080; I can start it back up again. But when I go to 8181 and look at the proxy-hosts the newly created host is in the list, but the status is "unknown".
After edit it, and just resave it (without any changes), the status turns to "offline".

So, I thought maybe my port-forwarding is busted, which it isnt, because if I type in: sub.mydomain.com (which is the same proxy-host I defined in NPM) I get the default landing page:

"Congratulations!
You've successfully started the Nginx Proxy Manager."

So the port-forwarding is correct. But it wont work.

Originally created by @orangebutblue on GitHub (Apr 8, 2020). Original GitHub issue: https://github.com/NginxProxyManager/nginx-proxy-manager/issues/354 I've tested this on two separate machines on my network already. Once in Debian, once in Ubuntu. I used the normal NPM container (latest) and used the suggested ports (8080:8080, 8181:8181, 8443:8443) I login, change the default password, create a new proxy-host and request a new certificate and hit save. Then I get 'Internal Error'. According to the logs, the cert was successfully requested, NPM is trying to restart nginx - but fails with this error: ``` [nginx] starting..., nginx: [emerg] bind() to [::]:80 failed (13: Permission denied) ``` Which is weird, because it's not supposed to be listening on 80 anyway. So now, NPM wont even start anymore. Then I went to /docker/appdata/nginx-proxy-manager/nginx/proxy_host/1.conf and looked at the config which says: ``` listen 8080; listen [::]:80; ``` When I change that to listen [::]:8080; I can start it back up again. But when I go to 8181 and look at the proxy-hosts the newly created host is in the list, but the status is "unknown". After edit it, and just resave it (without any changes), the status turns to "offline". So, I thought maybe my port-forwarding is busted, which it isnt, because if I type in: sub.mydomain.com (which is the same proxy-host I defined in NPM) I get the default landing page: "Congratulations! You've successfully started the Nginx Proxy Manager." So the port-forwarding is correct. But it wont work.
kerem 2026-02-26 06:32:11 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@BenHall-1 commented on GitHub (Apr 8, 2020):

I'm also getting this error. Same situation.

<!-- gh-comment-id:610925822 --> @BenHall-1 commented on GitHub (Apr 8, 2020): I'm also getting this error. Same situation.
Author
Owner

@MikelillOi commented on GitHub (Apr 8, 2020):

Me too. In older versions it works very well

<!-- gh-comment-id:610934445 --> @MikelillOi commented on GitHub (Apr 8, 2020): Me too. In older versions it works very well
Author
Owner

@orangebutblue commented on GitHub (Apr 8, 2020):

Me too. In older versions it works very well

Which version works for you?

<!-- gh-comment-id:610948449 --> @orangebutblue commented on GitHub (Apr 8, 2020): > Me too. In older versions it works very well Which version works for you?
Author
Owner

@ndaringer commented on GitHub (Apr 8, 2020):

Rolling back did not fix it for me.

<!-- gh-comment-id:610951047 --> @ndaringer commented on GitHub (Apr 8, 2020): Rolling back did not fix it for me.
Author
Owner

@DanielPiccoli commented on GitHub (Apr 8, 2020):

shit, exactly the same in here...

<!-- gh-comment-id:610996942 --> @DanielPiccoli commented on GitHub (Apr 8, 2020): shit, exactly the same in here...
Author
Owner

@mdisieno commented on GitHub (Apr 8, 2020):

same here on the jlesage version as well.

<!-- gh-comment-id:611019529 --> @mdisieno commented on GitHub (Apr 8, 2020): same here on the jlesage version as well.
Author
Owner

@MikelillOi commented on GitHub (Apr 8, 2020):

v2.0.14 in docker is working for me but I created a new container

<!-- gh-comment-id:611056567 --> @MikelillOi commented on GitHub (Apr 8, 2020): v2.0.14 in docker is working for me but I created a new container
Author
Owner

@pr0xyfl00d3r commented on GitHub (Apr 8, 2020):

same issue for me

<!-- gh-comment-id:611092988 --> @pr0xyfl00d3r commented on GitHub (Apr 8, 2020): same issue for me
Author
Owner

@nightcomdev commented on GitHub (Apr 8, 2020):

suggested ports (8080:8080, 8181:8181, 8443:8443)

where is written that those are suggested ports? just wonder because when I was setting up container those ports are suggested:
ports: # Public HTTP Port: - '80:80' # Public HTTPS Port: - '443:443' # Admin Web Port: - '81:81'
those are ports suggested in Setup
https://nginxproxymanager.com/setup/

As for list of hosts I have same problem with newest container. List of domains is gone but proxy is working fine. Went back to 2.2.1 and working correct.

<!-- gh-comment-id:611148406 --> @nightcomdev commented on GitHub (Apr 8, 2020): > suggested ports (8080:8080, 8181:8181, 8443:8443) where is written that those are suggested ports? just wonder because when I was setting up container those ports are suggested: ` ports: # Public HTTP Port: - '80:80' # Public HTTPS Port: - '443:443' # Admin Web Port: - '81:81'` those are ports suggested in Setup [https://nginxproxymanager.com/setup/](https://nginxproxymanager.com/setup/) As for list of hosts I have same problem with newest container. List of domains is gone but proxy is working fine. Went back to 2.2.1 and working correct.
Author
Owner

@mdisieno commented on GitHub (Apr 8, 2020):

rolled back to 2.2.1 on jlesage, back to working. Seems to be a 2.2.2 bug.

<!-- gh-comment-id:611161607 --> @mdisieno commented on GitHub (Apr 8, 2020): rolled back to 2.2.1 on jlesage, back to working. Seems to be a 2.2.2 bug.
Author
Owner

@orangebutblue commented on GitHub (Apr 8, 2020):

suggested ports (8080:8080, 8181:8181, 8443:8443)

where is written that those are suggested ports? just wonder because when I was setting up container those ports are suggested:
ports: # Public HTTP Port: - '80:80' # Public HTTPS Port: - '443:443' # Admin Web Port: - '81:81'
those are ports suggested in Setup
https://nginxproxymanager.com/setup/

As for list of hosts I have same problem with newest container. List of domains is gone but proxy is working fine. Went back to 2.2.1 and working correct.

using the docker:
https://hub.docker.com/r/jlesage/nginx-proxy-manager

<!-- gh-comment-id:611175808 --> @orangebutblue commented on GitHub (Apr 8, 2020): > > suggested ports (8080:8080, 8181:8181, 8443:8443) > > where is written that those are suggested ports? just wonder because when I was setting up container those ports are suggested: > ` ports: # Public HTTP Port: - '80:80' # Public HTTPS Port: - '443:443' # Admin Web Port: - '81:81'` > those are ports suggested in Setup > https://nginxproxymanager.com/setup/ > > As for list of hosts I have same problem with newest container. List of domains is gone but proxy is working fine. Went back to 2.2.1 and working correct. using the docker: https://hub.docker.com/r/jlesage/nginx-proxy-manager
Author
Owner

@nightcomdev commented on GitHub (Apr 8, 2020):

but that's different repository I guess, author of this script have this repository
https://hub.docker.com/r/jc21/nginx-proxy-manager

<!-- gh-comment-id:611196605 --> @nightcomdev commented on GitHub (Apr 8, 2020): but that's different repository I guess, author of this script have this repository https://hub.docker.com/r/jc21/nginx-proxy-manager
Author
Owner

@jc21 commented on GitHub (Apr 8, 2020):

Correct. I am not supporting jlesage docker images.

I'm using v2.2.2 on Centos without any problems Docker version 19.03.8, build afacb8b. The errors about port permissions looks like it's a non-root user trying to open ports below 1024. Since docker runs as root and you have to run docker commands under a root umbrella, this doesn't make a lot of sense when docker is used in a standard setup (no idea about unraid, synology or other docker hosts).

<!-- gh-comment-id:611232661 --> @jc21 commented on GitHub (Apr 8, 2020): Correct. I am not supporting `jlesage` docker images. I'm using v2.2.2 on Centos without any problems `Docker version 19.03.8, build afacb8b`. The errors about port permissions looks like it's a non-root user trying to open ports below 1024. Since docker runs as root and you have to run docker commands under a root umbrella, this doesn't make a lot of sense when docker is used in a standard setup (no idea about unraid, synology or other docker hosts).
Author
Owner

@DanielPiccoli commented on GitHub (Apr 10, 2020):

running jlesage/nginx-proxy-manager:v1.7.0 working again now.

<!-- gh-comment-id:611823042 --> @DanielPiccoli commented on GitHub (Apr 10, 2020): running jlesage/nginx-proxy-manager:v1.7.0 working again now.
Author
Owner

@nightcomdev commented on GitHub (Apr 10, 2020):

I suggest to use docker from author, you are always can be sure it's safe and up to date.

<!-- gh-comment-id:612006476 --> @nightcomdev commented on GitHub (Apr 10, 2020): I suggest to use docker from author, you are always can be sure it's safe and up to date.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/nginx-proxy-manager-NginxProxyManager#304
No description provided.