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!
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:
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:
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:
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:
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:
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:
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.
apt update
Install 3CX v20 Software
Begin the installation of 3CX with:
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).
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.
3 Comments
Hi Roosho,
Thank you for the clear explanation on how to install 3CX V20 on Debian 12. I followed all the steps successfully. However, I have a Debian 12 system running Docker and several other applications. I am a little bit apprehensive about running the last command in your instructions, “apt install 3cxpbx”. The last time I did that, 3CX installed fine, but the server became inaccessible. Even Docker couldn’t start up. Does the installation overwrite system files, such as the boot section, or does it leave them alone?
Hello Onno,
THanks a lot for your feedback. I am also failining with Docker. So, far I have gathered information that 3CX is not supported with Docker. But I am working on it. Hopefully I will be able to get to a solution. I will inform you as soon as there is a solution. In the mean time you can keep your eyes on my website for other updates.
Thanks
Hey Roosho !
Thanks a lot for your article ! Do you know if it is possible to choose which version/update you install ?
Sank