iis服务器助手广告广告
返回顶部
首页 > 资讯 > 服务器 >PVE配置GPU显卡直通(亲测可用)
  • 336
分享到

PVE配置GPU显卡直通(亲测可用)

linux服务器运维网络 2023-08-20 14:08:44 336人浏览 泡泡鱼
摘要

PVE配置GPU显卡直通(亲测可用) 进入网址 2.输入用户名密码 点击local上传镜像 进入命令行模式 shell 换源 apt install apt-transport-https ca-certificates nano

PVE配置GPU显卡直通(亲测可用)

进入网址
2.输入用户名密码
请添加图片描述

点击local上传镜像
请添加图片描述
请添加图片描述

进入命令行模式 shell
请添加图片描述

换源

apt install apt-transport-https ca-certificates nano /etc/apt/sources.list

保存并替换如下内容:

# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释deb Https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-free# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-freedeb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-free# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-freedeb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-backports main contrib non-free# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-backports main contrib non-freedeb https://mirrors.tuna.tsinghua.edu.cn/debian-security bullseye-security main contrib non-free# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian-security bullseye-security main contrib non-free

保存并退出,输入以下命令

nano /etc/apt/sources.list.d/pve-enterprise.list

用以下内容替换原代码并保存退出

deb https://mirrors.tuna.tsinghua.edu.cn/proxmox/debian bullseye pve-no-subscription

更新源文件

apt-get update

配置显卡直通

nano /etc/default/grub

其中一行是GRUB_CMDLINE_linux_DEFAULT="quiet“,修改这一行为如下内容,保存并退出

GRUB_CMDLINE_LINUX_DEFAULT="quiet intel_iommu=on iommu=pt video=efifb:off "

使用以下命令打开要修改的文件

nano /etc/modules

添加如下内容

vfiovfio_iommu_type1vfio_pcivfio_virqfd

保存退出后更新服务

update-initramfs -uupdate-grub

然后重启pve系统

reboot

创建虚拟机
自己命名虚拟机名称
请添加图片描述
选择之前上传的镜像文件
请添加图片描述
机型选择q35并开启Qemu代理
请添加图片描述
分配磁盘大小
请添加图片描述
配置CPU核心数,按照自己物理机的CPU进行分配
请添加图片描述
配置虚拟机内存,物理为32GB,这里给分配了24X1024MB的内存容量
请添加图片描述
一定要取消勾选防火墙选项
请添加图片描述
确认安装
8.添加显卡设备
请添加图片描述
在PCI设备中找到自己的GPU设备型号
请添加图片描述
然后勾选所有功能、ROM-Bar、PCI-Express复选框,点击添加
请添加图片描述

打开虚拟机正常换源装显卡驱动
10.重启后使用终端命令nvidia-smi测试显卡是否正常
11.添加虚拟网卡(非必要)
请添加图片描述
添加后在虚拟机的硬件中添加
请添加图片描述

来源地址:https://blog.csdn.net/yyhyoung/article/details/130708894

--结束END--

本文标题: PVE配置GPU显卡直通(亲测可用)

本文链接: https://www.lsjlt.com/news/376469.html(转载时请注明来源链接)

有问题或投稿请发送至: 邮箱/279061341@qq.com    QQ/279061341

本篇文章演示代码以及资料文档资料下载

下载Word文档到电脑,方便收藏和打印~

下载Word文档
猜你喜欢
软考高级职称资格查询
编程网,编程工程师的家园,是目前国内优秀的开源技术社区之一,形成了由开源软件库、代码分享、资讯、协作翻译、讨论区和博客等几大频道内容,为IT开发者提供了一个发现、使用、并交流开源技术的平台。
  • 官方手机版

  • 微信公众号

  • 商务合作