Your web hosting partners since 2004.
Buy now »

How to upgrade cPanel on CentOS 7 OpenVZ to AlmaLinux 8

Upgrading cPanel on CentOS 7 OpenVZ to AlmaLinux 8: A Detailed Guide

Introduction: Upgrading your cPanel installation from CentOS 7 to AlmaLinux 8 is a crucial step to ensure optimal performance, security, and access to the latest features. This guide will take you through the steps needed for a seamless migration.

Prerequisites:

  1. Backup: Before initiating any major upgrade, create a full backup of your cPanel server, including all accounts, configurations, and databases.
  2. Check cPanel Compatibility: Confirm that your cPanel version is compatible with AlmaLinux 8. Refer to cPanel documentation for compatibility details.

Update System

Ensure your system is updated to the latest version:

sudo yum update -y
sudo reboot

Check cPanel Version

Note: You must have cPanel version 102 or greater installed.

/usr/local/cpanel/cpanel -V

Upgrade cPanel

Ensure cPanel is updated to the latest version:

/scripts/upcp

Install Elevate cPanel Script

You can download a copy of the script to run on your cPanel server via:

wget -O /scripts/elevate-cpanel \
    https://raw.githubusercontent.com/cpanel/elevate/release/elevate-cpanel ;
chmod 700 /scripts/elevate-cpanel

It is recommended to check for known blockers before you upgrade. The check is designed to not make any changes to your system.

You can check if your system is ready to upgrade to AlmaLinux 8 by running:

# Check AlmaLinux 8 upgrade (dry run mode)
/scripts/elevate-cpanel --check --upgrade-to=almalinux

Note: If you're running from an OpenVZ container you'll get a message like this:

[WARN] *** Elevation Blocker detected: ***
  cPanel thinks that this is a container-like environment.
  This cannot be upgraded by the native leapp tool.
  Consider contacting your hypervisor provider for alternative solutions.

To convert the contain from CentOS 7, CentOS 8, VzLinux 7, and VzLinux 8 to AlmaLinux 8, you can use the almaconvert8 command.

almaconvert8 is a utility provided by the AlmaLinux team to assist with the conversion from CentOS to AlmaLinux. It's particularly useful for systems running CentOS 7 that you want to convert to AlmaLinux 8. However, it's important to note that this tool may not be fully tested and supported in all environments, so caution is advised.

Install AlmaConvert 8:

yum install vzdeploy8

If that doesn't work, try this:

# rpm -Uvh https://repo.virtuozzo.com/vzlinux/7/x86_64/os/Packages/v/vzdeploy8-1.0.61-9.vl7.noarch.rpm
Retrieving https://repo.virtuozzo.com/vzlinux/7/x86_64/os/Packages/v/vzdeploy8-1.0.61-9.vl7.noarch.rpm
Preparing...                          ################################# [100%]
Updating / installing...
   1:vzdeploy8-1.0.61-9.vl7           ################################# [ 50%]

# almaconvert8 --help
usage: almaconvert8 [-h] {list,list-cpanel,convert} ...

AlmaLinux Converter

positional arguments:
  {list,list-cpanel,convert}
    list                List convertible CentOS 7 / CentOS 8 / VzLinux 8 /
                        Rocky 8 containers
    list-cpanel         List convertible CentOS 7 with CPanel installed
    convert             Convert the specified containers to AlmaLinux 8

optional arguments:
  -h, --help            show this help message and exit

List Available Containers

Use the almaconvert8 list-cpanel command to list all the cPanel-based containers available for converting. For example:

# almaconvert8 list-cpanel
101 (101)

Convert Container

Run the almaconvert8 convert command to convert a container from one operating system to AlmaLinux 8. For example, to convert the 101 container to AlmaLinux 8, use the following:

almaconvert8 convert 101

Note: While almaconvert8 is a convenient tool, it's always crucial to have a backup before making significant changes to your server.

Refer to the official AlmaLinux documentation and forums for any specific considerations or issues related to your environment and applications.

# almaconvert8 convert --help
usage: almaconvert8 convert [-h] [--dry-run] [-q] [-v] [--log LOG]
                            [--parallel [parallel]] [--elevate] [--strict]
                            CT [CT ...]

positional arguments:
  CT                    UUID, CTID, or name of the container to convert,
                        delimited by spaces

optional arguments:
  -h, --help            show this help message and exit
  --dry-run             Check that conversion is possible, do not actually
                        perform it
  -q, --quiet           Be quiet
  -v, --verbose         Be verbose
  --log LOG             Dump all messages to the specified log file. Detailed
                        messages for every container will be dumped to
                        separate files with the same prefix
  --parallel [parallel]
                        The number of concurrent conversions to perform
  --elevate             Call the elevate upgrade scripts and wait for them to
                        finish
  --strict              Treat some of the precheck warnings as errors that
                        block conversion
# almaconvert8 convert --dry-run 101
*******Running dry run conversion of container 101*******
101: Conversion aborted: Software unsupported by AlmaLinux 8 detected: cPanel
Please contact the software vendor and request AlmaLinux 8 support

Verify the Upgrade:

Check that your system is running AlmaLinux 8:

vzctl exec 101 cat /etc/redhat-release

Post-Upgrade Checks:

  • Check PHP Handlers.
  • Check Apache is working.
  • Ensure MySQL/MariaDB is working.
  • Verify cPanel functionality.
  • Check email, DNS, and other cPanel services.
  • Test hosted websites and applications.

Conclusion: Upgrading cPanel on your CentOS 7 OpenVZ container to AlmaLinux 8 is a critical step in maintaining a secure and well-performing hosting environment. By following this detailed guide, you ensure a smooth transition with minimal disruption to your cPanel services.

Note: Always refer to official cPanel and AlmaLinux documentation for the most accurate and up-to-date information during the upgrade process.

Also see

Last updated: 2023-12-01

« Go Back

Order now »

They have always been helpful and give a good service.