Setting Up Containers on CentOS in Azure
This section will walk you through the steps required to manually get a Solace Virtual Message Router (VMR) Docker container up-and-running on a CentOS instance in Microsoft Azure.
- You have an Azure account with permission to create and run a virtual machine.
- Docker Engine used—minimum version 1.12.0
- Step 1: Launch a Host in Azure
- Step 2: Install Docker
- Step 3: Set Storage-Driver and IPtables
- Step 4: Get a VMR Docker Container Package
- Step 5: Set Docker Create Options
- Step 6: Create the VMR Docker Container
- Additional VMR Docker Container Configuration
Use the Azure Dashboard’s Launch setup wizard to create an Azure virtual machine that you can use to run a VMR Docker container on.
- On the Azure dashboard, click the Virtual Machines icon, and then click +Add.
Follow the setup wizard, and accept the recommended default settings, except as noted in the following steps.
- In the Compute window, search for the host OS you want to use.
For a CentOS 7 host, CentOS-Based 7.2 is recommended.
- In the Choose Virtual Machine Size step, select a size.
For a non-production deployment, the following minimum instance types are recommended:
- To support a combined maximum of 1,000 client connections, a minimum of 2 vCPUs and 4 GiBs of memory is required, and a minimum of 30 GB storage and a General Purpose SSD are recommended. The recommended minimum virtual machine size is DS11_V2.
- To support a combined maximum of 10,000 client connections, a minimum of 4 vCPUs and 12 GiBs of memory is required, and a minimum of 30 GB storage and General Purpose SSD are recommended. The recommended minimum virtual machine size is DS3_V2.
- To support a combined maximum of 100,000 client connections, a minimum of 8 vCPUs and 28 GiBs of memory is required, and a minimum of 30 GB storage and General Purpose SSD are recommended. The recommended minimum virtual machine size is DS13_V2.
For information about client connection scaling, refer to VMR Connection Scaling Tiers.
- For a test deployment, it is recommended that the network security group include the following inbound rules.
Soure Destination Service Action Any Any SSH(TCP/22) Allow Any Any Custom (TCP/8080) Allow Any Any Custom (TCP/55555) Allow
These port numbers are used for the following services: 22-Host SSH; 8080-SEMP/SolAdmin; 55555-SMF/non-compressed message data connections. Other ports can be opened as required. For a list of ports associated with VMR services, see VMR Configuration Defaults.
Manually install and configure Docker on your CentOS host. Instructions can be found on the Docker Get Docker for CentOS Web page.
You have to set the
iptables options on the host system.
For systemd-based systems, create a
daemon.json file to set the
devicemapper Docker daemon options. For test deployments, it is recommended to set
These options are set in the
daemon.json file located in
/etc/docker/. Follow these steps to set the options.
- If Docker is not stopped, then enter this command.
>sudo systemctl stop docker
- Create the
sudo tee /etc/docker/daemon.json <<-EOF
- Apply the settings.
>sudo systemctl daemon-reload
>sudo systemctl disable docker
>sudo systemctl enable docker
>sudo systemctl start docker
You must obtain a VMR Docker container image—a compressed tar archive containing a VMR Docker repository, which consists of a single VMR Docker Image.
- Community edition of the VMR—Go to the Downloads page of dev.solace.com. Then in the VMR Community Edition area, select Docker Images > Solace VMR Docker Package. After you read and agree to the license agreement, a compressed archive file called
soltr-<version>-vmr-community-docker.tar.gzwill be downloaded.
- Enterprise version of the VMR Docker package—If you have purchased an Enterprise version of the VMR Docker package, Solace will give you information for how to download an enterprise version of the compressed tar archive package from a secure Solace server. Contact Solace Support at email@example.com if you require assistance.
Once you have obtained a copy of the Solace VMR Docker Package, you can upload it to a directory on your host and load the image using these two steps:
- Start Docker:
>sudo systemctl start docker
Tip: You can use the
statuscommand to check the status of Docker.
>sudo systemctl status docker
The display above shows that Docker is up and running.
- Load the image from the VMR Docker package:
>sudo docker load -i /tmp/soltr-<version>-vmr-community-docker.tar.gz
In this example, it has been assumed that the compressed tar archive of an Community Edition VMR Docker container image has been uploaded to
When loading is finished, you can check the image with the
>sudo docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
solace-app 8.x.x.x-community 529588fc82ce 4 days ago 856.6 MB
There are many options that you can set for the
docker create command.
For test deployments, it is recommended that you create a
docker-create file, which will enable you to set various
docker create command options. The examples provided in this step will show you how to create a suitable
docker-create file for a test deployment.
For production deployments, there are use-case dependent factors that will impact the option and configuration key settings in the
docker create command. For more information on considerations for the configuration of product deployments, see Index of VMR Container Configuration Tasks.
- Create a
>sudo tee /root/docker-create <<-EOF
sudo docker create \
--ulimit core=-1 \
--ulimit memlock=-1 \
--ulimit nofile=2448:38048 \
--env 'username_admin_globalaccesslevel=admin' \
--env 'username_admin_password=admin' \
In this example, the
adminSolace CLI user and an associated password are defined at container creation through the
username_admin_passwordconfiguration keys. By default, in a VMR Docker container, no Solace CLI users are defined, so setting these configuration keys allows the container to be administered through the Solace SolAdmin management tool without first entering the Solace CLI to create an
In the above
docker createcommand, the repository name is
<version-edition>is dependent on the VMR Docker package you obtained in Step 2. For example, if you downloaded a version 184.108.40.206 Community Edition Docker Container Image, the value of
220.127.116.11-community, where “
version” is the release version, and the edition can be “
enterprise” or “
Note: To support a combined maximum of 100,000 client connections, it is recommended to change the file descriptor setting to the following.
- Make the
>sudo chmod +x /root/docker-create
Create and run the VMR Docker container on your CentOS host.
- Create the VMR Docker container:
Once it’s done running, a long identifier will be displayed that looks something like this:
This is the ID for the VMR container you have just created.
- Start the VMR Docker container:
>sudo docker start solace
You can use the
docker pscommand to check on the status of the VMR Docker container once it’s running.
>sudo docker ps
STATUScolumn associated with the VMR Docker container will display if the container is running and for how long.
You now have a VMR Docker container with a basic configuration that is ready for messaging tasks. However, there are additional configuration tasks that you can perform. At this stage, you should do the following:
- Review the following extra configuration tasks specific to VMR Docker containers. These additional configurations allow you to further customize your VMR Docker container to better suit your particular use-case and to make it more suitable for a production deployment.
Below are some further configuration and monitoring tasks that are useful in the basic operation of a VMR Docker Container.
Below are some common configuration tasks that often must be performed when using a VMR Docker Container in a production environment.
- Configuring an Arbitrary User ID
- Configuring Direct-LVM Mode
- Assigning External Storage to VMR Containers
- Configuring Docker Create Options
- Configuring VMR Containers with Configuration Keys
- VMR Connection Scaling Tiers
- Configuring Core Dump Management
- Configuring VMR Container Logging
- Gathering Router Diagnostics for VMR Docker Containers
- Working with Docker Monitoring Commands
- Begin to configure and manage the VMR Docker container’s messaging operations through the Solace CLI in the same manner as you would other Solace messaging routers (say, a Solace messaging appliance or a Solace VMR machine image). For information on how to perform these configuration and management tasks, see the topics in the Router Configuration category of the Solace customer documentation.