• We value your experience with Plesk during 2024
    Plesk strives to perform even better in 2025. To help us improve further, please answer a few questions about your experience with Plesk Obsidian 2024.
    Please take this short survey:

    https://pt-research.typeform.com/to/AmZvSXkx
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Issue nginx configuration error after elevation

TurabG

Basic Pleskian
Server operating system version
Almalinux 8
Plesk version and microupdate number
18.0.62 #2
I elevated from Centos 7.9 to Almalinux 8 using the Plesk elevation script. Overall process was quite fine. I am just having one issue which shows up in Website Configuration Toubleshooter. It says:

Code:
nginx: [warn] conflicting server name "_" on 94.xx.xx.xx:443, ignored nginx: [warn] conflicting server name "lists.*" on 94.xx.xx.xx:443, ignored nginx: [warn] conflicting server name "" on 94.xx.xx.xx:80, ignored nginx: [emerg] bind() to 192.xx.xx.xx:443 failed (99: Cannot assign requested address) nginx: configuration file /etc/nginx/nginx.conf test failed

Here the IP which is 94.xx.xx.xx is the public IP of this VPS and 192.xx.xx.xx is the local IP. The server is behind a firewall (Endian). Repairing and rescanning rescanning IPs doesn't work. Here is what it looks like in IP configuration on Plesk:

Code:
IP Address                       Public IP     Interface   Type
192.xx.xx.xx / 255.255.255.0    94.xx.xx.xx    ens160    shared
 
Code:
docker0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        inet 172.17.0.1  netmask 255.255.0.0  broadcast 172.17.255.255
        ether 02:42:40:a7:73:94  txqueuelen 0  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

ens160: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.xx.xx  netmask 255.255.255.0  broadcast 192.168.xx.xx
        ether 00:xxxx:xx:xx:xx  txqueuelen 1000  (Ethernet)
        RX packets 41888649  bytes 10545242828 (9.8 GiB)
        RX errors 0  dropped 2470  overruns 0  frame 0
        TX packets 43824590  bytes 69352503796 (64.5 GiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 26157294  bytes 74164093507 (69.0 GiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 26157294  bytes 74164093507 (69.0 GiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
 
If the addresses are the same in the ifconfig output and the nginx configuration, there might be:
- an issue with SELinux. You can disable it by using the command `setenforce 0`.
- another service already using this port on the interface
 
Yes they are the same local IP which shows up in Plesk panel and ifconfig output. But what port do you mean which another service could be using? 443? No, not possible, sites are working. As you know, Plesk has both Apache and nginx simultaneously and nginx is used as a proxy. Since the websites are working, I am pretty sure port 443 is not used by anything other than the http servers.
 
Well yes but this implies it always runs on default config. I can't make any changes. When I run nginx command on shell, it says:

Code:
nginx: [emerg] bind() to 192.168.xx.xx:443 failed (98: Address already in use)

When I check status of the running process:
Code:
systemctl status nginx
... .. ..
 nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
 nginx: configuration file /etc/nginx/nginx.conf test is successful
... .. ..

But as you saw from the error code above, it says:
Code:
nginx: configuration file /etc/nginx/nginx.conf test failed

I believe there is nothing wrong with nginx but the problem is with how Plesk manages 2 http servers concurrently. There has to be a misconfiguration somewhere (which emerged after elevation from Centos to AlmaLinux).
 
Back
Top