更新至 Ubuntu 17.10 后出现 Ubuntu Gnome 错误

更新至 Ubuntu 17.10 后出现 Ubuntu Gnome 错误

更新 ubuntu gnome 后,每次登录时都会出现黑屏和错误窗口。我只需单击“确定”并继续,但忽略了它一个月左右后,我想我应该修复它。有人能帮助我吗?

错误窗口如下所示:

Error found when loading /etc/profile:

Locale: Cannot set LC_ALL to default locale: No such file or directory
Locale: Cannot set LC_ALL to default locale: No such file or directory

As a result the session will not be configured correctly. You should fix the problem as soon as feasible.

该文件包含以下几行:

# /etc/profile: system-wide .profile file for the Bourne shell (sh(1))
# and Bourne compatible shells (bash(1), ksh(1), ash(1), ...).

if [ "${PS1-}" ]; then
  if [ "${BASH-}" ] && [ "$BASH" != "/bin/sh" ]; then
    # The file bash.bashrc already sets the default PS1.
    # PS1='\h:\w\$ '
    if [ -f /etc/bash.bashrc ]; then
      . /etc/bash.bashrc
    fi
  else
    if [ "`id -u`" -eq 0 ]; then
      PS1='# '
    else
      PS1='$ '
    fi
  fi
fi

if [ -d /etc/profile.d ]; then
  for i in /etc/profile.d/*.sh; do
    if [ -r $i ]; then
      . $i
    fi
  done
  unset i
fi

相关内容