举报
PVE开启intel 11代和12代gpu的sriov教程
2022-10-15 14:00:39
4026次阅读
1个评论
首要条件:
系统要求PVE 7, 内核版本5.19以上。
一、安装5.19内核以及linux-header
1、安装linux-header
apt update && apt install pve-headers-5.19.7-2-pve -y
2、安装5.19内核
apt install pve-kernel-5.19.7-2-pve
二、安装dkms
apt install dkms -y
1、tar -xvf i915-sriov-dkms.tar
2、mv i915-sriov-dkms /usr/src
四、dkms安装i915
1、dkms install -m i915-sriov -v dkms
2、检查一下有没有成功
dkms status
正常输出如下
i915-sriov, dkms, 5.19.7-2-pve, x86_64: installed
五、修改内核参数
UEFI如下修改
找到 /etc/kernel/cmdline 添加 intel_iommu=on i915.enable_guc=7
如果intel_iommu=on 已经配置了就不需要了
更新内核initramfs
update-initramfs -u -k all
pve-efiboot-tool refresh
grub启动的,自行百度
六、安装sysfsutils
这个工具方便配置sys的参数
apt install sysfsutils -y
添加开启vf的参数
echo "devices/pci0000:00/0000:00:02.0/sriov_numvfs = 7" > /etc/sysfs.conf
七、检查系统是否有12代的i915的firmware
ls /lib/firmware/i915/tgl_guc_70.1.1.bin
如果不存在就执行下载
wget -P /lib/firmware/i915 https://git.kernel.org/pub/scm/l ... /tgl_guc_70.1.1.bin
11代的自行去找
https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/plain/i915/
八、重启电脑检查
dmesg | grep vf
[ 5.004817] RAPL PMU: API unit is 2^-32 Joules, 3 fixed counters, 655360 ms ovfl timer
[ 5.238952] i915 0000:00:02.0: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 5.238957] i915 0000:00:02.0: pf_verify_readiness: pf_reduce_totalvfs
[ 6.424895] i915 0000:00:02.1: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.431447] i915 0000:00:02.2: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.436964] i915 0000:00:02.3: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.442156] i915 0000:00:02.4: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.446980] i915 0000:00:02.5: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.451589] i915 0000:00:02.6: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.455795] i915 0000:00:02.7: i915_sriov_probe: gen12_pci_capability_is_vf in
如上输出就正常了
可以去界面配置直通
若没有
dmesg | grep -i guc
[ 4.112232] i915 0000:00:02.0: Direct firmware load for i915/tgl_guc_70.1.1.bin failed with error -2
[ 4.112236] i915 0000:00:02.0: [drm] GuC firmware i915/tgl_guc_70.1.1.bin: fetch failed with error -2
[ 4.205493] i915 0000:00:02.0: GuC initialization failed -2
输出类似上面的,说明firmware文件缺少对应的文件,直接按7去执行,再重启就OK
系统要求PVE 7, 内核版本5.19以上。
一、安装5.19内核以及linux-header
1、安装linux-header
apt update && apt install pve-headers-5.19.7-2-pve -y
2、安装5.19内核
apt install pve-kernel-5.19.7-2-pve
二、安装dkms
apt install dkms -y
三、下载i915-sriov-dkms.tar
链接:https://pan.baidu.com/s/1f97tgQacFl85vP8aKCc1ew?pwd=gxmg 提取码:gxmg 复制这段内容后打开百度网盘手机App,操作更方便哦
参考了
https://github.com/strongtz/i915-sriov-dkms
1、tar -xvf i915-sriov-dkms.tar
2、mv i915-sriov-dkms /usr/src
四、dkms安装i915
1、dkms install -m i915-sriov -v dkms
2、检查一下有没有成功
dkms status
正常输出如下
i915-sriov, dkms, 5.19.7-2-pve, x86_64: installed
五、修改内核参数
UEFI如下修改
找到 /etc/kernel/cmdline 添加 intel_iommu=on i915.enable_guc=7
如果intel_iommu=on 已经配置了就不需要了
更新内核initramfs
update-initramfs -u -k all
pve-efiboot-tool refresh
grub启动的,自行百度
六、安装sysfsutils
这个工具方便配置sys的参数
apt install sysfsutils -y
添加开启vf的参数
echo "devices/pci0000:00/0000:00:02.0/sriov_numvfs = 7" > /etc/sysfs.conf
七、检查系统是否有12代的i915的firmware
ls /lib/firmware/i915/tgl_guc_70.1.1.bin
如果不存在就执行下载
wget -P /lib/firmware/i915 https://git.kernel.org/pub/scm/l ... /tgl_guc_70.1.1.bin
11代的自行去找
https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/plain/i915/
八、重启电脑检查
dmesg | grep vf
[ 5.004817] RAPL PMU: API unit is 2^-32 Joules, 3 fixed counters, 655360 ms ovfl timer
[ 5.238952] i915 0000:00:02.0: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 5.238957] i915 0000:00:02.0: pf_verify_readiness: pf_reduce_totalvfs
[ 6.424895] i915 0000:00:02.1: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.431447] i915 0000:00:02.2: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.436964] i915 0000:00:02.3: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.442156] i915 0000:00:02.4: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.446980] i915 0000:00:02.5: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.451589] i915 0000:00:02.6: i915_sriov_probe: gen12_pci_capability_is_vf in
[ 6.455795] i915 0000:00:02.7: i915_sriov_probe: gen12_pci_capability_is_vf in
如上输出就正常了
可以去界面配置直通
若没有
dmesg | grep -i guc
[ 4.112232] i915 0000:00:02.0: Direct firmware load for i915/tgl_guc_70.1.1.bin failed with error -2
[ 4.112236] i915 0000:00:02.0: [drm] GuC firmware i915/tgl_guc_70.1.1.bin: fetch failed with error -2
[ 4.205493] i915 0000:00:02.0: GuC initialization failed -2
输出类似上面的,说明firmware文件缺少对应的文件,直接按7去执行,再重启就OK
源贴地址:https://www.right.com.cn/forum/thread-8258222-1-1.html
0
0
2022-10-16 15:36:31
AMD机器上可以用吗
共1条
1