我最近在笔记本电脑上安装了 Ubuntu 18.04 和 Windows 10。不幸的是,连接到 HDMI-1 的外接显示器无法在 Ubuntu 上运行(未检测到)。我几乎尝试了所有方法这里和这里. 它与HDMI 转 VGA 适配器。我的显卡是 GeForce GTX 1650,我尝试下载这NVidia 的驱动程序。此外,正如您在图片中看到的,屏幕显示设置甚至不显示屏幕布局。
在 Ubuntu 14.04(我的旧笔记本电脑)上,我曾经使用类似方法解决过类似的问题:
echo $myNewMode
## Output: "1368x768_60.00" 85.25 1368 1440 1576 1784 768 771 781 798 -hsync +vsync
xrandr --addmode eDP-1 $myNewModeName
xrandr --output eDP-1 --mode $myNewModeName --output HDMI-1 --auto --right-of eDP-1
但是,这也不起作用。有什么想法吗?
更新:我已经运行X -configure
(只有主屏幕在工作)如前所述这里之后我运行了nvidia-xconfig
(只有 HDMI 有效)。不知何故,似乎 nvidia 拿走了最近创建的文件xorg.conf.new
并从中创建了自己的文件xorg.conf
。不过,如果我拔掉 HDMI,一切都是空白的。至少现在我可以在应用程序窗口上看到一个屏幕布局(HDMI)和内容nvidia x server settings
(之前是空白的)
这是最新的xorg.conf
文件:
# nvidia-xconfig: X configuration file generated by nvidia-xconfig
# nvidia-xconfig: version 440.26
Section "ServerLayout"
Identifier "X.org Configured"
Screen 0 "Screen0" 0 0
Screen 1 "Screen1" RightOf "Screen0"
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 "Monitor"
Identifier "Monitor0"
VendorName "Monitor Vendor"
ModelName "Monitor Model"
EndSection
Section "Monitor"
Identifier "Monitor1"
VendorName "Monitor Vendor"
ModelName "Monitor Model"
EndSection
Section "Device"
### Available Driver options are:-
### Values: <i>: integer, <f>: float, <bool>: "True"/"False",
### <string>: "String", <freq>: "<f> Hz/kHz/MHz",
### <percent>: "<f>%"
### [arg]: arg optional
#Option "Accel" # [<bool>]
#Option "AccelMethod" # <str>
#Option "Backlight" # <str>
#Option "CustomEDID" # <str>
#Option "DRI" # <str>
#Option "Present" # [<bool>]
#Option "ColorKey" # <i>
#Option "VideoKey" # <i>
#Option "Tiling" # [<bool>]
#Option "LinearFramebuffer" # [<bool>]
#Option "HWRotation" # [<bool>]
#Option "VSync" # [<bool>]
#Option "PageFlip" # [<bool>]
#Option "SwapbuffersWait" # [<bool>]
#Option "TripleBuffer" # [<bool>]
#Option "XvPreferOverlay" # [<bool>]
#Option "HotPlug" # [<bool>]
#Option "ReprobeOutputs" # [<bool>]
#Option "XvMC" # [<bool>]
#Option "ZaphodHeads" # <str>
#Option "VirtualHeads" # <i>
#Option "TearFree" # [<bool>]
#Option "PerCrtcPixmaps" # [<bool>]
#Option "FallbackDebug" # [<bool>]
#Option "DebugFlushBatches" # [<bool>]
#Option "DebugFlushCaches" # [<bool>]
#Option "DebugWait" # [<bool>]
#Option "BufferCache" # [<bool>]
Identifier "Card0"
Driver "nvidia"
BusID "PCI:0:2:0"
EndSection
Section "Device"
### Available Driver options are:-
### Values: <i>: integer, <f>: float, <bool>: "True"/"False",
### <string>: "String", <freq>: "<f> Hz/kHz/MHz",
### <percent>: "<f>%"
### [arg]: arg optional
#Option "SWcursor" # [<bool>]
#Option "HWcursor" # [<bool>]
#Option "NoAccel" # [<bool>]
#Option "ShadowFB" # [<bool>]
#Option "VideoKey" # <i>
#Option "WrappedFB" # [<bool>]
#Option "GLXVBlank" # [<bool>]
#Option "ZaphodHeads" # <str>
#Option "PageFlip" # [<bool>]
#Option "SwapLimit" # <i>
#Option "AsyncUTSDFS" # [<bool>]
#Option "AccelMethod" # <str>
#Option "DRI" # <i>
Identifier "Card1"
Driver "nvidia"
BusID "PCI:1:0:0"
EndSection
Section "Screen"
Identifier "Screen0"
Device "Card0"
Monitor "Monitor0"
DefaultDepth 24
SubSection "Display"
Viewport 0 0
Depth 1
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 4
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 8
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 15
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 16
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 24
EndSubSection
EndSection
Section "Screen"
Identifier "Screen1"
Device "Card1"
Monitor "Monitor1"
DefaultDepth 24
SubSection "Display"
Viewport 0 0
Depth 1
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 4
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 8
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 15
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 16
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 24
EndSubSection
EndSection
答案1
最后,我让它在双屏上工作了。我做了很多步骤,这是让你想知道“它有效,怎么回事?”的解决方案之一。我最后的步骤是:
1-我启用/选择gdm3
而不是lightdm
作为经理:
sudo gdm3
sudo dpkg-reconfigure gdm3
2 - 按照步骤登录恢复模式这里。
3 - 彻底删除文件rm -rf /etc/X11/xorg.conf
4 – 运行,但不替换创建的X -configure
文件。/root/xorg.conf.new
/etc/X11/xorg.conf
5-重新启动到正常模式,我以为会出现一些问题,但突然双显示器处于活动状态并且运行正常。
目前,它无需任何xorg.conf
文件即可工作。
我现在有点不敢碰它,尽管我认为我应该尝试重新创建该xorg.conf
文件,也许通过 nvidia?!我希望这对有类似问题的人有用。
另外,如果我在 bios 上启用安全启动,它会回到零,双显示器无法工作,尽管 ubuntu 运行正常。也许,需要将签名驱动程序放入内核或其他东西,我不确定。
如果有人知道到底发生了什么,我会很高兴听到。