在我的 Ubuntu 12.04 上,我将显示器连接到板载英特尔显卡。我想使用我的 ATI Radeon 6770 执行 OpenCL 任务(例如比特币挖矿)。
到目前为止,我还不知道如何让 ati 驱动程序工作。当调用“aticonfig --initial -f”时,它总是会写入一个新的 xorg.conf,忽略英特尔显卡。在启动时,只有当我将显示器连接到 ati 卡时,它才会工作。
因此我手动篡改了 xorg.conf 并得到了这个:
Section "ServerLayout"
Identifier "Default Monitor"
Screen 0 "myscreen" 0 0
Screen 1 "deadscreen" RightOf "myscreen"
EndSection
Section "Module"
EndSection
Section "Monitor"
Identifier "Default Monitor"
Option "VendorName" "Monitor Vendor"
Option "ModelName" "Monitor Name"
Option "DPMS" "true"
EndSection
Section "Monitor"
Identifier "null Monitor"
Option "Enable" "false"
EndSection
Section "Device"
Identifier "Intel Integrated Graphics"
Driver "intel"
BusID "PCI:0:2:0"
Screen 0
EndSection
Section "Device"
Identifier "aticonfig-Device[0]-0"
Driver "fglrx"
BusID "PCI:1:0:0"
Screen 1
EndSection
Section "Screen"
Identifier "myscreen"
Device "Intel Integrated Graphics"
Monitor "Default Monitor"
DefaultDepth 24
SubSection "Display"
Viewport 0 0
Depth 24
EndSubSection
EndSection
Section "Screen"
Identifier "deadscreen"
Device "aticonfig-Device[0]-0"
Monitor "null Monitor"
DefaultDepth 24
SubSection "Display"
Viewport 0 0
Depth 24
EndSubSection
EndSection
我认为这可能是正确的方法,因为我看到 X 尝试在 /var/log/Xorg.0.log 中启动这两个驱动程序。但是 fglrx 驱动程序似乎崩溃了(xorg.0.log 结尾):
Backtrace:
[ 6.625] 0: /usr/bin/X (xorg_backtrace+0x26) [0x7fb5cd41b846]
[ 6.625] 1: /usr/bin/X (0x7fb5cd293000+0x18c6ea) [0x7fb5cd41f6ea]
[ 6.625] 2: /lib/x86_64-linux-gnu/libpthread.so.0 (0x7fb5cc5b9000+0xfcb0) [0x7fb5cc5c8cb0]
[ 6.625] 3: /usr/lib/x86_64-linux-gnu/xorg/extra-modules/extra-modules.dpkg-tmp/modules/drivers/fglrx_drv.so (xdl_xs111_atiddxGetGPUMapInfo+0x1b1) [0x7fb5c88e16b1]
[ 6.625] 4: /usr/lib/x86_64-linux-gnu/xorg/extra-modules/extra-modules.dpkg-tmp/modules/drivers/fglrx_drv.so (atiddxGetGPUMapInfo+0xd) [0x7fb5c87bcc0d]
[ 6.625] 5: /usr/lib/x86_64-linux-gnu/xorg/extra-modules/extra-modules.dpkg-tmp/modules/extensions/libglx.so (0x7fb5ca12d000+0x1ab29) [0x7fb5ca147b29]
[ 6.625] 6: /usr/lib/x86_64-linux-gnu/xorg/extra-modules/extra-modules.dpkg-tmp/modules/extensions/libglx.so (0x7fb5ca12d000+0x1cf8c) [0x7fb5ca149f8c]
[ 6.625] 7: /usr/lib/x86_64-linux-gnu/xorg/extra-modules/extra-modules.dpkg-tmp/modules/extensions/libglx.so (0x7fb5ca12d000+0x1ee55) [0x7fb5ca14be55]
[ 6.626] 8: /usr/bin/X (InitExtensions+0x99) [0x7fb5cd350069]
[ 6.626] 9: /usr/bin/X (0x7fb5cd293000+0x3d605) [0x7fb5cd2d0605]
[ 6.626] 10: /lib/x86_64-linux-gnu/libc.so.6 (__libc_start_main+0xed) [0x7fb5cb44e76d]
[ 6.626] 11: /usr/bin/X (0x7fb5cd293000+0x3daad) [0x7fb5cd2d0aad]
[ 6.626] Segmentation fault at address 0x14
[ 6.626]
Caught signal 11 (Segmentation fault). Server aborting
[ 6.626]
如果有人能提示我如何在使用集成显卡进行显示的同时配置 ATI 卡,我会非常高兴。
更新
我使用了大部分 jjhughes57 配置并成功启动了英特尔上的 X 服务器(不过有趣的是,键盘布局发生了变化)。
不幸的是,第二个 X 服务器 (fglrx) 无法完全启动。它在启动后立即关闭>
[ 6.265] (II) fglrx(0): Restoring Recent Mode via PCS is not supported in RANDR 1.2 capable environments
[ 6.296] (II) UnloadModule: "mouse"
[ 6.296] (II) Unloading mouse
[ 6.296] (II) UnloadModule: "kbd"
[ 6.296] (II) Unloading kbd
[ 6.298] (II) fglrx(0): Shutdown CMMQS
[ 6.298] (II) fglrx(0): [uki] removed 1 reserved context for kernel
[ 6.298] (II) fglrx(0): [uki] unmapping 8192 bytes of SAREA 0x2000 at 0x7fbef8209000
[ 6.337] (II) fglrx(0): Interrupt handler Shutdown.
[ 6.470] ddxSigGiveUp: Closing log
[ 6.470] Server terminated successfully (0). Closing log file.
谢谢大家对这里出了什么问题的提示。
解决方案
就我而言,解决方案非常简单。主要是 xorg.conf(来自 jjhughes57)让我走上了正确的道路。其余问题可以在 /etc/lightdm/lightdm.conf 中修复。我的最终版本是:
[LightDM]
seats=Seat:0 Seat:1
[SeatDefaults]
autologin-user-timeout=0
autologin-session=lightdm-autologin
greeter-session=lightdm-gtk-greeter
[Seat: 0]
xserver-layout=seat0
xserver-command=/usr/bin/X :0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -sharevts -novtswitch
autologin-guest=false
autologin-user=fx
autologin-user-timeout=0
autologin-session=lightdm-autologin
user-session=ubuntu
[Seat: 1]
xserver-layout=seat1
xserver-command=/usr/bin/X :1 -auth /var/run/lightdm/root/:1 -nolisten tcp vt8 -sharevts -novtswitch
autologin-guest=true
user-session=ubuntu
一个问题是缺少“/usr/share/xgreeters/lightdm-gtk-greeter.desktop”。再次正确安装 lightdm-gtk-greeter 后,第二个 X-server 成功启动。现在需要满足以下要求:
- X 需要接受 :1 上的连接(假设 :1 是您的
- fglrx-display) 您的用户需要权限才能在 :1 上打开 X-clients
实际上,我首先尝试使用 autologin-guest=false,但没有成功。使用 autologin-guest=true 和正在运行的用户会话(作为来宾用户),您需要禁用 X 访问控制(至少这是最简单的方法)。例如:在显示器 :0 上以 root 身份:
# su - guest-6ht0hq
guest-6ht0hq$ echo $DISPLAY
:0.0
guest-6ht0hq$ export DISPLAY=:1
guest-6ht0hq$ xhost +
access control disabled, clients can connect from any host
guest-6ht0hq$
现在在另一个终端上(以 root 身份):
# DISPLAY=:1.0 aticonfig --adapter=0 --od-getclocks
Adapter 0 - AMD Radeon HD 6700 Series
Core (MHz) Memory (MHz)
Current Clocks : 850 1000
Current Peak : 850 1000
Configurable Peak Range : [500-970] [1000-1430]
GPU load : 0%
#
答案1
所以我离解决这个问题已经很近了。我的基本想法是多座席会话。这允许 ATI 卡拥有自己的 X 会话,允许 Intel 显示器拥有自己的 X 会话。
- 确保 PCIE 是系统的默认显示器,但您的板载 GPU 已在系统 BIOS 中启用
- 修改我们的 /etc/X11/xorg.conf 使其看起来像这样...
Section "ServerLayout"
Identifier "seat0"
Screen 0 "My screen 1" 0 0
Option "Clone" "off"
Option "AutoAddDevices" "off"
Option "DisableModInDev" "true"
Option "SingleCard" "on" # use this to simplfied isolatedevice option
Option "AllowEmptyInput" "true"
EndSection
Section "ServerLayout"
Identifier "seat1"
Screen "aticonfig-Screen[0]-0" 0 0
Option "Clone" "off"
Option "AutoAddDevices" "off"
Option "DisableModInDev" "true"
Option "SingleCard" "on" # use this to simplfied isolatedevice option
Option "AllowEmptyInput" "true"
EndSection
Section "Module"
EndSection
Section "InputClass"
Identifier "Ignore Streamzap IR"
MatchProduct "Streamzap"
MatchIsKeyboard "yes"
Option "Ignore" "true"
EndSection
Section "Monitor"
Identifier "aticonfig-Monitor[0]-0"
Option "VendorName" "ATI Proprietary Driver"
Option "ModelName" "Generic Autodetecting Monitor"
Option "DPMS" "true"
EndSection
Section "Device"
Identifier "aticonfig-Device[0]-0"
Driver "fglrx"
Option "Capabilities" "0x00000800"
BusID "PCI:1:0:0"
EndSection
Section "Screen"
Identifier "aticonfig-Screen[0]-0"
Device "aticonfig-Device[0]-0"
Monitor "aticonfig-Monitor[0]-0"
DefaultDepth 24
SubSection "Display"
Viewport 0 0
Depth 24
EndSubSection
EndSection
Section "Monitor"
Identifier "My monitor 1"
EndSection
Section "Device"
Identifier "Sandybridge"
Driver "intel"
BusID "PCI:0:2:0"
EndSection
Section "Screen"
Identifier "My screen 1"
Device "Sandybridge"
Monitor "My monitor 1"
DefaultDepth 24
SubSection "Display"
Depth 24
Modes "1280x720"
EndSubSection
EndSection
- 最后我必须编辑 /etc/lightdm/lightdm.conf
[LightDM]
seats=Seat:0 Seat:1
[SeatDefaults]
autologin-user-timeout=0
autologin-session=lightdm-autologin
greeter-session=lightdm-gtk-greeter
[Seat: 0]
xserver-layout=seat0
xserver-command=/usr/bin/X :0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -sharevts -novtswitch
autologin-guest=false
autologin-user=joe
autologin-user-timeout=0
autologin-session=lightdm-autologin
greeter-session=lightdm-gtk-greeter
user-session=mythbuntu
[Seat: 1]
xserver-layout=seat1
xserver-command=/usr/bin/X :1 -auth /var/run/lightdm/root/:1 -nolisten tcp vt8 -sharevts -novtswitch
我现在正在启动两个显示器。我遇到了问题
sudo aticonfig --adapter=0 --od-getclocks
工作...但这会让你摆脱当前的错误。
答案2
您需要将显示器连接到卡上,或者连接假插头否则,显卡会假装没电。如果您的显示器有两个接口,您可以只将其中一个连接到显卡,而不使用该输入。