深度linux deepin双屏,deepin nvidia 双显卡 双屏

其实跟双屏没太多联系,不过建议单屏完成操作

用 deepin 有挺久了,一直没怎么注意驱动,前几天突然想玩玩 流星蝴蝶剑  ,之前没搞成功也不知道怎么回事也没时间没注意,大晚上想起来买了 crossover 就突然来劲了(冰封王座进去也很卡也是驱动问题),然后尝试了 驱动管理,不顶用,更了 15.11 之后好像就不得行了,之前尝试去 NVIDIA 下载 linux 的 run驱动包,没装成功。

折腾到今天傍晚才弄好,稍微总结和写个流程。

如果您在参考此文,开始动手前请注意:

安装NVIDIA驱动需要关闭开源驱动 nouveau

安装NVIDIA驱动需要关闭图形化服务 x server

安装NVIDIA驱动需要常用的编译环境

安装run包的驱动,需要卸载所有deb包

安装deb包最好先卸载一次之前的驱动

部分deb源可能不适于deepin 15.11

部分命令总结:

#查看电脑中的显卡

sudo lspci | egrep '3D|VGA'

#查看 nouveau 是否已关闭

sudo lsmod | grep nouveau

#卸载所有apt管理的关于NVIDIA驱动deb包

sudo apt purge *nvidia *nvidia* nvidia* -y

#安装编译环境

sudo apt -y install linux-headers-amd64 linux-headers-deepin-amd64 gcc make dkms

#安装run包之前停止 x server,启动改为start

#ctrl+alt+F2 进入tty2之后

sudo service lightdm stop

#NVIDIA的部分命令

#生成xorg.conf (实际可能不顶用)

sudo nvidia-xconfig

#查看显卡相关信息

nvidia-smi

#打开显卡面板

nvidia-settings

深度论坛相关教程地址:

安装完成之后,当你的 nvidia-smi 有输出内容之后,此时可能出现若干问题,包括不限于:

输入 nvidia-smi 不正常:

1、nvidia-smi 没有安装(常见于apt安装方式):使用 apt install nvidia-smi

2、nvidia-smi 存在,但是输出内容不正常:通常是驱动安装失败,参考屏幕提示,或者查看 /var/log/nvidia-install.log

输入 nvidia-smi 正常,但是打开面板报错,没有弹出面板

输入 nvidia-smi 正常,但是打开面板提示缺少 /etc/X11/xorg.conf ,请使用 nvidia-xconfig 生成配置文件

以上两个基本上都是 /etc/X11/xorg.conf 配置文件有问题,用 nvidia-xconfig 生成的配置文件不顶用(不过还是可以试试),不记得是哪里找到的一个有人贴出来的配置文件,可以用了,内容如下:

Section "ServerLayout"

Identifier      "X.org Configured"

Screen          0  "screen_nvidia"

Inactive        "card_intel"

InputDevice     "Mouse0" "CorePointer"

InputDevice     "Keyboard0" "CoreKeyboard"

EndSection

Section "Files"

ModulePath   "/usr/lib/xorg/modules"

FontPath     "/usr/share/fonts/X11/misc"

FontPath     "/usr/share/fonts/X11/cyrillic"

FontPath     "/usr/share/fonts/X11/100dpi/:unscaled"

FontPath     "/usr/share/fonts/X11/75dpi/:unscaled"

FontPath     "/usr/share/fonts/X11/Type1"

FontPath     "/usr/share/fonts/X11/100dpi"

FontPath     "/usr/share/fonts/X11/75dpi"

FontPath     "built-ins"

EndSection

Section "Module"

Load  "glx"

EndSection

Section "InputDevice"

Identifier  "Keyboard0"

Driver      "kbd"

EndSection

Section "InputDevice"

Identifier  "Mouse0"

Driver      "mouse"

Option      "Protocol" "auto"

Option      "Device" "/dev/input/mice"

Option      "ZAxisMapping" "4 5 6 7"

EndSection

Section "Device"

Identifier  "card_nvidia"

Driver      "nvidia"

BusID       "PCI:1:0:0"

EndSection

Section "Device"

Identifier  "card_intel"

Driver      "modesetting"

BusID       "PCI:0:2:0"

EndSection

Section "Screen"

Identifier "screen_nvidia"

Device     "card_nvidia"

EndSection

Section "Screen"

Identifier "screen_intel"

Device     "card_intel"

EndSection

刚又测试了一下,需要在 /etc/lightdm/lightdm.conf的 [Seat:*] 行下添加

display-setup-script=/etc/lightdm/display_setup.sh

/etc/lightdm/display_setup.sh 的内容是:

#!/bin/sh

xrandr --setprovideroutputsource modesetting NVIDIA-0

xrandr --auto

xrandr --dpi 96

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值