How to Install 3CX v20 on Debian 12 Linux on KVM Cloud

Install 3cx V20 on Debian 12 Just Copy-paste Commands

How to Install 3CX v20 on Debian 12 Linux on KVM Cloud

Home » Blog » Cookbook » VoIP » 3cx » How to Install 3CX v20 on Debian 12 Linux on KVM Cloud
Installing 3CX v20 on your Debian 12 system can be a straightforward process when you understand each step. This guide provides details on the commands used during the installation.
Table of Contents

As in this article we have talked about, Trying to upload a custom ISO to most local cloud service providers is like asking a cat to fetch – it’s just not in their nature. They’ll happily hand you the keys to a cloud server via SSH or poke a hole in the firewall for you, but when it comes to OS options, it’s like choosing from a menu at a restaurant that only serves three kinds of sandwiches. And if you’re dreaming of installing 3CX Phone System v20 in the cloud the old-school ISO way, you might as well be trying to teach a goldfish to ride a bicycle – it’s simply not happening! But fear not, it’s a safe bet that Debian 12 will be strutting its stuff on their OS lineup – it’s like the reliable old diner that always has your favorite burger. You only need this trusty steed to kickstart your 3CX v20 adventure. As for the rest, relax! I’ve got it all mapped out in this cookbook like a treasure map to cloud-computing nirvana. Just follow the X marks the spot!

Why was the VoIP phone late to the meeting…?
It got hung up in traffic.

– RooSho

Installing 3CX v20 on Debian 12 system can be a straightforward process when you understand each step. This guide provides details on the commands used during the installation.

Prerequisites

  • A clean installation of Debian 12.
  • Root access to the system.
  • Control to NAT/Forward required Firewall ports
  • An active internet connection.

Open a Terminal Session

Access your Debian 12 cloud instance or VPC or VPS and open the terminal. This can usually be done by searching for ‘Terminal’ in your applications menu.

Gain Root Privileges

If not logged in as the root user, switch to the root user by executing:

SSH Config
sudo -i

Enter your password when prompted.

Root is the default administrator account on Linux that has full system privileges. Use sudo -i to switch to the root user, which allows you to execute commands with administrative privileges. Enter your regular user’s password when prompted.

Update Your System

Ensure that your system is up to date with the latest packages and security updates:

SSH Config
apt update && apt upgrade -y

Confirm any prompts that come up during the upgrade process.

If you’re asked about keeping or replacing configuration files, choose according to your requirements (usually keeping the current version is safe if you have made custom configurations).

Updating the system ensures you have the latest security patches and software updates.

  • apt update: Refreshes the list of available packages and their versions, but it does not install or upgrade any packages.
  • apt upgrade -y: Upgrades all updatable packages to the latest version. The -y flag automatically confirms the installation of packages.

Install Required Packages for 3CX v20

Install some prerequisite packages with the following command:

SSH Config
apt install sudo wget gnupg2 dphys-swapfile

Some packages are necessary for 3CX to run or to perform the installation.

  • sudo: Allows a permitted user to execute a command as the superuser.
  • wget: A utility for non-interactive download of files from the web.
  • gnupg2: GNU Privacy Guard is a replacement for the original PGP cryptographic software, allows encrypting and signing data and communications.
  • dphys-swapfile: A swap file manager which sets up a swap space if there is none.

Add the 3CX v20 Repository

To add the GPG key for the 3CX repository to your system, use:

SSH Config
wget -O- https://repo.3cx.com/key.pub | gpg --dearmor | sudo tee /usr/share/keyrings/3cx-archive-keyring.gpg > /dev/null

Add the 3CX repository to your APT sources:

SSH Config
echo "deb [arch=amd64 by-hash=yes signed-by=/usr/share/keyrings/3cx-archive-keyring.gpg] http://repo.3cx.com/3cx bookworm main" | tee /etc/apt/sources.list.d/3cxpbx.list

For the testing repository, if needed, execute:

SSH Config
echo "deb [arch=amd64 by-hash=yes signed-by=/usr/share/keyrings/3cx-archive-keyring.gpg] http://repo.3cx.com/3cx bookworm-testing main" | tee /etc/apt/sources.list.d/3cxpbx.list

Repositories are servers which contain sets of software that your system can install.

  • wget: Retrieves the signing key for the 3CX repository.
  • gpg --dearmor: Converts the downloaded key into a format that APT can understand.
  • tee: Takes the output from the previous command and writes it to a file while also displaying it.
  • /usr/share/keyrings/3cx-archive-keyring.gpg: The location where the APT keyring is stored.
  • echo: Prints out its arguments as a string of text.
  • |: A pipe that takes the output from one command and inputs it into another.
  • sudo tee /etc/apt/sources.list.d/3cxpbx.list: Writes the 3CX repository source list to APT’s list of sources.

Update Package Lists Again

After adding new repositories, it’s important to refresh your package lists to make APT aware of the new packages available.

SSH Config
apt update

Install 3CX v20 Software

Begin the installation of 3CX with:

SSH Config
apt install 3cxpbx

Accept the 3CX License Agreement

During the installation, you will be prompted to accept the 3CX License Agreement. Read the agreement carefully, and if you agree to the terms, continue with the installation.

Configure 3CX v20

Upon completion of the installation, you will be presented with options to configure 3CX. You can choose to run the configuration tool from a web browser or the command line.

  • Choosing (1) will allow you to configure 3CX via a web interface.
  • Choosing (2) will allow you to configure 3CX from the command line.

If choosing (1), you’ll be provided with a URL to access the configuration tool from a browser. It’s important to use the correct IP address that corresponds to your machine’s network setup. (ensure that you replace the local IP with your public IP if you are setting this up on a cloud machine).

SSH Config
http://172.31.28.41:5015/

Access the URL from your browser and follow the instructions to complete the 3CX configuration.

Conclusion

You now have 3CX v20 installed and configured on your Debian 12 system. For more detailed instructions and troubleshooting, refer to my 3CX cookbooks.

Remember that maintaining system security is critical, especially when setting up a PBX system. Ensure that you follow best practices for securing your 3CX installation and the underlying Debian system.

share this article.
I am Rakib Raihan RooSho, Jack of all IT Trades. You got it right. Good for nothing. I try a lot of things and fail more than that. That's how I learn. Whenever I succeed, I note that in my cookbook. Eventually, that became my blog. 
I am Rakib Raihan RooSho, Jack of all IT Trades. You got it right. Good for nothing. I try a lot of things and fail more than that. That's how I learn. Whenever I succeed, I note that in my cookbook. Eventually, that became my blog. 

Enjoying my articles?

Sign up to get new content delivered straight to your inbox.

Please enable JavaScript in your browser to complete this form.
Name