Installing Acronis Backup & Recovery Agent for Linux v10 on Xen based kernel
Hey guys,
Wondering if anybody was able to install Acronis Agent v10 on XenServer based kernel successfully. I'm running SLES 11 SP1 with 2.6.32.29-0.3-xen kernel. Obviously linux-kernel-headers-2.6.32-1.4.13 by default are loaded, but headers are not for xen and Acronis SNAPAPI compilation errors out with message "Failed to find kernel source directory '/lib/modules/2.6/32/29-0.3-xen/build'".
dkms build -m snapapi26 -v 0.7.54 -k $(uname -r) --arch $(uname -m) --config /boot/config-$(uname -r) --kernelsourcedir /lib/modules/$(uname -r)/source
Error! Your kernel source for kernel 2.6.32.29-0.3-xen cannot be found at
/lib/modules/2.6.32.29-0.3-xen/build or /lib/modules/2.6.32.29-0.3-xen/source.
You can use the --kernelsourcedir option to tell DKMS where it's located.
Is there any way to compile SNAPAPI in this environment? Not sure where I can retrieve xen kernel headers or sources from.
Thanks,
Saulius

- Se connecter pour poster des commentaires

This article is good as long as target Linux VM is based on RedHat el5 kernel. In my case I run SLES 11 SP1 and obviously compiled kernel module on el5 is incompatible on target host and cannot be loaded due to invalid module format.
DDK kernel: 2.6.18-128.1.6.el5.xs5.5.0.505.1024xen
Target Host: 2.6.32.27-0.2-xen (SLES11SP1)
Any ideas where to retrieve 2.6.32.27-0.2-xen or 2.6.32.29-0.3-xen headers for SLES from? Meanwhile will try contacting Novell directly.
- Se connecter pour poster des commentaires

Update from Novell. Kernel source code rpm is the same for xen and native kernels.
All the kernel sources are installed in /usr/src/linux-2.6.32.29-0.3/kernel
So I created extra symbolic link pointing to source files:
/lib/modules/2.6.32.29-0.3-xen/source -> /usr/src/linux-2.6.32.29-0.3/kernel
but so far no luck.
uname -r
2.6.32.29-0.3-xen
rpm -qa |grep kernel
kernel-xen-base-2.6.32.29-0.3.1
kernel-xen-2.6.32.29-0.3.1
linux-kernel-headers-2.6.32-1.4.13
kernel-source-2.6.32.29-0.3.1
dkms build -m snapapi26 -v 0.7.54 -k $(uname -r) --arch $(uname -m) --config /boot/config-$(uname -r) --kernelsourcedir /lib/modules/$(uname -r)/source
Error! Your kernel source for kernel 2.6.32.29-0.3-xen cannot be found at /lib/modules/2.6.32.29-0.3-xen/build or /lib/modules/2.6.32.29-0.3-xen/source.
You can use the --kernelsourcedir option to tell DKMS where it's located.
#with specific path
dkms build -m snapapi26 -v 0.7.54 -k $(uname -r) --arch $(uname -m) --config /boot/config-$(uname -r) --kernelsourcedir /usr/src/linux-2.6.32.29-0.3/kernel/
Error! Your kernel source for kernel 2.6.32.29-0.3-xen cannot be found at
/lib/modules/2.6.32.29-0.3-xen/build or /lib/modules/2.6.32.29-0.3-xen/source.
You can use the --kernelsourcedir option to tell DKMS where it's located.
I hope there is something simple here, but so far can't figure out.
- Se connecter pour poster des commentaires

Problem solved. Applying steps from couple of other links with some minor modifications allowed to build Acronis Agent on Suse SLES Xen based kernel running as a guest on XenServer.
Linux Client on SLES 11
=======================
1. Install need packets for build
# zypper in kernel-xen-base kernel-source kernel-syms linux-kernel-headers gcc
cd /usr/src/linux
#http://forum.acronis.com/forum/9769#comments
zcat /boot/symvers-2.6.32.29-0.3-xen.gz > Module.symvers
make cloneconfig
make modules_prepare
#dkms remove -m snapapi26 -v 0.7.54 –all
# download last snapapi26 from http://kb.acronis.com/content/9317
# wget -c http://kb.acronis.com/sites/default/files/content/2010/03/9317/snapapi2…
wget AcronisAgentLinux_v.10.0.12708.i686
chmod +x AcronisAgentLinux_v.10.0.12708.i686
./AcronisAgentLinux_v.10.0.12708.i686
#if kernet module build fails – follow dkms manual rebuild steps below.
#on SLES set:
vi /etc/modprobe.d/unsupported-modules and set to 1
#make sure driver loads
modprobe snapapi26 && lsmod | grep snapapi26
reboot
#Open up firewall for TCP 9876
#Add machine into AMS
#Apply Backup Policy
#Do first full backup
#All Done!!!
#dkms manual rebuild steps
dkms ldtarball --archive /usr/lib/Acronis/kernel_modules/snapapi26-0.7.54-all.tar.gz
#dkms build -m snapapi26 -v 0.7.54 -k $(uname -r) --arch $(uname -m) --config /boot/config-$(uname -r) --kernelsourcedir /usr/src/linux
dkms build -m snapapi26 -v 0.7.54
dkms install -m snapapi26 -v 0.7.54
modprobe snapapi26 --allow-unsupported
#moving to other server
From: http://kb.acronis.com/content/9766
1. from Copy the created file snapapi26.ko to /lib/modules/`uname -r`/kernel/drivers/block directory of the host machine;
2. Recreate the list of module dependencies:
# depmod
#on SLES:
vi /etc/modprobe.d/unsupported-modules and set to 1
3. Make sure the driver can load:
# modprobe snapapi26 && lsmod | grep snapapi26
- Se connecter pour poster des commentaires

Hello Saulius,
From your initial post, I guess that the machine has a XEN hypervisor running.
Are you trying to backup the host, as well as all the virtual machines with the single Linux agent?
Thanks,
Asier
- Se connecter pour poster des commentaires