升级到16.04后登录循环

在将xenial beta更新到最新更新后,我遇到了一个登录循环。

我尝试了很多东西:

  • xauthority/tmp权限更改

  • 重新安装nvidia驱动程序,删除它们。

  • 重新安装unityunity-greeterunity-greeter ubuntu-desktopupstartlightdmcompiz

  • 重置compizunity设置。(我得到dbus启动错误:

     Failed to commit changes to dconf: error spawning command line 'dbus-launch -auto launch=..................) 
  • 使用旧内核和故障安全(故障安全报告没有找到屏幕)

  • 试图推出其他DE(蒸汽大图)

这是xsession错误日志:

 unity: open connection: connect: No such file or directory Cannot connect to brltty at :0 upstart: gnome-session (unity) main process (5441) terminated with status 1 upstart unity-settings-daemon main process (5434) killed by TERM signal steam big picture: open connection: connect: No such file or directory Cannot connect to brltty at :0 ERROR: ld.so: object '/usr/lib/i386-linux-gnu/libmodeswitch_inhibitor.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file(: ignored. ERROR: ld.so: object '/usr/lib/i386-linux-gnu/libmodeswitch_inhibitor.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file(: ignored ERROR: ld.so: object '/usr/lib/i386-linux-gnu/libmodeswitch_inhibitor.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file(: ignored Could not create GLX context ERROR: ld.so: object '/usr/lib/i386-linux-gnu/libmodeswitch_inhibitor.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file(: ignored 

在Unity(compiz)日志中,有很多关于opengl插件的错误

 Compiz (opengl) - Fatal: glXQueryExtenisonsString is NULL for screen 0 

而且由于opengl而卸载了很多插件。

Lightdm有突然的SIGTERM信号,日志中没有先前的错误。

xserver有2个错误:

 xf86EnablePorts: failed to set IOPL for I/O (Operation not permitted) (EE) Failed to initialize GLX extension (Compatible NVIDIA X driver not found) 

但它继续通过输入操作,直到它突然终止。

在我的情况下,原始的nvidia驱动程序是原因,并切换回开源nouveau帮助。 首先,我从nvidia中删除了所有内容:

 sudo apt-get remove --purge 'nvidia-*' sudo apt-get install ubuntu-desktop sudo rm /etc/X11/xorg.conf echo 'nouveau' | sudo tee -a /etc/modules 

(来源: 如何完全卸载nvidia驱动程序? )

之后我可以登录,但是Unity没有加载,没有启动器等等。事实certificate我必须重新启用Unity插件:

 sudo apt-get install compizconfig-settings-manager DISPLAY=:0 ccsm Find the Unity plugin and enable it. 

(来源: Unity不加载,没有Launcher,没有Dash出现 )

问题是,当您更新Ubuntu时(甚至在安装调用/sbin/ldconfig某些程序时),对/etc/ls.so.cache进行了/etc/ls.so.cache

试试看,你会发现安装/更新后的ld.so.cache文件的大小与操作前的大小不同。

在Ubuntu 16.04中,从lightDM登录时会产生登录循环。 因此,您应该保留原始ld.so.cache的副本,因为在安装/更新后生成的新版本中,lightDM将不再进行身份validation。

我多次遇到过这个问题,并且必须非常小心。 我总是保留原始文件的副本( /etc/ld.so.cache.orig ),它允许我在没有登录循环的情况下登录并使用它登录。然后,一旦我成功登录,我复制新的一个( /etc/ld.so.cache.new )结束。 为此,我修改了~/.bash_profile文件并添加了以下行:

 sudo /bin/cp /etc/ld.so.cache.new /etc/ld.so.cache 

然后,为了在退出会话时将原始文件复制回来以便我下次登录获取,我已将此行添加到/etc/gdm/PostSession/Default

 /bin/cp /etc/ld.so.cache.orig /etc/ld.so.cache 

为了实现这一点,我修改了/etc/sudoers (通过运行sudo vosudo )以允许非特权用户运行copy命令:

 ALL ALL= NOPASSWD: /bin/cp /etc/ld.so.cache.new /etc/ld.so.cache 

这可能看起来像一个丑陋的黑客,但它解决了这个登录循环问题,并且还保留了新的/etc/ld.so.cache文件。

我在16.04也有同样的错误。 在我的情况下,它也是一个NVidia驱动程序问题。 我有8个显示器,我喜欢NVidia潜水员的表现。 为了让它运作起来,我:

  1. 在登录提示符下按CTRL + ALT + F1并通过终端登录。

  2. 备份可能是旧的/etc/X11/xorg.conf文件,因为配置8个监视器很痛苦。

  3. 从NVidia下载驱动程序文件: NVIDIA-Linux-x86_64-367.44.run

  4. 执行以下命令: sudo service lightdm stop (如果跳过此步骤,驱动程序安装将失败)。

  5. 重新安装驱动程序: sudo ./NVIDIA-Linux-x86_64-367.44.run我收到通知,说自动生成的脚本没有完成,并且可以选择继续我接受的安装。 我还选择将驱动程序作为内核模块安装,并让程序生成一个新的xorg.conf文件(之前支持我的)。 在该过程结束时,它抱怨缺少lib的链接,但给出了链接到它的说明。 我推迟处理这件事。

  6. 重新启动,并能够通过GUI登录。

我正在使用xfce,我通过重命名手动检查每个文件夹和文件。 删除~/.config/xfce4/xfconf/xfce-perchannel-xml/displays.xml对我~/.config/xfce4/xfconf/xfce-perchannel-xml/displays.xml

我也有nvidia驱动程序,但是当我以root用户身份登录时,它们工作正常。