nginx down

Pouyar69

Verified User
Joined
Feb 2, 2019
Messages
10
Hi guys.
sorry for my poor English.
I had a problem updating exim by custombuild and by search I realized that my problem was because of OpenSSL version and updated OpenSSL to 1.1.1
after that exim is updated with no problem but all of my websites went down with the ERR_EMPTY_RESPONSE browser response.
and now I noticed that nginx is down in my server and cant start.
 
DirectAdmin relies on OS version of OpenSSL, and it does not change it system-wide to a custom version. I'd suggest removing that custom installation and everything should be fine then.
 
Hello,

Try the following

Code:
cd openssl-1.1.1/
make uninstall
ldconfig


to uninstall OpenSSL 1.1.1, then rebuild software with custombuild.
 
I uninstalled openssl and rebuilt software with custombuild but the problem exists yet.

my service nginx status output is:

Code:
Redirecting to /bin/systemctl status nginx.service
● nginx.service - The nginx HTTP and reverse proxy server
   Loaded: loaded (/etc/systemd/system/nginx.service; disabled; vendor preset: disabled)
   Active: failed (Result: exit-code) since Tue 2019-07-02 21:08:07 +0430; 23s ago
  Process: 32057 ExecStartPre=/usr/sbin/nginx -t -c /etc/nginx/nginx.conf (code=exited, status=203/EXEC)

Jul 02 21:08:07 srv.com systemd[1]: Starting The nginx HTTP and reverse proxy server...
Jul 02 21:08:07 srv.com systemd[32057]: Failed at step EXEC spawning /usr/sbin/nginx: No such file or directory
Jul 02 21:08:07 srv.com systemd[1]: nginx.service: control process exited, code=exited status=203
Jul 02 21:08:07 srv.com systemd[1]: Failed to start The nginx HTTP and reverse proxy server.
Jul 02 21:08:07 srv.com systemd[1]: Unit nginx.service entered failed state.
Jul 02 21:08:07 srv.com systemd[1]: nginx.service failed.

and journalctl -xe output is:

Code:
-- The result is failed.
Jul 02 21:12:06 srv.com systemd[1]: Unit nginx.service entered failed state.
Jul 02 21:12:06 srv.com systemd[1]: nginx.service failed.
Jul 02 21:12:06 srv.com systemd[1]: Reloading The PHP FastCGI Process Manager.
-- Subject: Unit php-fpm56.service has begun reloading its configuration
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit php-fpm56.service has begun reloading its configuration
Jul 02 21:12:06 srv.com systemd[1]: Reloaded The PHP FastCGI Process Manager.
-- Subject: Unit php-fpm56.service has finished reloading its configuration
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit php-fpm56.service has finished reloading its configuration
--
-- The result is done.
Jul 02 21:12:07 srv.com polkitd[2859]: Registered Authentication Agent for unix-process:32339:119511 (system bus name :1.111 [/usr/bin/pkttyagent --notify-fd 5 --fallback], object p
Jul 02 21:12:07 srv.com systemd[1]: Starting The nginx HTTP and reverse proxy server...
-- Subject: Unit nginx.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit nginx.service has begun starting up.
Jul 02 21:12:07 srv.com systemd[32355]: Failed at step EXEC spawning /usr/sbin/nginx: No such file or directory
-- Subject: Process /usr/sbin/nginx could not be executed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- The process /usr/sbin/nginx could not be executed and failed.
--
-- The error number returned by this process is 2.
Jul 02 21:12:07 srv.com systemd[1]: nginx.service: control process exited, code=exited status=203
Jul 02 21:12:07 srv.com systemd[1]: Failed to start The nginx HTTP and reverse proxy server.
-- Subject: Unit nginx.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit nginx.service has failed.
--
-- The result is failed.
Jul 02 21:12:07 srv.com systemd[1]: Unit nginx.service entered failed state.
Jul 02 21:12:07 srv.com systemd[1]: nginx.service failed.
Jul 02 21:12:07 srv.com polkitd[2859]: Unregistered Authentication Agent for unix-process:32339:119511 (system bus name :1.111, object path /org/freedesktop/PolicyKit1/Authenticatio
Jul 02 21:12:12 srv.com kernel: Firewall: *UDP_IN Blocked* IN=eth0 OUT= MAC=ff:ff:ff:ff:ff:ff:e4:5d:8c:d1:87:2d:08:00 SRC=5.61.x.x DST=255.255.255.255 LEN=158 TOS=0x00 PREC=0x00 TT
Jul 02 21:12:15 srv.com kernel: Firewall: *TCP_IN Blocked* IN=eth0 OUT= MAC=00:16:5g:8e:d4:45:e4:7g:8c:02:0f:c9:08:00 SRC=198.108.x.x DST=5.61.28.42 LEN=40 TOS=0x08 PREC=0x40 TTL
Jul 02 21:12:20 srv.com kernel: Firewall: *UDP_IN Blocked* IN=eth0 OUT= MAC=ff:ff:ff:ff:ff:ff:e8:8d:8c:02:0f:c9:04:00 SRC=5.61.x.x DST=255.255.255.255 LEN=163 TOS=0x00 PREC=0x00
Jul 02 21:12:24 srv.com kernel: Firewall: *UDP_IN Blocked* IN=eth0 OUT= MAC=ff:ff:ff:ff:ff:ff:00:0c:45:6e:1a:fc:05:00 SRC=185.73.x.x DST=255.255.255.255 LEN=139 TOS=0x00 PREC=0x00
Jul 02 21:12:25 srv.com kernel: Firewall: *UDP_IN Blocked* IN=eth0 OUT= MAC=ff:ff:ff:ff:ff:ff:00:50:42:a7:9e:4a:07:00 SRC=185.73.x.x DST=255.255.255.255 LEN=139 TOS=0x00 PREC=0x0
lines 2626-2674/2674 (END)
 
Failed at step EXEC spawning /usr/sbin/nginx: No such file or directory

Either nginx is not installed, or it is installed in not-supported location.

What are the final 10-20 lines when you run ./build nginx ?
 
Thnx zEitEr.

I use nginx_apache and last lines of ./build nginx_apache is:

Code:
checking whether to enable mod_slotmem_plain... no
checking whether to enable mod_ssl... checking dependencies
checking for OpenSSL... checking for user-provided OpenSSL base directory... /usr
  setting MOD_CFLAGS to " "
  setting ab_CFLAGS to " "
  setting MOD_LDFLAGS to " "
checking for OpenSSL version >= 0.9.8a... FAILED
configure: WARNING: OpenSSL version is too old
no
checking whether to enable mod_ssl... configure: error: mod_ssl has been requested but can not be built due to prerequisite failures

*** There was an error while trying to configure Apache 2. Check the configure/ap2/configure.apache file
 
Code:
yum install openssl openssl-devel -y || yum reinstall -y openssl openssl-devel
ldconfig

and try again to build.
 
after
yum install openssl openssl-devel -y || yum reinstall -y openssl openssl-devel
response is:
Code:
Package 1:openssl-1.0.2k-16.el7_6.1.x86_64 already installed and latest version
Package 1:openssl-devel-1.0.2k-16.el7_6.1.x86_64 already installed and latest version
Nothing to do

and nothing changed in build.

openssl version in yum info openssl is:openssl-1.0.2k but when we try to build nginx it says checking for OpenSSL version >= 0.9.8a... FAILED.
which one is correct?

what if I try to install openssl 1.02 or 1.1 by method I tried to install 1.1.1 :
https://www.osradar.com/how-to-install-the-latest-version-of-openssl-on-centos-7/
 
after
yum install openssl openssl-devel -y || yum reinstall -y openssl openssl-devel
response is:
Code:
Package 1:openssl-1.0.2k-16.el7_6.1.x86_64 already installed and latest version
Package 1:openssl-devel-1.0.2k-16.el7_6.1.x86_64 already installed and latest version
Nothing to do

and nothing changed in build.

openssl version in yum info openssl is:openssl-1.0.2k but when we try to build nginx it says checking for OpenSSL version >= 0.9.8a... FAILED.
which one is correct?

what if I try to install openssl 1.02 or 1.1 by method I tried to install 1.1.1 :
https://www.osradar.com/how-to-install-the-latest-version-of-openssl-on-centos-7/

Run just

yum reinstall -y openssl openssl-devel

and try again.
 
thank you very very much, Alex and nick-a.

problem with nginx has been solved by your guides.

but i have a new problem:
I cant access to my directadmin:
srv.xyz.com refused to connect.

and in my wordpress sites i have :

Code:
<?php
/**
 * Front to the WordPress application. This file doesn't do anything, but loads
 * wp-blog-header.php which does and tells WordPress to load the theme.
 *
 * @package WordPress
 */

/**
 * Tells WordPress to load the WordPress theme and output it.
 *
 * @var bool
 */
define( 'WP_USE_THEMES', true );

/** Loads the WordPress Environment and Template */
require( dirname( __FILE__ ) . '/wp-blog-header.php' );
 
Problem with Wordpress solved after ./build all d

But I can't access to DirectAdmin yet
 
thank you very very much, Alex and nick-a.

problem with nginx has been solved by your guides.

but i have a new problem:
I cant access to my directadmin:
srv.xyz.com refused to connect.

and in my wordpress sites i have :

Code:
<?php
/**
 * Front to the WordPress application. This file doesn't do anything, but loads
 * wp-blog-header.php which does and tells WordPress to load the theme.
 *
 * @package WordPress
 */

/**
 * Tells WordPress to load the WordPress theme and output it.
 *
 * @var bool
 */
define( 'WP_USE_THEMES', true );

/** Loads the WordPress Environment and Template */
require( dirname( __FILE__ ) . '/wp-blog-header.php' );

So that means Apache is running but PHP isn't, nor is directadmin.

What's the output of

Code:
/usr/local/directadmin/directadmin

and

Code:
/usr/sbin/httpd

Do you get any errors relating to openssl libraries?
 
I had changed the directadmin port from 2222 and it was returned to 2222, I changed it and updated the directadmin licence manually and problem solved.

thanks all of you and sorry for my poor English again.
 
Back
Top