Important issue: server down after build ngnix

feerdispzoo

Verified User
Joined
Jan 17, 2022
Messages
189
Hello everyone,
I hope can available and help me resolve this issue. I try switch web server to apache_ngnix using custom build 2.0

I fallow to this guide:
Currently, using an Nginx and Apache reverse proxy with DirectAdmin requires php-fpm to be used. If this is currently not the case, alter php1_mode and php2_mode in the CustomBuild options.conf file to the value php_fpm

cd /usr/local/directadmin/custombuild
./build set webserver nginx_apache

./build update
./build nginx_apache
./build rewrite_confs

I get any issue with firewall, so I disable firewall and try build again. After this:

Service Unavailable​

The server is temporarily unable to service your request due to maintenance downtime or capacity problems. Please try again later.

I try again with this:
cd /usr/local/directadmin/custombuild
./build update
./build update_da
./build set webserver nginx_apache
./build nginx_apache
./build set php1_release 5.6
./build set php2_release 7.0
./build set php1_release 7.1
./build set php2_release 7.2
./build set php1_mode php-fpm
./build set php2_mode php-fpm
./build set php3_mode php-fpm
./build set php4_mode php-fpm
./build set mod_ruid2 no
./build php n

But still not resolve this issue. And currently all websites down. Can anyone help how to solve this?
 
Tip: I should not use php 5.6 as first php, because the first php is also used for the system.
You don't want to use an ancient EOL php version as system default normally.
 
@Richard G, thanks for your tip.

I checked configuration custom build, please see screen below looks like:

php.png



and now im not sure, should I set now also php3_relase to 7.3 and php4_relase to 7.4 ?

and the second before on apache ioncube loader working correct. Now after switch to apache_ngnix and rebuild php ioncube not working. I build again and check php -v
phpv.png


looks like is enabled, but when I try open softaculous then I get:
Site error: the ionCube PHP Loader needs to be installed. This is a widely used PHP extension for running ionCube protected PHP code, website security and malware blocking. Please visit get-loader.ioncube.com for install assistance.


I think softaculous try use other php version, which ioncube loader is not enabled, but Im not sure how to check correct and install also for correct php version.
 
I would set the first php version to php 7.4 and then the rest to what you want.
You can also leave it like this if you want, but in that case you only have php 7.1 and 7.2 which in fact are also EOL currently.

As for the ioncube loader that's normal. You have to install ioncube for the PHP version your using by default.
You first used PHP 5.6 as first php version, so Softaculous is build for that. You need to reinstall Softaculous for it to work with php 7.1

However. If you don't need old php version I would suggest using php 7.4 as first php version.
And then whatever you want as second version, or just leave it at this version if you don't know yet. Because you can always install at a later time.

Anyway, if you change your first php you might have to re-install Softaculous again when you get the ionCube errors again.
 
Here is how to reinstall Softaculous:

If yours is a totally new installation, you can just use this command:
./install.sh --reinstall
from where you installed first. No need for the rest.
 
Back
Top