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

# The file /etc/login.defs already sets the default PATH.
# if [ "`id -u`" -eq 0 ]; then
#   PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
# else
#   PATH="/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games"
# fi
# export PATH

# auto shell script startup process
for i in /etc/profile.d/*.sh ; do
 if [ -r "$i" ]; then
     . $i
 fi
done
unset i

export MIBS=ALL
export SNMPCONFPATH=/etc/snmp


if [ "`id -u`" -eq 0 ]; then
  PS1='# '
else
  PS1='debug> '
  export PATH=/bin:/usr/bin:
  alias help='echo cli, exit, passwd, ping, reboot, route, ssh, syslog, uptime, telnet'
  alias cd='help'
  alias ls='help'
  alias vi='help'
  alias cat='help'
  alias more='help'
  alias import_config='help'
  alias export_config='help'
  alias diagnostic='help'
  alias ldd='help'
  alias mib2c='help'
  alias snmpbulkget='help'
  alias snmpbulkwalk='help'
  alias snmpconf='help'
  alias snmpdelta='help'
  alias snmpdf='help'
  alias snmpget='help'
  alias snmpgetnext='help'
  alias snmpinform='help'
  alias snmpnetstat='help'
  alias snmpset='help'
  alias snmpstatus='help'
  alias snmptable='help'
  alias snmptest='help'
  alias snmptranslate='help'
  alias snmptrap='help'
  alias snmpusm='help'
  alias snmpvacm='help'
  alias snmpwalk='help'
  alias traptoemail='help'
  alias zebra='help'
fi

telnet localhost 35600

if [ "`id -u`" -ne 0 ]; then
  export CURRENT_PID=$PPID
  if [ -f /tmp/view_node_exit ] ; then
    rm -rf /tmp/view_node_exit
    #kill -9 $CURRENT_PID;
  fi
fi

