linux - Commands not working after editing bashrc file in ubuntu -


i had added export statements hcatalog in .bashrc file messed .basrc file. if open bashrc file in cmd , remove 2 export statements, still not able run of commands.

my current bashrc file:

>     # ~/.bashrc: executed bash(1) non-login shells. >     # see /usr/share/doc/bash/examples/startup-files (in package bash-doc) >     # examples >  >     # if not running interactively, don't >     [ -z "$ps1" ] && return >  >     # don't put duplicate lines or lines starting space in history. >     # see bash(1) more options >     histcontrol=ignoreboth >  > # append history file, don't overwrite shopt -s histappend >  > # setting history length see histsize , histfilesize in bash(1) histsize=1000 histfilesize=2000 >  > # check window size after each command and, if necessary, > # update values of lines , columns. shopt -s checkwinsize >  > # if set, pattern "**" used in pathname expansion context > # match files , 0 or more directories , subdirectories. > #shopt -s globstar >  > # make less more friendly non-text input files, see lesspipe(1) [ -x /usr/bin/lesspipe ] && eval "$(shell=/bin/sh lesspipe)" >  > # set variable identifying chroot work in (used in prompt below) if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; >     debian_chroot=$(cat /etc/debian_chroot) fi >  > # set fancy prompt (non-color, unless know "want" color) case "$term" in >     xterm-color) color_prompt=yes;; esac >  > # uncomment colored prompt, if terminal has capability; turned > # off default not distract user: focus in terminal window > # should on output of commands, not on prompt > #force_color_prompt=yes >  > if [ -n "$force_color_prompt" ]; >     if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; >     # have color support; assume it's compliant ecma-48 >     # (iso/iec-6429). (lack of such support extremely rare, , such >     # case tend support setf rather setaf.) >     color_prompt=yes >     else >     color_prompt= >     fi fi >  > if [ "$color_prompt" = yes ]; >     ps1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ > ' else >     ps1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' fi unset color_prompt force_color_prompt >  > # if xterm set title user@host:dir case "$term" in xterm*|rxvt*) >     ps1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$ps1" >     ;; > *) >     ;; esac >  > # enable color support of ls , add handy aliases if [ -x /usr/bin/dircolors ]; >     test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)" >     alias ls='ls --color=auto' >     #alias dir='dir --color=auto' >     #alias vdir='vdir --color=auto' >  >     alias grep='grep --color=auto' >     alias fgrep='fgrep --color=auto' >     alias egrep='egrep --color=auto' fi >  > # more ls aliases alias ll='ls -alf' alias la='ls -a' alias l='ls -cf' >  > # add "alert" alias long running commands.  use so: > #   sleep 10; alert alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"' >  > # alias definitions. > # may want put additions separate file > # ~/.bash_aliases, instead of adding them here directly. > # see /usr/share/doc/bash-doc/examples in bash-doc package. >  > if [ -f ~/.bash_aliases ]; >     . ~/.bash_aliases fi >  >  >  > # enable programmable completion features (you don't need enable > # this, if it's enabled in /etc/bash.bashrc , /etc/profile > # sources /etc/bash.bashrc). if [ -f /etc/bash_completion ] && ! shopt -oq posix; >     . /etc/bash_completion fi >  > export java_home=/usr/lib/jvm/java-6-openjdk-amd64 >  > export hadoop_prefix=/home/itelligence/hadoop-1.2.0 export > path=$path:$hadoop_prefix/bin >  > export hadoop_common_home=/home/itelligence/hadoop-1.2.0 export > hadoop_mapred_home=/home/itelligence/hadoop-1.2.0 export > hbase_home=/home2/itelligence/hbase-0.94.20 export > hive_home=/home/itelligence/hive-0.12.0 >  > export pig_prefix=/home/itelligence/pig-0.11.1 export > path=$path:$pig_prefix/bin >  > export hive_prefix=/home/itelligence/hive-0.12.0 export > path=$path:$hive_prefix/bin >  > export hbase_prefix=/home/itelligence/hbase-0.94.20 export > path=$path:$hbase_prefix/bin >  > export zookeeper_prefix=/home/itelligence/zookeeper-3.4.6 export > path=$path:$zookeeper_prefix/bin >  > export sqoop_prefix=/home/itelligence/sqoop-1.4.4.bin__hadoop-1.0.0 > export path=$path:$sqoop_prefix/bin export > flume_prefix=/home/itelligence/apache-flume-1.6.0-bin export > path=$path:$flume_prefix/bin >  >     export cassandra_prefix=/home/itelligence/apache-cassandra-2.0.8 >     export path=$pat4h:$cassandra_pefix/bin 

and error encountering are: hadoop namenode -format hadoop:command not found

could please me this. tia.

there's lot of things wrong. half if statements, commented gone. , exports have been moved end of lines.

i think should reset file: cp -f /etc/skel/.bashrc ~/


Comments

Popular posts from this blog

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

python Tkinter Capturing keyboard events save as one single string -

sql server - Why does Linq-to-SQL add unnecessary COUNT()? -