I've installed ubuntu 20.04.3 lts, and I installed anaconda3 twice, first time from user privilege and once again from root privilege since not being activated conda. when i reopened the terminal, i need to type the command to be activated conda. But If i type '$whereis conda', it doesn't show the bin directory where it was actually installed. I typed like given below,
hilipkumar@thilipkumar-Inspiron-5520:~$ python
Command 'python' not found, did you mean:
command 'python3' from deb python3
command 'python' from deb python-is-python3
thilipkumar@thilipkumar-Inspiron-5520:~$ whereis conda
conda: /home/thilipkumar/anaconda3/condabin/conda
thilipkumar@thilipkumar-Inspiron-5520:~$ source /home/thilipkumar/anaconda3/bin/activate
(base) thilipkumar@thilipkumar-Inspiron-5520:~$ conda init
no change /home/thilipkumar/anaconda3/condabin/conda
no change /home/thilipkumar/anaconda3/bin/conda
no change /home/thilipkumar/anaconda3/bin/conda-env
no change /home/thilipkumar/anaconda3/bin/activate
no change /home/thilipkumar/anaconda3/bin/deactivate
no change /home/thilipkumar/anaconda3/etc/profile.d/conda.sh
no change /home/thilipkumar/anaconda3/etc/fish/conf.d/conda.fish
no change /home/thilipkumar/anaconda3/shell/condabin/Conda.psm1
no change /home/thilipkumar/anaconda3/shell/condabin/conda-hook.ps1
no change /home/thilipkumar/anaconda3/lib/python3.8/site-packages/xontrib/conda.xsh
no change /home/thilipkumar/anaconda3/etc/profile.d/conda.csh
no change /home/thilipkumar/.bashrc
No action taken.
(base) thilipkumar@thilipkumar-Inspiron-5520:~$ source ~/.bashrc
thilipkumar@thilipkumar-Inspiron-5520:~$ conda config --set auto_activate_base False
thilipkumar@thilipkumar-Inspiron-5520:~$ python
Python 3.8.8 (default, Apr 13 2021, 19:58:26)
[GCC 7.3.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> quit()
thilipkumar@thilipkumar-Inspiron-5520:~$
And i need to follow the same thing in root privilege too. If once i close and reopen the terminal, i need to do the same thing. Can anyone tell me a suggestion to solve this problem? And last few lines of $vi .bashrc
# >>> conda initialize >>>
# !! Contents within this block are managed by 'conda init' !!
__conda_setup="$('/home/thilipkumar/anaconda3/bin/conda' 'shell.bash' 'hook' 2> /dev/null)"
if [ $? -eq 0 ]; then
eval "$__conda_setup"
else
if [ -f "/home/thilipkumar/anaconda3/etc/profile.d/conda.sh" ]; then
. "/home/thilipkumar/anaconda3/etc/profile.d/conda.sh"
else
export PATH="/home/thilipkumar/anaconda3/bin:$PATH"
fi
fi
unset __conda_setup
# <<< conda initialize <<<
And echo $PATH
before activated
thilipkumar@thilipkumar-Inspiron-5520:~$ echo $PATH
/home/thilipkumar/anaconda3/condabin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
thilipkumar@thilipkumar-Inspiron-5520:~$