Steps to Install CDP-Agent on your server

Introduction

CDP Backups can help you manage a node’s backup policy to save files and folders of your E2E Node and also, rolling back to a previous backup recovery point anytime. We recommend you to subscribe for CDP backup service for all your nodes, especially the servers for a production environment

In this tutorial, We will go through the steps to install cdp-agent on your nodes.We will be using example of Centos 8 and Ubuntu 20.

Incase if you have uninstalled this application or you are importing your custom image on e2enetworks portal, You can refer mentioned steps on this tutorial to install cdp-agent.

CDP-agent Installation on CentOS/RHEL/Fedora

Step 1: Download the Repository

Create r1soft.repo file to install the cdp-enterprise-agent

vim /etc/yum.repos.d/r1soft.repo

Enter below text

[r1soft]

name=R1Soft Repository Server

baseurl=http://repo.r1soft.com/yum/stable/$basearch/

enabled=1

gpgcheck=0

Step 2: Installing the cdp-enterprise-agent

To install cdp-agent on your server, Please use below command

yum install r1soft-cdp-enterprise-agent

Enable cdp-agent on boot

chkconfig cdp-agent on

Once the cdp-agent is installed verify the cdp of cdp-agent using below command

systemctl status cdp-agent

Step 3: Get Driver Module

Run the below command to get the driver module.

r1soft-setup --get-module

If headers are missing for modules then download the kernel-devel according to kernel version and install it.

It will provide the required headers for module.

  1. to check kernel version

uname -a
  1. download kernel-devel of exactly the same kernel version.

wget http://mirror.centos.org/centos/6.4/updates/x86_64/Packages/kernel-devel-XYZ.rpm (example)
  1. install kernel-devel

yum --nogpgcheck install kernel-devel-XYZ.rpm
  1. run the command to get the driver module.

r1soft-setup --get-module

Step 4: Restart CDP agent

Restart cdp agent once to make the changes reflected

systemctl restart cdp-agent

Step 5: Adding CDP Server key to CDP Agent server

For security reasons, CDP Agent accepts connections only from known CDP Servers.

To authorize a CDP Server to CDP Agent, you must add the CDP Server’s public/private key to Agent’s configuration.

To add the Server’s key to the Agent’s configuration, run the following command on the Agent machine

r1soft-setup --get-key http://ip-of-cdp-server:8080/

CDP agent Installation on Debian/Ubuntu

Step 1: Download the Repository

Modify your /etc/apt/sources.list to include the R1Soft repository, and then download the R1Soft apt gpg key.

echo deb http://repo.r1soft.com/apt stable main >> /etc/apt/sources.list
wget http://repo.r1soft.com/r1soft.asc
apt-key add r1soft.asc
apt-get update

Step 2: Installing the cdp-enterprise-agent

To install cdp-agent on your server, Please use below command

apt-get install r1soft-cdp-enterprise-agent

Enable cdp-agent on boot

update-rc.d cdp-agent defaults

Once the CDP-agent is installed verify the cdp of cdp-agent using below command

service cdp-agent status

Step 3: Get Driver Module

Run the below command to get the driver module.

r1soft-setup --get-module

Step 4: Install Suitable Drivers

To Install suitable Driver,Please use below command

apt-get install linux-headers-`uname -r`

Step 4: Restart CDP agent

Restart cdp agent once to make the changes reflected

service cdp-agent restart

Step 5: Adding CDP Server key to CDP Agent server

For security reasons, CDP Agent accepts connections only from known CDP Servers.

To authorize a CDP Server to CDP Agent, you must add the CDP Server’s public/private key to Agent’s configuration.

To add the Server’s key to the Agent’s configuration, run the following command on the Agent machine

r1soft-setup --get-key http://ip-of-cdp-server:8080/