How to Install Apache ActiveMQ on Debian 11
Apache ActiveMQ is a free and open-source message broker developed by Apache Software Foundation. It is one of the well-known message brokers that supports multiple protocols such as AMQP, MQTT, Stomp, and OpenWire. It is written in Java and fully compliant with JMS 1.1 standards.
Apache ActiveMQ is one of the most popular message brokers that support different types of programming languages that can be deployed on multiple platforms. It is an enterprise-grade message broker that provides high availability, scalability, reliability,
high performance, and security.
In this post, you will learn how to install the Apache ActiveMQ Multi-Protocol message broker on the Debian 11 system. This tutorial includes the installation of Java OpenJDK and JRE and the configuration of the JAVA_HOME environment variable.
- A Linux server Debian 11.
- A non-root user with root administrator privileges.
Install Java OpenJDK and JRE
First, you will need to install the Java OpenJDK and JRE before installing the Apache ActiveMQ. The current version of Apache ActiveMQ required a minimum Java JRE v1.8.
On the Debian 11 repository, there are multiple versions of Java OpenJDK and JRE. But you will be installing Java OpenJDK and JRE v1.11 for the Apache ActiveMQ.
Refresh and update your Debian repository using the below command.
sudo apt update
Next, install java OpenJDK and JRE using the apt command below.
sudo apt install default-jdk default-jre
Type Y to confirm the installation and press ENTER to continue.
Now move to the next step to start the Apache ActiveMQ installation.
Installing Apache ActiveMQ
The Apache ActiveMQ provides multiple versions of the ActiveMQ. In this example, you will be installing the Apache ActiveMQ Classic, which is powerful and supports multiple messaging protocols such as AMQP, MQTT, Stomp, and OpenWire.
Additionally, you can install another version such as ActiveMQ Artemis in the same way as the ActiveMQ classic.
To start the installation, run the below command to download the Apache ActiveMQ v5.17 (the latest version during this writing).
After the download process is completed, you will see the file apache-activemq-5.17.1-bin.tar.gz. Extract it using the following command.
tar -xzvf apache-activemq-5.17.1-bin.tar.gz
Next, move the extracted directory apache-activemq-5.17.1 to the /opt/activemq.
mv apache-activemq-5.17.1 /opt/activemq
After installation is completed, check the Java version using the following command.
On the below screenshot, you will see that Java OpenJDK 1.11 is installed on the Debian system.
Go to the next step to set up the JAVA_HOME environment variable.
Setting Up JAVA_HOME Environment Variable
The Apache ActiveMQ required the JAVA_HOME environment variable to be configured correctly to the jvm installation directory, which is available at /usr/lib/jvm/java-11-openjdk-amd64 directory. And in a simple way, you can set up the JAVA_HOME environment variable through the “~/.bashrc” file.
Add the configuration to the “~/.bashrc” configuration file using the below command.
This article originally appeared on techblog.com, to read the full article, click here.
Nastel Technologies is the global leader in Integration Infrastructure Management (i2M). It helps companies achieve flawless delivery of digital services powered by integration infrastructure by delivering Middleware Management, Monitoring, Tracking, and Analytics to detect anomalies, accelerate decisions, and enable customers to constantly innovate, to answer business-centric questions, and provide actionable guidance for decision-makers. It is particularly focused on IBM MQ, Apache Kafka, Solace, TIBCO EMS, ACE/IIB and also supports RabbitMQ, ActiveMQ, Blockchain, IOT, DataPower, MFT and many more.
The Nastel i2M Platform provides:
- Secure self-service configuration management with auditing for governance & compliance
- Message management for Application Development, Test, & Support
- Real-time performance monitoring, alerting, and remediation
- Business transaction tracking and IT message tracing
- AIOps and APM
- Automation for CI/CD DevOps
- Analytics for root cause analysis & Management Information (MI)
- Integration with ITSM/SIEM solutions including ServiceNow, Splunk, & AppDynamics