pkg 升級破壞了 FreeBSD 上的 X 伺服器 ((II) NVIDIA(0): Validated MetaModes: ‘NULL’)
問題
在最近更新了
pkg
大約 60 個其他程序後,我的 X 伺服器壞了。我以前用 dwm 啟動,
startx
但我收到以下錯誤消息:xauth: file /home/user/.serverauth.1323 does not exists xauth: (argv):1: bad display name "pc-freebsd:0" in "list" command xauth: (stdin):1: bad display name "pc-freebsd:0" in "add" command
資訊
- 之後我在這個 tty 上什麼也做不了。
- 我知道
startx
達到,.xinitrc
因為我~/.xinitrc
的配置為在處理時發出嗶嗶聲。enable_xauth
設置為1
in/usr/local/bin/startx
。Xorg.0.log
[ 131.714] X.Org X Server 1.17.4 Release Date: 2015-10-28 [ 131.714] X Protocol Version 11, Revision 0 [ 131.714] Build Operating System: FreeBSD 10.1-RELEASE-p39 amd64 [ 131.714] Current Operating System: FreeBSD pc-freebsd 10.3-RELEASE-p4 FreeBSD 10.3-RELEASE-p4 #0: Sat May 28 12:23:44 UTC 2016 root@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64 [ 131.715] Build Date: 04 October 2016 06:28:38AM [ 131.715] [ 131.715] Current version of pixman: 0.34.0 [ 131.715] Before reporting problems, check http://wiki.x.org to make sure that you have the latest version. [ 131.715] Markers: (--) probed, (**) from config file, (==) default setting, (++) from command line, (!!) notice, (II) informational, (WW) warning, (EE) error, (NI) not implemented, (??) unknown. [ 131.715] (==) Log file: "/var/log/Xorg.0.log", Time: Mon Oct 10 23:11:24 2016 [ 131.759] (==) Using config file: "/etc/X11/xorg.conf" [ 131.760] (==) ServerLayout "X.org Configured" [ 131.760] (**) |-->Screen "Screen0" (0) [ 131.760] (**) | |-->Monitor "Monitor0" [ 131.760] (**) | |-->Device "Card0" [ 131.761] (**) |-->Input Device "Mouse0" [ 131.761] (**) |-->Input Device "Keyboard0" [ 131.761] (==) Automatically adding devices [ 131.761] (==) Automatically enabling devices [ 131.761] (==) Not automatically adding GPU devices [ 131.851] (**) FontPath set to: /usr/local/share/fonts/misc/, /usr/local/share/fonts/TTF/, /usr/local/share/fonts/OTF/, /usr/local/share/fonts/Type1/, /usr/local/share/fonts/100dpi/, /usr/local/share/fonts/75dpi/, /usr/local/share/fonts/misc/, /usr/local/share/fonts/TTF/, /usr/local/share/fonts/OTF/, /usr/local/share/fonts/Type1/, /usr/local/share/fonts/100dpi/, /usr/local/share/fonts/75dpi/ [ 131.851] (**) ModulePath set to "/usr/local/lib/xorg/modules" [ 131.851] (WW) Hotplugging is on, devices using drivers 'kbd', 'mouse' or 'vmmouse' will be disabled. [ 131.851] (WW) Disabling Mouse0 [ 131.851] (WW) Disabling Keyboard0 [ 131.851] (II) Loader magic: 0x801510 [ 131.851] (II) Module ABI versions: [ 131.851] X.Org ANSI C Emulation: 0.4 [ 131.851] X.Org Video Driver: 19.0 [ 131.851] X.Org XInput driver : 21.0 [ 131.851] X.Org Server Extension : 9.0 [ 131.852] (--) PCI:*(0:1:0:0) 10de:0dd6:1028:04b7 rev 161, Mem @ 0xd4000000/16777216, 0xc0000000/268435456, 0xd0000000/33554432, I/O @ 0x00004000/128, BIOS @ 0x????????/65536 [ 131.852] (II) "glx" will be loaded. This was enabled by default and also specified in the config file. [ 131.852] (II) LoadModule: "glx" [ 131.885] (II) Loading /usr/local/lib/xorg/modules/extensions/libglx.so [ 132.263] (II) Module glx: vendor="NVIDIA Corporation" [ 132.264] compiled for 4.0.2, module version = 1.0.0 [ 132.264] Module class: X.Org Server Extension [ 132.264] (II) NVIDIA GLX Module 367.44 Wed Aug 17 22:01:17 PDT 2016 [ 132.273] (II) LoadModule: "nvidia" [ 132.273] (II) Loading /usr/local/lib/xorg/modules/drivers/nvidia_drv.so [ 132.329] (II) Module nvidia: vendor="NVIDIA Corporation" [ 132.329] compiled for 4.0.2, module version = 1.0.0 [ 132.329] Module class: X.Org Video Driver [ 132.336] (II) NVIDIA dlloader X Driver 367.44 Wed Aug 17 21:41:06 PDT 2016 [ 132.336] (II) NVIDIA Unified Driver for all Supported NVIDIA GPUs [ 132.337] (--) Using syscons driver with X support (version 0.x) [ 132.337] (--) using VT number 9 [ 132.359] (II) Loading sub module "fb" [ 132.359] (II) LoadModule: "fb" [ 132.359] (II) Loading /usr/local/lib/xorg/modules/libfb.so [ 132.374] (II) Module fb: vendor="X.Org Foundation" [ 132.374] compiled for 1.17.4, module version = 1.0.0 [ 132.374] ABI class: X.Org ANSI C Emulation, version 0.4 [ 132.374] (II) Loading sub module "wfb" [ 132.374] (II) LoadModule: "wfb" [ 132.374] (II) Loading /usr/local/lib/xorg/modules/libwfb.so [ 132.380] (II) Module wfb: vendor="X.Org Foundation" [ 132.380] compiled for 1.17.4, module version = 1.0.0 [ 132.380] ABI class: X.Org ANSI C Emulation, version 0.4 [ 132.381] (II) Loading sub module "ramdac" [ 132.381] (II) LoadModule: "ramdac" [ 132.381] (II) Module "ramdac" already built-in [ 132.383] (WW) VGA arbiter: cannot open kernel arbiter, no multi-card support [ 132.383] (==) NVIDIA(0): Depth 24, (==) framebuffer bpp 32 [ 132.383] (==) NVIDIA(0): RGB weight 888 [ 132.383] (==) NVIDIA(0): Default visual is TrueColor [ 132.383] (==) NVIDIA(0): Using gamma correction (1.0, 1.0, 1.0) [ 132.385] (**) NVIDIA(0): Enabling 2D acceleration [ 133.170] (II) NVIDIA(0): NVIDIA GPU GeForce GT 550M (GF106) at PCI:1:0:0 (GPU-0) [ 133.170] (--) NVIDIA(0): Memory: 1048576 kBytes [ 133.170] (--) NVIDIA(0): VideoBIOS: 70.06.32.00.04 [ 133.170] (II) NVIDIA(0): Detected PCI Express Link width: 16X [ 133.182] (II) NVIDIA(0): Validated MetaModes: [ 133.182] (II) NVIDIA(0): "NULL" [ 133.182] (II) NVIDIA(0): Virtual screen size determined to be 640 x 480 [ 133.182] (WW) NVIDIA(0): Unable to get display device for DPI computation. [ 133.182] (==) NVIDIA(0): DPI set to (75, 75); computed from built-in default [ 133.182] (--) Depth 24 pixmap format is 32 bpp [ 133.182] (II) NVIDIA: Reserving 12288.00 MB of virtual memory for indirect memory [ 133.182] (II) NVIDIA: access. [ 133.322] (II) NVIDIA(0): Built-in logo is bigger than the screen. [ 133.323] (II) NVIDIA(0): Setting mode "NULL" [ 133.375] (==) NVIDIA(0): Disabling shared memory pixmaps [ 133.375] (==) NVIDIA(0): Backing store enabled [ 133.375] (==) NVIDIA(0): Silken mouse enabled [ 133.389] (==) NVIDIA(0): DPMS enabled [ 133.389] (II) Loading sub module "dri2" [ 133.389] (II) LoadModule: "dri2" [ 133.389] (II) Module "dri2" already built-in [ 133.389] (II) NVIDIA(0): [DRI2] Setup complete [ 133.389] (II) NVIDIA(0): [DRI2] VDPAU driver: nvidia [ 133.390] (--) RandR disabled [ 133.406] (II) Initializing extension GLX [ 133.406] (II) Indirect GLX disabled. [ 134.137] (II) config/devd: probing input devices... [ 134.137] (II) config/devd: adding input device (null) (/dev/kbdmux) [ 134.137] (II) LoadModule: "kbd" [ 134.149] (II) Loading /usr/local/lib/xorg/modules/input/kbd_drv.so [ 134.154] (II) Module kbd: vendor="X.Org Foundation" [ 134.154] compiled for 1.17.4, module version = 1.8.1 [ 134.154] Module class: X.Org XInput Driver [ 134.154] ABI class: X.Org XInput driver, version 21.0 [ 134.154] (II) Using input driver 'kbd' for 'kbdmux' [ 134.154] (**) kbdmux: always reports core events [ 134.154] (**) kbdmux: always reports core events [ 134.154] (**) Option "Protocol" "standard" [ 134.154] (**) Option "XkbRules" "base" [ 134.154] (**) Option "XkbModel" "pc105" [ 134.154] (**) Option "XkbLayout" "us" [ 134.154] (**) Option "config_info" "devd:kbdmux" [ 134.154] (II) XINPUT: Adding extended input device "kbdmux" (type: KEYBOARD, id 6) [ 134.161] (II) config/devd: kbdmux is enabled, ignoring device ukbd0 [ 134.161] (II) config/devd: kbdmux is enabled, ignoring device ukbd1 [ 134.161] (II) config/devd: kbdmux is enabled, ignoring device atkbd0 [ 134.161] (II) config/devd: adding input device (null) (/dev/sysmouse) [ 134.161] (II) LoadModule: "mouse" [ 134.161] (II) Loading /usr/local/lib/xorg/modules/input/mouse_drv.so [ 134.162] (II) Module mouse: vendor="X.Org Foundation" [ 134.162] compiled for 1.17.4, module version = 1.9.1 [ 134.162] Module class: X.Org XInput Driver [ 134.162] ABI class: X.Org XInput driver, version 21.0 [ 134.162] (II) Using input driver 'mouse' for 'sysmouse' [ 134.162] (**) sysmouse: always reports core events [ 134.162] (**) Option "Device" "/dev/sysmouse" [ 134.162] (==) sysmouse: Protocol: "Auto" [ 134.162] (**) sysmouse: always reports core events [ 134.162] (==) sysmouse: Emulate3Buttons, Emulate3Timeout: 50 [ 134.162] (**) sysmouse: ZAxisMapping: buttons 4 and 5 [ 134.162] (**) sysmouse: Buttons: 5 [ 134.162] (**) Option "config_info" "devd:sysmouse" [ 134.162] (II) XINPUT: Adding extended input device "sysmouse" (type: MOUSE, id 7) [ 134.162] (**) sysmouse: (accel) keeping acceleration scheme 1 [ 134.162] (**) sysmouse: (accel) acceleration profile 0 [ 134.162] (**) sysmouse: (accel) acceleration factor: 2.000 [ 134.162] (**) sysmouse: (accel) acceleration threshold: 4 [ 134.162] (II) sysmouse: SetupAuto: hw.iftype is 4, hw.model is 0 [ 134.162] (II) sysmouse: SetupAuto: protocol is SysMouse [ 134.163] (II) config/devd: device /dev/ums0 already opened [ 134.163] (II) config/devd: device /dev/ums1 already opened [ 134.163] (II) config/devd: device /dev/ums2 already opened [ 134.163] (II) config/devd: device /dev/psm0 already opened
我已經嘗試過的
殺死程序並
startx
再次執行
- 更改 tty。
- 以 root 身份登錄。
- 執行
ps
:1337 v0 S 1:00:00 /usr/local/bin/X :0 -auth /home/user/.serverauth1323 (Xorg)
- 用 殺死程序
kill -9
。- 將 tty 更改回使用者登錄的位置。
使用者現在可以再次使用他們的命令提示符。
來自 xauth 的另一條消息:
xauth: (argv):1: bad display name "pc-freebsd:0" in "remove" command
- 執行
startx
。不能解決我的問題。
刪除
/home/user/.serverauth.*
文件我刪除了所有這些文件,但沒有幫助。
嘗試以 root 身份訪問 X 伺服器
- 以 root 身份登錄。
- 執行
startx
。有趣的是,儘管我收到了相同的錯誤消息,
xauth
並且由於目前的 tty 凍結了,我不得不更改 tty,但啟動了許多額外的程序:
- 初始化
- xterm(實際上是其中的 3 個)
- twm
- 時鐘我試圖殺死所有這些程序,但是當我執行
pkill xclock
整個機器時,我不得不使用電源按鈕。設置
enable_xauth
為。0
_/usr/local/bin/startx
根據forums.freebsd.org(連結)上的這個執行緒,一個 hacky 解決方案可能設置
enable_xauth
為0
in/usr/local/bin/startx
。然而,它對我不起作用。xauth 消息消失了,但
dwm
也沒有啟動。重新安裝所有軟體包
我決定嘗試使用
pkg upgrade -f
(靈感:此執行緒(連結))重新安裝所有軟體包。重新啟動後我跑了
startx
,一秒鐘後整個螢幕變黑了,螢幕左上角只有一個很大的游標塊(看起來字型變大了)。當我切換 tty 然後立即切換回來時,我可以看到
usage: sleeps seconds
一直在列印的流。拔掉遠端螢幕
機器是戴爾L702X。我使用外接顯示器而不是筆記型電腦的預設螢幕。My
~/.xinitrc
包含以下行,這些行禁用預設螢幕並將影片流式傳輸到外部監視器(通過 HDMI 連接)。xrandr --output DP-1 --off --output HDMI-0 --auto xrandr --output HDMI-0 --rotate left
不幸的是,拔下顯示器或註釋掉這些行都不能解決問題。
顯然,它與
xauth
.我應該
/usr/ports/UPDATING
在更新之前閱讀。該問題與以下消息有關
Xorg.0.log
:[ 133.182] (II) NVIDIA(0): Validated MetaModes: [ 133.182] (II) NVIDIA(0): "NULL"
我們可以讀到
/usr/ports/UPDATING
:20160829:影響:x11/nvidia-driver 的使用者作者:cem@FreeBSD.org
NVidia 驅動程序已更新至版本 367.35。從版本 358.09 開始,添加了新的核心模組 nvidia-modeset.ko。這個新的驅動程序組件與 nvidia.ko 核心模組一起工作,以對 GPU 的顯示引擎進行程式。
使用者在啟動 X11 伺服器時遇到掛起,或觀察
(II) NVIDIA(0): Validated MetaModes: (II) NVIDIA(0): "NULL"
他們
/var/log/Xorg.0.log
文件中的消息應將nvidia 替換為或文件中的nvidia-modeset,具體取決於他們更喜歡如何載入 NVidia 驅動程序核心模組。/boot/loader.conf``/etc/rc.conf
因此,在我更改
nvidia_load="YES"
為nvidia-modeset_load="YES"
in後,/boot/loader.conf
我能夠進入 dwm 會話。同時,我對 FreeBSD 11.0 進行了系統升級,所以我不確定這是否是解決問題所需的一切。