300字范文,内容丰富有趣,生活中的好帮手!
300字范文 > ubuntu16.04登录界面输入用户名密码后又回到登录界面

ubuntu16.04登录界面输入用户名密码后又回到登录界面

时间:2024-08-01 02:52:20

相关推荐

ubuntu16.04登录界面输入用户名密码后又回到登录界面

原因有以下几种:

最好先查看log,即/var/log/Xorg.0.log .

1,磁盘空间不够了。

解决办法:字符界面登录,删除一些文件,腾出一些空间,重启即可。

2,/home/username文件夹的权限问题。

解决办法:# chown username:username /home/username -R

3,/tmp文件夹的权限问题。

解决办法:改成如下所示的权限即可。

$ ls / -lt

total 280

drwxrwxrwt 30 root root 155648 Aug 19 19:47 tmp

4, ~/.Xauthority 文件权限问题

解决办法:1>, 删除该文件

或者2>, # chown username:username ~/.Xauthority

同时可以查看log 文件 ~/.xsession-errors

5,造成循环登陆的原因还可能是.profile 或者profile 被改坏了

解决办法:从其他ubuntu系统中拷贝一个该文件。

$ cat ~/.profile

# ~/.profile: executed by the command interpreter for login shells.

# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login

# exists.

# see /usr/share/doc/bash/examples/startup-files for examples.

# the files are located in the bash-doc package.

# the default umask is set in /etc/profile; for setting the umask

# for ssh logins, install and configure the libpam-umask package.

#umask 022

# if running bash

if [ -n "$BASH_VERSION" ]; then

# include .bashrc if it exists

if [ -f "$HOME/.bashrc" ]; then

. "$HOME/.bashrc"

fi

fi

# set PATH so it includes user's private bin if it exists

if [ -d "$HOME/bin" ] ; then

PATH="$HOME/bin:$PATH"

fi

6, 如果之前装过nvidia的显卡驱动,可以重新安装一下该显卡驱动(可能是该显卡驱动没完全安装成功,导致该显卡驱动的配置文件部分损坏,从而导致无法进入桌面)。

解决办法:重新安装一下该显卡驱动。

以上所列也只是常见的几种情况,欢迎大家在comments里补充!

有一种建议安装驱动时候,加上如下flags(原文网址:/chaihuimin/article/details/71006654?locationNum=2&fps=1):

sudo ./NVIDIA.run -no-x-check -no-nouveau-check -no-opengl-files

-no-x-check:安装驱动时关闭X服务

-no-nouveau-check:安装驱动时禁用nouveau

-no-opengl-files:只安装驱动文件,不安装OpenGL文件

这样再reboot,就不会出现循环登录的问题。

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。