Your kernel headers for kernel 5.4.34-1-pve cannot be found

Globul

Member
Aug 6, 2020
38
0
11
48
Hi,

I try to install veeam backup linux agent and i have a problem with veeamsnap witch not correctly installed.
I want to execute this command :
Code:
sudo dkms build -m veeamsnap -v 4.0.1.2365

But the system return this answer :
Code:
Error! Your kernel headers for kernel 5.4.34-1-pve cannot be found.
Please install the linux-headers-5.4.34-1-pve package,
or use the --kernelsourcedir option to tell DKMS where it's located

I try this :

Code:
root@pve:~# apt update -y && apt upgrade -y && apt dist-upgrade
Hit:1 http://ftp.fr.debian.org/debian buster InRelease
Hit:2 http://ftp.fr.debian.org/debian buster-updates InRelease
Hit:3 http://security.debian.org buster/updates InRelease   
Hit:4 http://repository.veeam.com/backup/linux/agent/dpkg/debian/public stable InRelease
Hit:5 http://download.proxmox.com/debian/pve stretch InRelease
Reading package lists... Done         
Building dependency tree       
Reading state information... Done
All packages are up to date.
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
root@pve:~# uname -r
5.4.34-1-pve
root@pve:~# sudo apt-get install linux-headers-$(uname -r)
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package linux-headers-5.4.34-1-pve
E: Couldn't find any package by glob 'linux-headers-5.4.34-1-pve'
E: Couldn't find any package by regex 'linux-headers-5.4.34-1-pve'

Can someone help me ?
 
You have a stretch repository for pve but buster for everything else. That is probably the issue but more info is needed to fix it. What version of pve do you run? Please post the output of "pveversion -v" as well as your /etc/apt/sources.list and any files in /etc/apt/sources.list.d/.
 
You have a stretch repository for pve but buster for everything else. That is probably the issue but more info is needed to fix it. What version of pve do you run? Please post the output of "pveversion -v" as well as your /etc/apt/sources.list and any files in /etc/apt/sources.list.d/.


Hi, Thanks for your answer ...

Here are the informations you ask for :

I'm running this version of Proxmox :
Linux 5.4.34-1-pve #1 SMP PVE 5.4.34-2
pie-manager/6.2-4/982457a

Code:
root@pve:~# pveversion -v
proxmox-ve: 6.2-1 (running kernel: 5.4.34-1-pve)
pve-manager: 6.2-4 (running version: 6.2-4/9824574a)
pve-kernel-5.4: 6.2-1
pve-kernel-helper: 6.2-1
pve-kernel-5.4.34-1-pve: 5.4.34-2
ceph-fuse: 12.2.11+dfsg1-2.1+b1
corosync: 3.0.3-pve1
criu: 3.11-3
glusterfs-client: 5.5-3
ifupdown: 0.8.35+pve1
ksm-control-daemon: 1.3-1
libjs-extjs: 6.0.1-10
libknet1: 1.15-pve1
libproxmox-acme-perl: 1.0.3
libpve-access-control: 6.1-1
libpve-apiclient-perl: 3.0-3
libpve-common-perl: 6.1-2
libpve-guest-common-perl: 3.0-10
libpve-http-server-perl: 3.0-5
libpve-storage-perl: 6.1-7
libqb0: 1.0.5-1
libspice-server1: 0.14.2-4~pve6+1
lvm2: 2.03.02-pve4
lxc-pve: 4.0.2-1
lxcfs: 4.0.3-pve2
novnc-pve: 1.1.0-1
proxmox-mini-journalreader: 1.1-1
proxmox-widget-toolkit: 2.2-1
pve-cluster: 6.1-8
pve-container: 3.1-5
pve-docs: 6.2-4
pve-edk2-firmware: 2.20200229-1
pve-firewall: 4.1-2
pve-firmware: 3.1-1
pve-ha-manager: 3.0-9
pve-i18n: 2.1-2
pve-qemu-kvm: 5.0.0-2
pve-xtermjs: 4.3.0-1
qemu-server: 6.2-2
smartmontools: 7.1-pve2
spiceterm: 3.1-1
vncterm: 1.6-1
zfsutils-linux: 0.8.3-pve1

Code:
deb http://ftp.fr.debian.org/debian buster main contrib

deb http://ftp.fr.debian.org/debian buster-updates main contrib

# PVE pve-no-subscription repository provided by proxmox.com,
# NOT recommended for production use
deb http://download.proxmox.com/debian/pve stretch pve-no-subscription


# security updates
deb http://security.debian.org buster/updates main contrib

Code:
root@pve:/etc/apt/sources.list.d# ls
veeam.list
 
This line:
deb http://download.proxmox.com/debian/pve stretch pve-no-subscription

should be:
deb http://download.proxmox.com/debian/pve buster pve-no-subscription

Try making that change, then do "apt update" and "apt full-upgrade", then if everything works try to install the kernel headers.
 
This line:
deb http://download.proxmox.com/debian/pve stretch pve-no-subscription

should be:
deb http://download.proxmox.com/debian/pve buster pve-no-subscription

Try making that change, then do "apt update" and "apt full-upgrade", then if everything works try to install the kernel headers.


Thanks.

I've another problem, the kernel installed is 5.4.44-2 but veeamsnap need 5.4.34-1 to work apparently

Code:
root@pve:~# sudo dkms status
veeamsnap, 4.0.1.2365, 5.4.44-2-pve, x86_64: installed
root@pve:~# sudo modprobe veeamsnap
modprobe: FATAL: Module veeamsnap not found in directory /lib/modules/5.4.34-1-pve
root@pve:~# sudo dkms build -m veeamsnap -v 4.0.1.2365
Error! Your kernel headers for kernel 5.4.34-1-pve cannot be found.
Please install the linux-headers-5.4.34-1-pve package,
or use the --kernelsourcedir option to tell DKMS where it's located
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!