<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<atom:link href="https://www.gentoo-zh.org/extern.php?action=feed&amp;tid=618&amp;type=rss" rel="self" type="application/rss+xml" />
		<title><![CDATA[Gentoo中文社区 / Gentoo linux 配置nvidia显卡，安装timeshift，安装steam方法总结]]></title>
		<link>https://www.gentoo-zh.org/viewtopic.php?id=618</link>
		<description><![CDATA[Gentoo linux 配置nvidia显卡，安装timeshift，安装steam方法总结 最近发表的帖子。]]></description>
		<lastBuildDate>Mon, 12 Dec 2022 16:31:03 +0000</lastBuildDate>
		<generator>FluxBB</generator>
		<item>
			<title><![CDATA[Gentoo linux 配置nvidia显卡，安装timeshift，安装steam方法总结]]></title>
			<link>https://www.gentoo-zh.org/viewtopic.php?pid=661#p661</link>
			<description><![CDATA[<p>作者:semes 有疑问进群询问</p><p>参考了许多大佬的文章，还有gentoo官方的wiki，如果有哪位大佬看到文章里有你的内容，希望别生气哈</p><p>全过程root用户或者普通用户sudo，建立在gentoo已经安装完桌面的基础上，我就不讲gentoo整么安装了</p><p>gentoo linux安装nvidia（内核开始）：</p><p>获取内核源码</p><p>emerge --ask sys-kernel/gentoo-sources</p><p>eselect kernel list<br />eselect kernel set 1</p><p>（可选）安装genkennel配置内核 ##有时候nvidia安装不上和内核配置有关，他需要根据你的内核配置文件来编译模块，所以我用genkernel，会自己陪内核的还是自己来配置内核</p><p>emerge --ask sys-kernel/genkernel</p><p>cd /usr/src/linux</p><p>genkernel all</p><p>禁用nouveau</p><p>mkdir /etc/modprobe.d/</p><p>touch /etc/modprobe.d/blacklist.conf</p><p>nano /etc/modprobe.d/blacklist.conf</p><p>#加入这些begin</p><p>blacklist nouveau<br />blacklist lbm-nouveau<br />options nouveau modeset=0</p><p>#加入这些end</p><p>安装显卡驱动</p><p>nano /etc/portage/make.conf</p><p>#加入这些begin<br />VIDEO_CARDS=&quot;intel i965 iris nvidia&quot; #Intel UHD630和Nvidia双显卡</p><p>#加入这些end</p><p>emerge -av x11-base/xorg-server x11-apps/xrandr x11-base/xorg-drivers media-libs/mesa x11-drivers/nvidia-drivers</p><p>配置nvidia</p><p>nano /etc/modules-load.d/nvidia.conf</p><p>#加入这些begin<br />nvidia</p><p>#加入这些end</p><p>systemctl start systemd-modules-load.service</p><p>或者</p><p>rc-update add modules boot</p><br /><br /><p>nano /etc/modprobe.d/nvidia-drm.conf</p><p>#加入这些begin<br />options nvidia-drm modeset=1</p><p>#加入这些end</p><br /><br /><p>nano /etc/X11/xorg.conf</p><br /><br /><p>##############加入这些begin##############################<br /># nvidia-xconfig: X configuration file generated by nvidia-xconfig<br /># nvidia-xconfig: version 440.100</p><p>Section &quot;ServerLayout&quot;<br />Identifier &quot;Layout0&quot;<br />Screen 0 &quot;Screen0&quot;<br />Inactive &quot;InactiveDevice1&quot;<br />Option &quot;AllowNVIDIAGPUScreens&quot; &quot;true&quot;<br />Option &quot;AllowPRIMEDisplayOffloadSink&quot; &quot;true&quot;<br />EndSection</p><p>Section &quot;Files&quot;<br />EndSection</p><p>Section &quot;InputClass&quot;<br />Identifier &quot;libinput pointer catchall&quot;<br />Driver &quot;libinput&quot;<br />MatchIsPointer &quot;on&quot;<br />MatchDevicePath &quot;/dev/input/event*&quot;<br />Option &quot;AccelProfile&quot; &quot;flat&quot; #禁用鼠标加速，玩游戏必备<br />Option &quot;AccelSpeed&quot; &quot;0&quot;<br />EndSection</p><p>Section &quot;InputClass&quot;<br />Identifier &quot;libinput keyboard catchall&quot;<br />Driver &quot;libinput&quot;<br />MatchIsKeyboard &quot;on&quot;<br />MatchDevicePath &quot;/dev/input/event*&quot;<br />EndSection</p><p>Section &quot;InputClass&quot;<br />Identifier &quot;libinput touchpad catchall&quot;<br />Driver &quot;libinput&quot;<br />MatchIsTouchpad &quot;on&quot;<br />MatchDevicePath &quot;/dev/input/event*&quot;<br />option &quot;Tapping&quot; &quot;True&quot;<br />option &quot;TappingDrag&quot; &quot;True&quot;<br />option &quot;NaturalScrolling&quot; &quot;True&quot;<br />EndSection</p><p>Section &quot;Module&quot;<br />Load &quot;fb&quot;<br />Load &quot;shadow&quot;<br />Load &quot;exa&quot;<br />Load &quot;glamoregl&quot;<br />Load &quot;glx&quot;<br />Load &quot;dri3&quot;<br />EndSection</p><p>Section &quot;Monitor&quot;<br />Identifier &quot;Monitor0&quot;<br />VendorName &quot;Unknown&quot;<br />ModelName &quot;Unknown&quot;<br />Option &quot;DPMS&quot;<br />EndSection</p><p>Section &quot;Device&quot;<br />Identifier &quot;Device0&quot;<br />Driver &quot;nvidia&quot;<br />VendorName &quot;NVIDIA Corporation&quot;<br />BusID &quot;PCI:1:0:0&quot;<br />Option &quot;Accel&quot; &quot;true&quot;<br />Option &quot;RenderAccel&quot; &quot;true&quot;<br />Option &quot;NoFlip&quot; &quot;false&quot;<br />Option &quot;SWCursor&quot; &quot;false&quot;<br />Option &quot;HWCursor&quot; &quot;true&quot;<br />Option &quot;DamageEvents&quot; &quot;true&quot;<br />Option &quot;ModeDebug&quot; &quot;false&quot;<br />Option &quot;AllowSHMPixmaps&quot; &quot;false&quot;<br />Option &quot;SidebandSocketPath&quot; &quot;/tmp&quot;<br />Option &quot;UseSysmemPixmapAccel&quot; &quot;true&quot;<br />Option &quot;MultisampleCompatibility&quot; &quot;true&quot;<br />Option &quot;AllowEmptyInitialConfiguration&quot; &quot;true&quot;<br />Option &quot;ForceCompositionPipeline&quot; &quot;true&quot;<br />Option &quot;ForceFullCompositionPipeline&quot; &quot;true&quot; #大幅度减少屏幕画面撕裂tearing，类似于垂直同步Vsync<br />Option &quot;AllowIndirectGLXProtocol&quot; &quot;false&quot;<br />Option &quot;TripleBuffer&quot; &quot;true&quot; #开启三重缓冲、并配合CompositionPipeline，能明显提升桌面和3D游戏的流畅度和响应速度，并且浏览器加载页面的速度也明显的感觉快了很多<br />Option &quot;Stereo&quot; &quot;0&quot;<br />Option &quot;BaseMosaic&quot; &quot;false&quot;<br />Option &quot;MultiGPU&quot; &quot;false&quot;<br />Option &quot;SLI&quot; &quot;false&quot;<br />Option &quot;PrimaryGPU&quot; &quot;yes&quot;<br />EndSection</p><p>Section &quot;Device&quot;<br />Identifier &quot;InactiveDevice1&quot;<br />Driver &quot;modesetting&quot;<br />VendorName &quot;Unknown&quot;<br />Option &quot;AccelMethod&quot; &quot;glamor&quot;<br />Option &quot;DRI&quot; &quot;3&quot;<br />Option &quot;TearFree&quot; &quot;true&quot;<br />EndSection</p><p>Section &quot;Screen&quot;<br />Identifier &quot;Screen0&quot;<br />Device &quot;Device0&quot;<br />Monitor &quot;Monitor0&quot;<br />DefaultDepth 24<br />SubSection &quot;Display&quot;<br />Depth 24<br />EndSubSection<br />EndSection</p><p>Section &quot;Screen&quot;<br />Identifier &quot;Screen1&quot;<br />Device &quot;InactiveDevice1&quot;<br />EndSection</p><p>Section &quot;ServerFlags&quot;<br />Option &quot;DontVTSwitch&quot; &quot;True&quot;<br />Option &quot;DontZap&quot; &quot;True&quot;<br />EndSection</p><p>#############加入这些end###############</p><p>nano /usr/share/sddm/scripts/Xsetup</p><p>#加入这些begin</p><p>xrandr --setprovideroutputsource modesetting NVIDIA-0 #加入这一行<br />xrandr --auto #加入这一行</p><p>#加入这些end</p><p>chmod u+s /usr/bin/xinit</p><p>修改grub启动参数</p><p>nano /etc/default/grub</p><p>找到</p><p>#GRUB_CMDLINE_LINUX=&quot;&quot;</p><p>改为</p><p>GRUB_CMDLINE_LINUX=&quot;nvidia-drm.modeset=1&quot;</p><p>然后更新grub引导</p><p>grub-mkconfig -o /boot/grub/grub.cfg</p><p>#详细的intel&amp;nvidia双显卡****prime****设置可以参照这位大佬的文章——</p><p>gentoo linux配置intel和nvidia双显卡电脑，使用prime方案<br /><a href="http://www.jianshu.com/p/515a1f39b438" rel="nofollow">www.jianshu.com/p/515a1f39b438</a></p><p>换intel_GPU就改xorg.conf</p><p>把/etc/X11/xorg.conf的内容修改为：</p><p>##############################################################<br />Section &quot;ServerLayout&quot;<br />Identifier &quot;layout&quot;<br />Screen 0 &quot;iGPU&quot;<br />Option &quot;AllowNVIDIAGPUScreens&quot;<br />EndSection</p><p>Section &quot;Device&quot;<br />Identifier &quot;iGPU&quot;<br />Driver &quot;modesetting&quot;<br />BusID &quot;PCI:0:2:0&quot;<br />EndSection</p><p>Section &quot;Screen&quot;<br />Identifier &quot;iGPU&quot;<br />Device &quot;iGPU&quot;<br />EndSection</p><p>Section &quot;Device&quot;<br />Identifier &quot;nvidia&quot;<br />Driver &quot;nvidia&quot;<br />BusID &quot;PCI:1:0:0&quot;<br />EndSection<br />###################################################################</p><br /><br /><p>安装timshift备份软件</p><p>Gentoo Portage Overlays - News<br />gpo.zugaina.org/</p><p>emerge layman</p><p>layman -a guru</p><p>layman -s guru</p><p>nano /etc/portage/package.keywords</p><p>#加入这些begin</p><p>app-backup/timeshift</p><p>#加入这些end</p><p>emerge app-backup/timeshift --autounmask-write</p><p>etc-update --automode -3</p><p>emerge app-backup/timeshift</p><br /><br /><br /><br /><br /><br /><p>安装gentoo储存库的steam</p><p>nano /etc/portage/make.conf</p><p>#加入这些begin</p><p>USE=&quot; -gpm &quot; ##解决一个循环依赖问题，我遇到的大问题，后面才想到备份系统</p><p>#加入这些end</p><p>安装 app-eselect/eselect-repository和dev-vcs/git：</p><p>emerge --ask --noreplace app-eselect/eselect-repository dev-vcs/git</p><p>添加 Steam 存储库：</p><p>eselect repository enable steam-overlay</p><p>或者layman -a steam-overlay</p><p>然后与任一特定的 emaint 同步：</p><p>emaint sync -r steam-overlay</p><p>或</p><p>emerge --sync</p><p>或</p><p>layman -s steam-overlay</p><br /><br /><p>nano /etc/portage/package.accept_keywords/steam</p><p>#加入这些begin</p><p>*/*::steam-overlay</p><p>#加入这些end</p><p>nano /etc/portage/package.keywords</p><p>#加入这些begin</p><p>games-util/game-device-udev-rules</p><p>#加入这些end</p><p>emerge games-util/steam-launcher games-util/steam-meta --autounmask-write</p><p>etc-update --automode -3</p><p>emerge games-util/steam-launcher games-util/steam-meta<br />安装过程要把依赖gpm的程序程序编译大概30几个包</p><p>我在安装steam的时候跌了一脚，我把gpm卸载了，大家遇到循环依赖的时候，不要向我一样哈，这导致了第11次重新安装系统</p><br /><br /><p>编译完后重启gentoo steam就可以正常用了</p>]]></description>
			<author><![CDATA[dummy@example.com (batsom)]]></author>
			<pubDate>Mon, 12 Dec 2022 16:31:03 +0000</pubDate>
			<guid>https://www.gentoo-zh.org/viewtopic.php?pid=661#p661</guid>
		</item>
	</channel>
</rss>
