This post relates to this question where I was asked to explain how I installed python3 on my system. I was attempting to install python3 on my system for development purposes. Something went wrong along the line, and now my system does not recognize either the default python install, or the python 3.4 install. Also apps like yum are also broken.
sudo apt-get install curl git-core gcc make zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev libssl-dev sudo yum install scl-utils sudo wget https://www.softwarecollections.org/en/scls/rhscl/python33/epel-7-x86_64/download/rhscl-python33-epel-7-x86_64.noarch.rpm sudo yum install rhscl-python33-*.noarch.rpm
Also, the line I appended and later removed from my .bashrc file was
In retrospect I imagine that it should have been "python3.4" but either way, I assumed potentially incorrectly that simply commenting this line out would remove its effect.
Edit: Also if memory serves, the apt-get was irrelevant because I was trying to install it the wrong way, so I really should not have included it here.
Edit Added outputs from commands:
Just typing "python" returns:
-bash: python: command not found
which python gives:
/usr/bin/which: no python in (/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/home/myusername/.local/bin:/home/myusername/bin)
However there is a python install in both
alternatives --list | grep -i python yields:
python auto /usr/bin/python3.4
-v python returns nothing.
type -a python gives:
-bash: type: python: not found
declare -p PATH outputs
declare -x PATH="/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/home/myusername/.local/bin:/home/myusername/bin"
I do seem to have
$ ls -l /usr/bin/python lrwxrwxrwx 1 root root 24 Jun 25 15:39 /usr/bin/python -> /etc/alternatives/python
$ ls -l $(readlink -f /usr/bin/python) gives:
ls: cannot access /usr/bin/python3.4: No such file or directory
I do not know if this is relevant, but
/etc/alternatives/python was pink looking in the terminal.
ls -l /usr/local/bin/` prints `-rwxr-xr-x 1 root root 101 Sep 4 2014 2to3-3.4 -rwxr-xr-x 1 root root 241 Sep 4 2014 easy_install-3.4 -rwxr-xr-x 1 root root 99 Sep 4 2014 idle3.4 -rwxr-xr-x 1 root root 213 Sep 4 2014 pip3.4 -rwxr-xr-x 1 root root 84 Sep 4 2014 pydoc3.4 -rwxr-xr-x 2 root root 17544 Sep 4 2014 python3.4 -rwxr-xr-x 2 root root 17544 Sep 4 2014 python3.4m -rwxr-xr-x 1 root root 3066 Sep 4 2014 python3.4m-config -rwxr-xr-x 1 root root 236 Sep 4 2014 pyvenv-3.4
/opt/rh/python33/root/usr/bin/python3.3: error while loading shared libraries: libpython3.3m.so.1.0: cannot open shared object file: No such file or directory