Quantcast
Channel: Veeam Support Knowledge Base
Viewing all articles
Browse latest Browse all 4362

Impact of tmux on Veeam Interactions With Linux OS

$
0
0

Impact of tmux on Veeam Interactions With Linux OS

KB ID: 4466
Product: Veeam Backup & Replication
Veeam ONE
Veeam Agent for Linux
Published: 2023-06-22
Last Modified: 2023-06-22

Purpose

This article documents a known incompatibility between Veeam applications that initiate SSH connections to remote Linux machines and those Linux machines being configured to have tmux autorun when users connect.

 

Connection Examples

As stated, this issue affects all interactions wherein a Veeam application makes an SSH connection to a remote Linux server that has tmux automatically start during account login. The list below is not exhaustive and presents the most commonly impacted scenarios.

Known Limitation

Veeam Backup & Replication does not support SSH connections to a server where when the user Veeam logs in as is configured to have tmux automatically start.

  • For persistent agents, automatic tmux at login must be disabled during the initial deployment of the Veeam Data Mover services that are installed when the Linux Machine is first added to Veeam Backup & Replication.
  • For Hardened Repositories, review: https://www.veeam.com/kb4250
  • For non-persistent agents, automatic tmux must be disabled completely for the user Veeam Backup & Replication is configured to connect as.
    Note: This use scenario is rare as it only occurs when the account supplied to Veeam Backup & Replication does not have sudo rights.
To successfully deploy the Veeam services on the system, tmux must be temporarily disabled or disabled for the account used by Veeam (see More Information section). Usually, this is configured in /etc/bashrc for all users on the system, as shown here:
[user@rhel8 ~]$ sudo grep tmux /etc/bashrc
case "$name" in sshd|login) exec tmux ;; esac

While this specific example is from RHEL 8 using the NIST 800-171 security profile, which includes tmux automatic startup system-wide, the same concept applies to other distros.

To disable the automatic launching of tmux, edit the /etc/bashrc file and comment (#) out the line with tmux, as shown in the grep output below.

[user@rhel8 ~]$ sudo grep tmux /etc/bashrc
#case "$name" in sshd|login) exec tmux ;; esac
If an account was provided to Veeam Backup & Replication that had root equivalent permissions (sudo), the Veeam Data Mover services would be installed during the process of adding the Linux machine to Veeam Backup & Replication. Once that is complete, Veeam Backup & Replication will no longer need to SSH into that Linux machine for most day-to-day operations; As such, the automatic tmux at login can be re-enabled.

More Information

For non-persistent configurations, or customers seeking to ensure Veeam Backup & Replication can SSH into the Linux machine as needed for operations such as upgrading the Data Mover Services, an exemption could be created to prevent tmux from starting for the specific user account provided to Veeam Backup & Replication.

For example, below is the default if statement used to start tmux automatically.

if [ "$PS1" ];then
parent=$(ps -o ppid= -p $$)
name=$(ps -o comm= -p $parent)
case "$name" in (sshd|login) exec tmux ;; esac
fi

By adding a qualifier to the initial if statement to check for a specific username, it is possible to exempt a single user from having tmux start automatically. (In this example, that user account is named 'veeam'.)

if [ "$PS1" ] && [ "$(id -un)" != "veeam" ];then
parent=$(ps -o ppid= -p $$)
name=$(ps -o comm= -p $parent)
case "$name" in (sshd|login) exec tmux ;; esac
fi
To submit feedback regarding this article, please click this link: Send Article Feedback
To report a typo on this page, highlight the typo with your mouse and press CTRL + Enter.

Viewing all articles
Browse latest Browse all 4362

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>