Я - аспирант, который попал в поддержание сервера на машине linux-Ubuntu - мы работаем в Ontopia и Wandora, двух программах, которым нравится смешивать со средами Java. Я учусь, когда я иду, что означает, что я, вероятно, испортил что-то глупое; я полагаю, что пытался обновить версию Java, который работал на Ubuntu, когда я повредил его.
Загрузки страницы входа в систему, я ввожу свой пароль, он перезагружает. Это происходит для всех пользователей, гостя и тестовых учетных записей. Это происходит в Ubuntu, Ubuntu2d, lubuntu и после graphicx отказоустойчивого бизнеса восстановления.
Вход в систему через оболочку (после Высокого звука F3) дает мне:
-bash: export: 'HOME/bin' : not a valid identifier
но позволяет мне перейти через систему и учетные записи без других очевидных проблем. Мой .xsession-errors
дает:
/etc/gdm/Xsession: 3: export: HOME/bin: bad variable name
когда я вхожу which java
Я добираюсь:
/usr/lib/jvm/java-6-openjdk-amd64//bin/java
Я видел, как это могло бы способствовать проблеме, но у меня нет подсказки, как изменить этот путь [и не могу найти, где сделать таким образом онлайн].
Мои файлы среды включают ПУТЬ К КЛАССУ И переменные CATALINA_HOME, что я не думаю, релевантны, а также:
PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:"
JAVA_HOME=/usr/lib/jvm/java-7-openjdk-amd64:/usr/lib/jvm/java-6-openjdk-amd64
JRE_HOME=/usr/lib/jvm/java-7-openjdk-amd64/jre:/usr/lib/jvm/java-6-openjdk-amd64/jre
Содержание java.sh
:
export JAVA_HOME=/usr/lib/jvm/java-6-openjdk-amd64/
export PATH=$JAVA_HOME/bin:$PATH
export PATH=$PATH:$JAVA $HOME/bin
Содержание /etc/bashrc
:
# System-wide .bashrc file for interactive bash(1) shells.
# To enable the settings / commands in this file for login shells as well,
# this file has to be sourced in /etc/profile.
# If not running interactively, don't do anything
[ -z "$PS1" ] && return
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, overwrite the one in /etc/profile)
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
# Commented out, don't overwrite xterm -T "title" -n "icontitle" by default.
# If this is an xterm set the title to user@host:dir
#case "$TERM" in
#xterm*|rxvt*)
# PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD}\007"'
# ;;
#*)
# ;;
#esac
# enable bash completion in interactive shells
#if [ -f /etc/bash_completion ] && ! shopt -oq posix; then
# . /etc/bash_completion
#fi
# sudo hint
if [ ! -e "$HOME/.sudo_as_admin_successful" ] && [ ! -e "$HOME/.hushlogin" ] ; then
case " $(groups) " in *\ admin\ *)
if [ -x /usr/bin/sudo ]; then
cat <<-EOF
To run a command as administrator (user "root"), use "sudo <command>".
See "man sudo_root" for details.
EOF
fi
esac
fi
# if the command-not-found package is installed, use it
if [ -x /usr/lib/command-not-found -o -x /usr/share/command-not-found/command-not-found ]; then
function command_not_found_handle {
# check because c-n-f could've been removed in the meantime
if [ -x /usr/lib/command-not-found ]; then
/usr/bin/python /usr/lib/command-not-found -- "$1"
return $?
elif [ -x /usr/share/command-not-found/command-not-found ]; then
/usr/bin/python /usr/share/command-not-found/command-not-found -- "$1"
return $?
else
printf "%s: command not found\n" "$1" >&2
return 127
fi
}
fi
Содержание ~/.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`
`
вам нужно просмотреть свои точечные файлы (например, если вы используете bash, это будет .bashrc, .bash_profile) для записи export PATH=....
.
Похоже, что одна из записей будет HOME/bin
, измените это на $HOME/bin
, выйдите и снова войдите в систему, и ошибка должна исчезнуть
Я думаю, что проблема здесь:
/etc/gdm/Xsession: 3: export: HOME/bin: bad variable name
Отредактируйте / etc / gdm / Xsession (sudo nano /etc/gdm/Xsession
), затем перейдите к строке № 3 и измените HOME/bin
на $HOME/bin
.