更新软件库apt-get update
升级软件apt-get upgrade
安装ubuntu桌面系统apt-get install ubuntu-desktop
重启服务器reboot
修改文件
# 文件 /usr/share/lightdm/lightdm.conf.d/50-ubuntu.conf
# 修改前
[Seat:*]
user-session=ubuntu
# 修改后
[Seat:*]
user-session=ubuntu
greeter-show-manual-login=true
allow-guest=false
# 文件 /root/.profile
# 文件修改前
# ~/.profile: executed by Bourne-compatible login shells.
if [ "$BASH" ]; then
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
fi
mesg n || true
# 文件修改后
# ~/.profile: executed by Bourne-compatible login shells.
if [ "$BASH" ]; then
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
fi
tty -s && mesg n || true
再执行 reboot 命令,重启服务器,重启之后,只有root用户,登录后也没有警告信息了。