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

Asking Linux 

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.

Keeping the current version is safe if you have made custom configurations on your Debian 12

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 Required Packages for 3CX v20 on Debian 12

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

Download 3CX v20 Repository on Debian 12

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 3CX v20 repository to your APT sources

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, execute bookworm-testing

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

Install 3CX v20 Software on Debian 12

Begin the installation of 3CX with:

SSH Config

apt install 3cxpbx

Accept the 3CX License Agreement

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.
Choosing option 1 will allow you to configure 3CX via a web interface.

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://YOUR_SERVER_IP:5015/

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

Recommended Posts

How to Start Using a Web Hosting Account

Starting with a web hosting account is an essential step in launching your online presence. Whether you’re setting up a personal blog, an e-commerce website, or a professional portfolio, a hosting account serves as the foundation. Here’s a comprehensive guide to help you get started: Step 1: Choose the Right Hosting Plan Before diving into […]

Asking Linux 

5 Linux commands to check free disk space

Keeping track of disk utilization information is on system administrators’ (and others’) daily to-do list. Linux has a few built-in utilities that help provide that information. Linux df command The df command stands for “disk-free,” and shows available and used disk space on the Linux system. df -h shows disk space in human-readable format df -a shows the file system’s […]

Asking Linux