Updating PHP or Other Services with DirectAdmin Custombuild

You are currently viewing Updating PHP or Other Services with DirectAdmin Custombuild

If you are hosting your WordPress sites on an unmanaged VPS, you will most probably have to perform all system updates and upgrades yourself. So for that, you can use a control panel that DirectAdmin offers, which is a very handy tool that makes keeping your server packages updated without any hassle.

The tool is called DirectAdmin Custom build. This script package allows DirectAdmin users to install and upgrade services like Apache, PHP, and MySQL from a central place. Here’s a good introduction to DirectAdmin Custombuild.

DirectAdmin is a control panel just like the cPanel. But it is more of an affordable option so more & more hosting providers are using it nowadays. And for unmanaged VPS, Direct admin is my first choice. Moreover, with the DirectAdmin Custombuild feature, you can easily perform PHP updates & other services update. So, in this brief guide, I will talk about Updating PHP or other services with DirectAdmin Custombuild.

Moreover, I will also discuss PHP 8 DirectAdmin update & updating to custombuild 2.0. And as a bonus, I will overview & provide resources for WordPress DirectAdmin Install.

Load WordPress Sites in as fast as 37ms!

So without wasting any more of your time, let’s start this brief guide on Installing & performing DirectAdmin PHP update.

Note: Before making any changes to your server, don’t forget to backup your data. The process described below works for us, but your server might be totally different. Since this is not a procedure for newbies please learn more about what you´re doing before proceeding.

How to Install Custombuild

During the installation of DirectAdmin, you’ll be asked if you want to install Custombuild. If your unmanaged VPS came with DirectAdmin already running, chances are that Custombuild is already installed.

However, if for some reason it does not have custombuild. Here’s the recipe to install Custombuild 1.1 /1.2 or 2.0 from scratch:

cd /usr/local/directadmin
wget http://files.directadmin.com/services/custombuild/1.1/custombuild.tar.gz
tar xvzf custombuild.tar.gz
cd custombuild

To install version 1.2, simply change the version number to 1.2

Load WordPress Sites in as fast as 37ms!

When you’re done, you need to run this command for the first time:

./build all d

Updating to Custombuild 2.0

If you’re still running older versions of Custombuild,  it’s recommended that you should update to custombuild 2.0 to unlock features such as the DirectAdmin change PHP version for users from Domain set up. Moreover, it also allows you to run multiple PHP with DirectAdmin.

To perform DirectAdmin update for custombuild 2.0 you first need to find out what version of custom build are you running. For that, run the following commands:

 cd /usr/local/directadmin/custombuild
./build version

If you’re already running 2.0 which is embedded in all the latest Directadmin install, you don’t need to update it. However, if you’re running an older version, it’s recommended that you should install custom build 2.0 with default settings because it has different values than CB 1.2. So, first, execute the pre-installation commands, which can be found on this resource.

Load WordPress Sites in as fast as 37ms!

After that use run the following commands to update CB2. These commands are for updating CB2 with default options.

cd /usr/local/directadmin
mv custombuild custombuild_1.x
wget -O custombuild.tar.gz http://files.directadmin.com/services/custombuild/2.0/custombuild.tar.gz
tar xvzf custombuild.tar.gz
cd custombuild

This will create default options.conf, and if you want to keep using this specific one. Then you only need to add the following commands to use apache

./build apache
./build php n
./build rewrite_confs

Or use this to rebuild everything.

./build all d

How to configure Custombuild

Now that you have installed the correct version of custombuild, you now need to configure it before updating PHP version with DirectAdmin. You can specify the services and versions you wish to use in the options.conf file. All available options are listed here.

To see your current configuration, run this command:

./build options

The Ultimate Managed Hosting Platform

Interested in related articles? Here are some we think you’ll like: 10 Best Hosting Providers for Node.js in 2023, 6 Best Cloud Hosting for Startups in 2021.

How to update PHP or another service

After updating to the latest version of DirectAdmin Custombuild, now it’s time to let you know about Updating PHP or other services with DirectAdmin Custombuild

So, here are a the steps that you need to follow.

  1. cd /usr/local/directadmin/custombuild

    – Navigate to the Custombuild directory

  2. ./build options

    – Review your current settings

  3. nano options.conf

    – Edit the options.conf file, save and exit

  4. ./build update_data

    – Always run this command after updating options.conf

  5. ./build versions

    – check for available updates

  6. ./build update_versions

    – This last command will install all the updates that are pending

Don’t forget to restart Apache, if it does not automatically restart by the update script option. You can restart apache manually with this command.

systemctl restart httpd

That’s all there is to it for updating/changing PHP version or other services in DirectAdmin. But if you find this process complicated, you can use the automatic method. You can manage DirectAdmin PHP updates easily with the help of this plugin.  However, please note that this plugin requires Custombuild 2.0 to work.

Changing Php version with DirectAdmin Panel

In this guide, I’ve informed you about adding/updating PHP version in DirectAdmin custombuild.  And after performing this update you can use DirectAdmin for Php version change by using the following method:

First, you need to log into your DirectAdmin control panel & click on user level. And select your desired domain name that you want to change the PHP version for.

You can find the domains listed under the Domain setup option. Next, click on your account & select the domain name and change or select or change your desired PHP version.


Note: In the latest versions of DirectAdmin, you simply scroll down to features & click on Select PHP version.


In this guide, I went through the procedures for the DirectAdmin PHP version change, updating the DirectAdmin custom build. Along with the Updating PHP information, I’ve also talked about updating other services with DirectAdmin Custombuild. I know that this might seem like a complicated procedure, but it’s not. However, if you’re still confused about something feel free to ask questions in the comment section below. But before you go, check out the information box below to find some more relevant information.

Interested in related articles? Here’s one we think you’ll like: 13 Best WordPress Hostings in Australia!

Related Material

Looking for some better hosting providers with embedded cPanel or even DirectAdmin? check out our related articles:

Relevant Queries for DirectAdmin & Custombuild

Can you run PHP 8 on DirectAdmin?

Although, PHP 8 is already available on DirectAdmin and you can use it right now but some people have GD related warnings. Other than this, it’s safe to update to PHP 8 with DirectAdmin.

How many PHP versions can you choose in Custombuild 2.0?

As mentioned before,  you can choose multiple PHP versions with DirectAdmin custombuild 2.0. The exact number right now is 4.

How to Install WordPress with DirectAdmin?

Nowadays most hosting providers have the Softaculous app Installer in their DirectAdmin Cpanel. So to automatically Install WordPress follow this method:

To get more detailed information about WordPress Installation, check out our related article on Install WordPress

Leave a Reply