If you are trying to setup r1soft backups and getting errors like:
- Failed to get suitable module for this system: Failed to read directory open *some dir*: no such file or directory
Failed to find headers at *some dir*
- Unable to find a valid source directory. Please install the kernel headers for your operating system
- This article should help you fix this.
First, let’s ensure that r1soft kernel module not loaded so we don’t do unnecessary work. Type to your console and execute:
# lsmod | grep hcp
if it’s showing you something like:
hcpdriver 75664 4
Then you don’t have to do anything, module is already loaded and all you need to do – start r1soft agent.
If you see empty output, then we really have to get the module. Basically we need to ensure that system have corresponding kernel-devel and kernel-headers packages:
# rpm -qa | grep kernel-headers-$(uname -r)
# rpm -qa | grep kernel-devel-$(uname -r)
If both commands giving you something like:
# kernel-devel-(your kernel version here).x86_64
# kernel-headers-(your kernel version here).x86_64
and if r1soft module still can’t be build, than there should be something related to current kernel you are running, maybe it’s beta or not supported by r1soft. Try to update to latest stable kernel -> reboot -> install kernel-devel and kernel-header -> try building module.
If you don’t have modules installed, than we’ll have to install them, but first – let’s ensure that there are no packages for other kernels with:
# rpm -qa | grep -e kernel-headers -e kernel-devel
and if there are any, let’s remove them:
# rpm -e kernel-header-xxxxx.elx.x86_64 –nodeps
# rpm -e kernel-devel-xxxxx.elx.x86_64 –nodeps
Repeat for everything you find.
After this we are ready for install missing packages:
# yum install kernel-devel kernel-headers
Once this done, try to get r1soft kernel module with:
# r1soft-setup –get-module
If r1soft module still can’t be build, than there should be something related to current kernel you are running, maybe it’s beta or not supported by r1soft. Try to update to latest stable kernel -> reboot -> install kernel-devel and kernel-header -> try building module.
[Need assistance to fix this error or install tools? We’ll help you.]