DRLM integration with ReaR

DRLM (Disaster Recovery Linux Manager) integration with ReaR
=====================================================

These are the required configurations in order to configure ReaR to work properly with DRLM:

ReaR client required configurations for DRLM:
======================================

- Create DRLM user on the client side:

useradd -d /home/drlm -c "DRLM User" -m -s /bin/bash drlm
passwd drlm

**NOTE: password will be blocked, the connection is only allowed using ssh keys. 

- Disable password aging for drlm user:

chage -I -1 -m 0 -M 99999 -E -1 drlm


- Copy ssh key from DRLM Server to the new client (login as root on DRLM server):

ssh-copy-id drlm@client_name

SUDO DRLM user configuration:
===========================
- On the client side (if not present):

mkdir /etc/sudoers.d
chmod 750 /etc/sudoers.d
echo "#includedir /etc/sudoers.d" >> /etc/sudoers

- Create SUDOERS DRLM user rules (in old SUDO versions you may need to configure DRLM rule directly in /etc/sudoers):

vi /etc/sudoers.d/drlm

         Cmnd_Alias DRLM = /usr/sbin/rear -dDv mkrescue, \ 
	 /usr/sbin/rear -dDv mkbackup, \ 
	 /usr/sbin/rear -d mkrescue, \ 
	 /usr/sbin/rear -d mkbackup, \ 
         /usr/sbin/rear -D mkrescue, \ 
         /usr/sbin/rear -D mkbackup, \ 
         /usr/sbin/rear -v mkrescue, \ 
         /usr/sbin/rear -v mkbackup, \ 
         /usr/sbin/rear mkrescue, \ 
         /usr/sbin/rear mkbackup, \ 
	 /usr/sbin/rear dump 

         drlm    ALL=(root)      NOPASSWD: DRLM 

chmod 440 /etc/sudoers.d/drlm


- Disable password login:

 passwd -l drlm

DRLM Required /etc/rear/[local.conf|site.conf] settings:
============================================
DRLM_NAME=rearclient01
DRLM_SERVER=drlmserver01

OUTPUT=PXE
OUTPUT_URL=nfs://${DRLM_SERVER}/DRLM/STORE/${DRLM_NAME}
OUTPUT_PREFIX=PXE

BACKUP=NETFS
NETFS_PREFIX=BKP
BACKUP_URL=nfs://${DRLM_SERVER}/DRLM/STORE/${DRLM_NAME}