WHM EasyApache 4 PHP missing

CloudLinux PHP versions missing in PHP Selector

On a Cpanel server running CloudLinux, PHP Selector did not show all PHP versions.

cloudlinux php selector

I reinstalled EasyApache profile “CloudLinux + All PHP Options + OpCache + mod_lsapi”.

WHM EasyApache 4  PHP missing

Even after installing EasyApache profile with all PHP versions, PHP 7.2 and PHP 7.4 was missing on this server.

To fix, the problem, i run

EasyEngine Renew SSL

To renew SSL for site hosted in EasyEngine, run

You can set a cronjob to run every month to auto renew the SSL certificates.

Alibaba Cloud DirectMail

AlibabaCloud DirectMail

Alibaba Cloud DirectMail

AlibabaCloud DirectMail is transactional email service from AlibabaCloud. It is like Amazon SES, MailGun, SendGrid etc…

They have 3 differnt mail server hostname depending on region. Unlike other SMTP providers, they allow email using port 80.

Note: Port 25 is currently disabled to maintain ECS security. If your sending application is deployed on Alibaba Cloud ECS, we recommend that you use port 80 when SSL is not checked, and use port 465 when SSL is checked. Besides, we support explict ssl/tls functionality on port 25 or 80 with “STARTTLS” smtp cmd.

rpm verify packages

To verify a package installed on system, you can use

Example

Here bind package have /etc/named.conf file modified.

To verify all packages on system, run

OpenLiteSpeed Change Admin Password

OpenLiteSpeed Binary Installation

You can download latest version of OpenLiteSpeed web server from

https://openlitespeed.org/downloads/

There are 2 download links for each version of OpenLiteSpeed, here we use the binary download. To install verison 1.6.9, run

To start/stop OpenLiteSpeed, use following commands

OpenLiteSpeed control panel available at

Default password for admin user is 123456.

MySQL

MySQL 8

MySQL 8 use caching_sha2_password as default autentication method. Many mysql clients still not support this method. If you need to use old method, you can set autentication plugin as mysql_native_password. You can also set this as default method by editing my.cnf file.

To change a user to use mysql_native_password, run

MySQL

Disable MySQL bin log on Bitnami

if you have cloud sevrer with less disk space, it is better disable MySQL bin log as it take approx 3 GB of disk space on bitnami server.

To disable MySQL binlog, edit mysql config file.

Find

Add below

Here is what i have in the my.cnf

Now restart MySQL

You can now remove the file starting with binlog from folder /opt/bitnami/mysql/data

python

error: Python.h: No such file or directory

When install dlib python module, i get error

This is because missing python3-dev package. To fix, install

If you are using python virtualenv, you will need to recreate the virtualenv after installing dev package.

Mac

To list all packages installed with brew

To see if a specific package installed, run

List open ports

Restart apache2

Disable Apache from starting on boot

Or

php programming

HTTP 301 Redirect using PHP

You can use PHP header() function to do redirect.

To do 301 redirect, use

For 302 redirect, use

If you need to redirect a site to new site keeping same URL structure, you can use