Installing UFM Infra Using Docker Root
This section provides installation instructions for UFM Enterprise running in Docker root mode with UFM infra support and NFS or shared storage. The configuration uses versioned directories and soft links to enable seamless upgrades.
Docker engine installed and running
HA configured with the multinode option and either drbd-dual-primary or NFS.
Root or sudo privileges
NFS or shared storage must be mounted at
/opt/ufm/shared_files
For more information on the UFM-HA package and all installation and configuration options, please refer to UFM High Availability User Guide.
Two systemd services:
ufm-enterprise.serviceandufm-infra.serviceShared Docker volume:
ufm-shared-datafor Apache configuration sharingUFM configuration: With Infra mode enabled
NoteNote: Both service files are created during installation to enable future mode switching without reinstallation. You can switch between Legacy and Infra modes using the
ufm_infra_feature_flag.pyscript.
You may install UFM in the original installation and switch to UFM Infra mode using the ufm_infra_feature_flag.py script. For more information, refer to UFM Infra.
Step 1: Create UFM Base Directory
mkdir -p /opt/ufm
mkdir -p /opt/ufm/ufm_plugins_data
Step 2: Load UFM Image and Extract Version
# Define the UFM image file path
UFM_IMAGE_FILE="<path to ufm*-docker.img.gz>"
# Load the UFM image
docker load -i "$UFM_IMAGE_FILE"
Step 3: Create a Soft Link
# Remove existing files link if it exists
rm -f /opt/ufm/files
# Create soft link
ln -s /opt/ufm/shared_files/ /opt/ufm/files
# Verify the soft link
ls -la /opt/ufm/files
Step 4: Run UFM Installer
docker run --name=ufm_installer --rm \
-v /var/run/docker.sock:/var/run/docker.sock \
-v /etc/systemd/system/:/etc/systemd_files/ \
-v /opt/ufm/files/:/installation/ufm_files/ \
-v [LICENSE_DIRECTORY]:/installation/ufm_licenses/ \
mellanox/ufm-enterprise:latest \
--install \
--fabric-interface ib0 \
--ufm-infra
Replace
ib0with your actual InfiniBand interface name, if it is not the default ib0.All other UFM install flags are supported and can be added to the command.
After this stage, you can skip the rest of the stages and use
ufm_infra_feature_flag.pyscript. For more information, refer to UFM Infra.
Step 5: Load Redis Image
Load the given Redis image (tested with Redis v7.2.4) (in case you are not using external Redis)docker load -i "".
Step 6: Load Fast API Plugin Image
# Define the Fast API plugin image file path
FAST_API_IMAGE="<PATH TO FAST API.img.gz file>"
# Load the Fast API plugin image
docker load -i "$FAST_API_IMAGE"
# Extract Fast API version from Docker image tag (exclude latest tag)
FAST_API_VERSION=$(docker images --format "{{.Repository}}:{{.Tag}}" | grep "mellanox/ufm-plugin-fast_api" | grep -v ":latest" | head -1 | cut -d':' -f2)
echo "Fast API Version: $FAST_API_VERSION"
Step 7: Install Fast API Plugin
docker run --hostname $HOSTNAME --rm --name=ufm_plugin_mgmt --entrypoint="" \
-v /var/run/docker.sock:/var/run/docker.sock \
-v /opt/ufm/files:/opt/ufm/shared_config_files \
-v /dev/log:/dev/log \
-v /sys/fs/cgroup:/sys/fs/cgroup:ro \
-v /lib/modules:/lib/modules:ro \
-v /opt/ufm/ufm_plugins_data:/opt/ufm/ufm_plugins_data \
-e UFM_CONTEXT=ufm-infra \
mellanox/ufm-enterprise:latest \
/opt/ufm/scripts/manage_ufm_plugins.sh add -p fast_api -t ${FAST_API_VERSION} -c ufm-infra
You can repeat steps 6 and 7 using UTM when working with the UFM Clustered Telemetry.
Step 8: (Optional) Install Additional Infra Plugins (UTM)
# Load the plugin image
docker load -i "<PATH_TO_PLUGIN_IMAGE>"
# Get plugin version
PLUGIN_VERSION=$(docker images --format "{{.Repository}}:{{.Tag}}" \
| grep "mellanox/ufm-plugin-<plugin_name>" \
| grep -v ":latest" \
| head -1 \
| cut -d':' -f2)
# Install the plugin
docker run --hostname $HOSTNAME --rm --name=ufm_plugin_mgmt --entrypoint="" \
-v /var/run/docker.sock:/var/run/docker.sock \
-v /opt/ufm/files:/opt/ufm/shared_config_files \
-v /dev/log:/dev/log \
-v /sys/fs/cgroup:/sys/fs/cgroup:ro \
-v /lib/modules:/lib/modules:ro \
-v /opt/ufm/ufm_plugins_data:/opt/ufm/ufm_plugins_data \
-e UFM_CONTEXT=ufm-infra \
mellanox/ufm-enterprise:latest \
/opt/ufm/scripts/manage_ufm_plugins.sh add -p <plugin_name> -t ${PLUGIN_VERSION} -c ufm-infr
Step 9: Reload systemd and Start Services
For Standalone Mode (No HA)
# Reload systemd daemon
systemctl daemon-reload
# Start UFM infra service first
systemctl start ufm-infra
# Then start UFM enterprise service
systemctl start ufm-enterprise
For HA Mode
If using HA, configure and start the HA cluster instead:
# Reload systemd daemon on all nodes
systemctl daemon-reload
# Start HA cluster (on master node)
ufm_ha_cluster start
After installation, you can switch between Legacy and Infra modes using the feature flag script:
Switch to Legacy Mode
cd /opt/ufm/files/scripts/
./ufm_infra_feature_flag.py --disable
Switch Back to Infra Mode
cd /opt/ufm/files/scripts/
./ufm_infra_feature_flag.py --enable