{"id":1812,"date":"2022-12-21T14:27:48","date_gmt":"2022-12-21T06:27:48","guid":{"rendered":"https:\/\/qishiya.com\/?p=1812"},"modified":"2022-12-21T14:27:49","modified_gmt":"2022-12-21T06:27:49","slug":"centos-8-%e5%ae%89%e8%a3%85-nvidia-%e6%98%be%e5%8d%a1%e9%a9%b1%e5%8a%a8","status":"publish","type":"post","link":"https:\/\/qishiya.com\/?p=1812","title":{"rendered":"<strong>Centos 8 \u5b89\u88c5 Nvidia \u663e\u5361\u9a71\u52a8<\/strong>"},"content":{"rendered":"\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_61 counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title \" >\u76ee\u5f55<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #ff6200;color:#ff6200\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #ff6200;color:#ff6200\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/qishiya.com\/?p=1812\/#%E6%9F%A5%E7%9C%8B%E6%98%BE%E5%8D%A1\" title=\"\u67e5\u770b\u663e\u5361\">\u67e5\u770b\u663e\u5361<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/qishiya.com\/?p=1812\/#%E4%B8%8B%E8%BD%BD%E6%98%BE%E5%8D%A1%E9%A9%B1%E5%8A%A8\" title=\"\u4e0b\u8f7d\u663e\u5361\u9a71\u52a8\">\u4e0b\u8f7d\u663e\u5361\u9a71\u52a8<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/qishiya.com\/?p=1812\/#%E5%AE%89%E8%A3%85%E4%BE%9D%E8%B5%96\" title=\"\u5b89\u88c5\u4f9d\u8d56\">\u5b89\u88c5\u4f9d\u8d56<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/qishiya.com\/?p=1812\/#%E7%A6%81%E6%AD%A2%E9%BB%98%E8%AE%A4%E6%98%BE%E5%8D%A1%E9%A9%B1%E5%8A%A8\" title=\"\u7981\u6b62\u9ed8\u8ba4\u663e\u5361\u9a71\u52a8\">\u7981\u6b62\u9ed8\u8ba4\u663e\u5361\u9a71\u52a8<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/qishiya.com\/?p=1812\/#%E6%9F%A5%E7%9C%8B%E7%A6%81%E6%AD%A2%E6%98%AF%E5%90%A6%E7%94%9F%E6%95%88\" title=\"\u67e5\u770b\u7981\u6b62\u662f\u5426\u751f\u6548\">\u67e5\u770b\u7981\u6b62\u662f\u5426\u751f\u6548<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/qishiya.com\/?p=1812\/#%E9%87%8D%E5%90%AF\" title=\"\u91cd\u542f\">\u91cd\u542f<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/qishiya.com\/?p=1812\/#%E5%AE%89%E8%A3%85%E5%86%85%E6%A0%B8%E5%BC%80%E5%8F%91%E6%96%87%E4%BB%B6\" title=\"\u5b89\u88c5\u5185\u6838\u5f00\u53d1\u6587\u4ef6\">\u5b89\u88c5\u5185\u6838\u5f00\u53d1\u6587\u4ef6<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/qishiya.com\/?p=1812\/#%E6%9B%B4%E6%96%B0%E4%BE%9D%E8%B5%96\" title=\"\u66f4\u65b0\u4f9d\u8d56\">\u66f4\u65b0\u4f9d\u8d56<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/qishiya.com\/?p=1812\/#%E5%AE%89%E8%A3%85%E9%A9%B1%E5%8A%A8\" title=\"\u5b89\u88c5\u9a71\u52a8\">\u5b89\u88c5\u9a71\u52a8<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/qishiya.com\/?p=1812\/#%E6%B3%A8%E6%84%8F\" title=\"\u6ce8\u610f\">\u6ce8\u610f<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-11\" href=\"https:\/\/qishiya.com\/?p=1812\/#%E5%8F%82%E8%80%83\" title=\"\u53c2\u8003\">\u53c2\u8003<\/a><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E6%9F%A5%E7%9C%8B%E6%98%BE%E5%8D%A1\"><\/span>\u67e5\u770b\u663e\u5361<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code> lspci | grep -i vga<\/code><\/pre>\n\n\n\n<p>\u6211\u7684\u663e\u5361\u662f<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>00:10.0 VGA compatible controller: NVIDIA Corporation GA106 &#91;GeForce RTX 3060] (rev a1)<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E4%B8%8B%E8%BD%BD%E6%98%BE%E5%8D%A1%E9%A9%B1%E5%8A%A8\"><\/span>\u4e0b\u8f7d\u663e\u5361\u9a71\u52a8<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>\u53bb Nvidia \u5b98\u7f51\u4e0b\u8f7d(\u4ee53060\u4e3a\u4f8b\uff0c\u53ef\u4ee5\u5728\u5b98\u7f51\u627e\u5230\u5404\u4e2a\u663e\u5361\u578b\u53f7\u7684\u9a71\u52a8)<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>wget https:\/\/us.download.nvidia.com\/XFree86\/Linux-x86_64\/525.60.11\/NVIDIA-Linux-x86_64-525.60.11.run<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E5%AE%89%E8%A3%85%E4%BE%9D%E8%B5%96\"><\/span>\u5b89\u88c5\u4f9d\u8d56<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>\u6211\u4e00\u822c\u5b89\u88c5\u5f00\u53d1\u5de5\u5177\u96c6\u6210\uff0c\u8fd9\u6837\u53ef\u4ee5\u7701\u5f88\u591a\u65f6\u95f4\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>dnf groupinstall \"Development Tools\"\ndnf install libglvnd-devel elfutils-libelf-devel<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E7%A6%81%E6%AD%A2%E9%BB%98%E8%AE%A4%E6%98%BE%E5%8D%A1%E9%A9%B1%E5%8A%A8\"><\/span>\u7981\u6b62\u9ed8\u8ba4\u663e\u5361\u9a71\u52a8<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>grub2-editenv - set \"$(grub2-editenv - list | grep kernelopts) nouveau.modeset=0\"<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E6%9F%A5%E7%9C%8B%E7%A6%81%E6%AD%A2%E6%98%AF%E5%90%A6%E7%94%9F%E6%95%88\"><\/span>\u67e5\u770b\u7981\u6b62\u662f\u5426\u751f\u6548<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>\u8f93\u5165\u53ef\u4ee5\u770b\u5230\u663e\u5361\u9a71\u52a8\u7c7b\u578b<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>lspci -k | grep -EA3 'VGA|3D|Display'<\/code><\/pre>\n\n\n\n<p>\u67e5\u770b\u5730 nouveau \u662f\u5426\u7981\u6b62<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>grub2-editenv - list | grep kernelopts<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E9%87%8D%E5%90%AF\"><\/span>\u91cd\u542f<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>reboot<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E5%AE%89%E8%A3%85%E5%86%85%E6%A0%B8%E5%BC%80%E5%8F%91%E6%96%87%E4%BB%B6\"><\/span>\u5b89\u88c5\u5185\u6838\u5f00\u53d1\u6587\u4ef6<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>dnf install kernel-headers\ndnf install kernel-devel\ndnf distro-sync<\/code><\/pre>\n\n\n\n<p>\u67e5\u770b\u5185\u6838\u5f00\u53d1\u6587\u4ef6\u662f\u5426\u751f\u6548<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>rpm -qa | grep -E \"kernel-devel|kernel-headers\"<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E6%9B%B4%E6%96%B0%E4%BE%9D%E8%B5%96\"><\/span>\u66f4\u65b0\u4f9d\u8d56<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>dnf distro-sync<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E5%AE%89%E8%A3%85%E9%A9%B1%E5%8A%A8\"><\/span>\u5b89\u88c5\u9a71\u52a8<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>sh NVIDIA-Linux-x86_64-525.60.11.run<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E6%B3%A8%E6%84%8F\"><\/span>\u6ce8\u610f<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<ol class=\"wp-block-list\">\n<li>\u663e\u5361\u9a71\u52a8\u548c CUDA \u662f\u4e24\u4e2a\u4e0d\u540c\u7684\u5305\uff0c\u5b89\u88c5\u4e86\u663e\u5361\u9a71\u52a8\u5c31\u8981\u4ee5\u7528\u663e\u5361\u4e86\u3002<\/li>\n\n\n\n<li>CUDA \u662f\u4e00\u4e2a\u57fa\u4e8e\u663e\u5361\u7684\u8ba1\u7b97\u5e93\u3002<\/li>\n\n\n\n<li>\u5982\u679c\u662f\u901a\u8fc7 conda \uff0c\u53ef\u4ee5\u4e0d\u5b89\u88c5CUDA\uff0c\u901a\u8fc7 conda \u4e5f\u53ef\u4ee5\u5b89\u88c5CUDA\u3002<\/li>\n<\/ol>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E5%8F%82%E8%80%83\"><\/span>\u53c2\u8003<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p><a href=\"https:\/\/linuxconfig.org\/how-to-install-the-nvidia-drivers-on-centos-8\">How to install the NVIDIA drivers on CentOS 8 &#8211; Linux Tutorials &#8211; Learn Linux Configuration<\/a><\/p>\n\n\n\n<p><a href=\"https:\/\/linuxconfig.org\/error-unable-to-find-the-kernel-source-tree-for-the-currently-running-kernel-centos-rhel\">ERROR: Unable to find the kernel source tree for the currently running kernel &#8211; CentOS \/ RHEL \/ AlmaLinux &#8211; Linux Tutorials &#8211; Learn Linux Configuration<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u67e5\u770b\u663e\u5361 \u6211\u7684\u663e\u5361\u662f \u4e0b\u8f7d\u663e\u5361\u9a71\u52a8 \u53bb Nvidia \u5b98\u7f51\u4e0b\u8f7d(\u4ee53060\u4e3a\u4f8b\uff0c\u53ef\u4ee5\u5728\u5b98\u7f51\u627e\u5230\u5404\u4e2a\u663e\u5361\u578b\u53f7\u7684\u9a71\u52a8) \u5b89\u88c5\u4f9d\u8d56 \u6211\u4e00\u822c\u5b89\u88c5\u5f00\u53d1\u5de5\u5177\u96c6\u6210\uff0c\u8fd9\u6837\u53ef\u4ee5\u7701\u5f88\u591a\u65f6\u95f4\u3002 \u7981\u6b62\u9ed8\u8ba4\u663e\u5361\u9a71\u52a8 \u67e5\u770b\u7981\u6b62\u662f\u5426\u751f\u6548 \u8f93\u5165\u53ef\u4ee5\u770b\u5230\u663e\u5361\u9a71\u52a8\u7c7b\u578b \u67e5\u770b\u5730 &#8230; <a title=\"Centos 8 \u5b89\u88c5 Nvidia \u663e\u5361\u9a71\u52a8\" class=\"read-more\" href=\"https:\/\/qishiya.com\/?p=1812\" aria-label=\"\u66f4\u591a Centos 8 \u5b89\u88c5 Nvidia \u663e\u5361\u9a71\u52a8\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"templates\/template-full-width.php","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[587,434,586,584,585],"class_list":["post-1812","post","type-post","status-publish","format-standard","hentry","category-5","tag-587","tag-centos8","tag-cuda","tag-nvidia","tag-585"],"_links":{"self":[{"href":"https:\/\/qishiya.com\/index.php?rest_route=\/wp\/v2\/posts\/1812","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/qishiya.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/qishiya.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/qishiya.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/qishiya.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1812"}],"version-history":[{"count":1,"href":"https:\/\/qishiya.com\/index.php?rest_route=\/wp\/v2\/posts\/1812\/revisions"}],"predecessor-version":[{"id":1813,"href":"https:\/\/qishiya.com\/index.php?rest_route=\/wp\/v2\/posts\/1812\/revisions\/1813"}],"wp:attachment":[{"href":"https:\/\/qishiya.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1812"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/qishiya.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1812"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/qishiya.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1812"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}