Apache ActiveMQ Artemis on Ubuntu 24.04 on Azure User Guide
Overview
Apache ActiveMQ Artemis is the next generation, high performance, multi protocol Java message broker that implements the JMS API and speaks the ActiveMQ core protocol, AMQP 1.0, STOMP and MQTT. Its asynchronous journal and non blocking architecture deliver high throughput and low latency for durable queues and topics. The cloudimg image installs Artemis 2.40.0 on OpenJDK 17 at /opt/artemis, creates a broker instance at /var/lib/artemis-broker, runs it as a dedicated artemis system user, fronts the Hawtio web console with an nginx reverse proxy on TCP 80, persists the broker journal, paging and bindings on a dedicated Azure data disk, and generates a unique web console password on the first boot of every VM. Backed by 24/7 cloudimg support.
What is included:
- Apache ActiveMQ Artemis 2.40.0 broker on OpenJDK 17 at
/opt/artemiswith a broker instance at/var/lib/artemis-broker - nginx reverse proxy on
:80in front of the Hawtio web console (bound to loopback:8161) - Core/OpenWire
61616, AMQP5672, STOMP61613and MQTT1883acceptors, all bound to loopback and reachable through your own network controls - A dedicated Azure data disk at
/var/lib/artemisholding the broker journal, paging and bindings, separate from the OS disk and re-provisioned with every VM - Per-VM web console password (
ARTEMIS_ADMIN_PASSWORD) generated at first boot, in a root only file artemis.service+nginx.serviceas systemd units, enabled and active- 24/7 cloudimg support
Prerequisites
An active Azure subscription, an SSH key pair, and a VNet plus subnet in the target region. Standard_B2ms (2 vCPU / 8 GiB RAM) is a good starting point for the JVM broker; scale up for higher message throughput. NSG inbound: allow 22/tcp from your management network, 80/tcp for the web console (front with TLS for public exposure, see Enabling HTTPS), and the acceptor ports your clients use (61616 core, 5672 AMQP, 61613 STOMP, 1883 MQTT) from your application networks.
Step 1 — Deploy from the Azure Marketplace
Sign in to the Azure Portal, choose Create a resource, search the Marketplace for Apache ActiveMQ Artemis by cloudimg, and select Create. On Basics pick your subscription, resource group, region and size; under Administrator account choose SSH public key and paste your key; under Inbound port rules allow SSH (22) and HTTP (80). Review the dedicated data disk on the Disks tab, then Review + create then Create.
Step 2 — Deploy from the Azure CLI
az vm create \
--resource-group <your-rg> \
--name artemis \
--image <marketplace-image-urn> \
--size Standard_B2ms \
--admin-username azureuser \
--ssh-key-values ~/.ssh/id_ed25519.pub \
--vnet-name <your-vnet> --subnet <your-subnet> \
--public-ip-sku Standard
az vm open-port --resource-group <your-rg> --name artemis --port 80 --priority 1010
Step 3 — Connect to your VM
ssh azureuser@<vm-public-ip>
Step 4 — Confirm the services are running
systemctl is-active artemis.service nginx.service
Both services report active. The broker can take a minute or two to fully start on first boot while the JVM warms up.

Step 5 — Retrieve your web console password
The web console password is generated uniquely on the first boot of your VM and written to a root only file:
sudo cat /root/artemis-credentials.txt
The ARTEMIS_ADMIN_PASSWORD value is the password; sign in to the web console as artemis with it.

Step 6 — Open the web console
Browse to http://<vm-public-ip>/ and sign in as artemis with the password from Step 5. The Artemis Hawtio web console lets you browse addresses and queues, inspect message counts, send and browse messages, and view broker attributes and the broker diagram.




Step 7 — Verify the broker health
The broker exposes a Jolokia REST endpoint behind the console at /console/jolokia/. Read the broker version to confirm it is healthy. Replace <password> with the value from Step 5 and run on the VM:
PW=<password>
curl -s -u artemis:$PW -H 'Origin: http://127.0.0.1' -H 'Content-Type: application/json' \
-X POST -d '{"type":"read","mbean":"org.apache.activemq.artemis:broker=\"0.0.0.0\"","attribute":"Version"}' \
'http://127.0.0.1/console/jolokia/'
The response is JSON with "status":200 and the broker version in value. The Jolokia endpoint requires authentication and a same origin request, so the Origin header must match the host you are calling.

Step 8 — Send and receive a test message
Artemis ships a producer and consumer CLI in the broker instance. Send one message to a queue, then drain it. Replace <password> with the value from Step 5 and run on the VM:
PW=<password>
sudo -u artemis /var/lib/artemis-broker/bin/artemis producer \
--user artemis --password "$PW" --url tcp://127.0.0.1:61616 \
--destination queue://DEMO --message-count 1
PW=<password>
sudo -u artemis /var/lib/artemis-broker/bin/artemis consumer \
--user artemis --password "$PW" --url tcp://127.0.0.1:61616 \
--destination queue://DEMO --message-count 1 --receive-timeout 10000 --break-on-null
The producer reports Produced: 1 messages and the consumer reports Consumed: 1 messages. The queue and its messages persist in the broker journal on the dedicated data disk.
Step 9 — Connect from your applications
Point JMS / core clients at tcp://<vm-public-ip>:61616, AMQP 1.0 clients at amqp://<vm-public-ip>:5672, STOMP clients at <vm-public-ip>:61613, and MQTT clients at <vm-public-ip>:1883. The acceptors bind to loopback by default for safety; expose only the protocols you need by publishing them through your own reverse proxy or load balancer, and open the matching NSG ports from your application networks only.
Enabling HTTPS
For production, terminate TLS at nginx with a real domain pointed at the VM's public IP. Install certbot and request a certificate (replace the domain):
sudo apt-get update && sudo apt-get install -y certbot python3-certbot-nginx
sudo certbot --nginx -d your-domain.example.com
Backup and maintenance
The broker journal, paging, large messages and bindings live on the dedicated data disk at /var/lib/artemis. Snapshot that disk in Azure to back up your durable queues and topics, and keep the OS patched with sudo apt update && sudo apt upgrade. The broker restarts cleanly with sudo systemctl restart artemis.
Support
This image is backed by 24/7 cloudimg support. Contact us by email and chat for help with broker configuration, protocol acceptors, clustering, persistence, TLS and backups.
All product and company names are trademarks or registered trademarks of their respective holders. Use of them does not imply any affiliation with or endorsement by them.