2

I'm in complete trouble with my Ubuntu 13.04 distro. Today I wanted to try python 3.3, I compiled it and installed from source. It broke my system, many packages wait for apt-get remove cmmand. I tried to purge python by issuing "sudo apt-get remove –purge python*" after then I still can not revert to python 2.7.4. Most importantly how can I reinstall my system? I feel like hanging in gallow, please help.

  • That version of Ubuntu already has Python 3.3, meaning you could have simply installed it via apt-get. Anyways, can you show what error messages you get... the ones that convinced you you can't revert to 2.7.4? – Tshepang Sep 9 '13 at 23:10
  • It was a known bug with python 2.7.4. The error message was "IOError: [Errno 2] No such file or directory: '/usr/lib/python2.7/sitecustomize.py'" Here is the filed bug : bugs.debian.org/cgi-bin/bugreport.cgi?bug=709157# – kenn Sep 10 '13 at 7:43
  • 1
    I know 13.04 has python3.3 but mine was using python2.7.4. Upgrading to 3.3 borked my system – kenn Sep 10 '13 at 7:59
  • same problem with me – Rajat Gupta Feb 18 '14 at 7:54
1

I fixed uninstallation problem by putting back "sitecustomize.py" It was deleted during upgrading to python3.3 so I could not purge python. I searched for it by "locate sitecustomize.py" luckily I found it in remastersys folder. I copied it into sudo cp /home/remastersys/remastersys/dummysys/etc/python2.7/sitecustomize.py /usr/lib/python2.7/ then ran sudo dpkg -a --configure uninstallation problem fixed. Thank you Tshepang for answer

Edit: Today after system updated python, I met the IOError: [Errno 2] No such file or directory: ‘/usr/lib/python2.7/sitecustomize.py’ error again. I navigated using cd /usr/lib/python2.7/ then executed ls.

to my surprize "sitecustomize.py" was in the list in red. I think it was a symlink and main file was deleted during update. So I removed symlink and copied main file I found in "/home/remastersys/remastersys/dummysys/etc/python2.7/sitecustomize.py" into " /usr/lib/python2.7/" then ran sudo dpkg --configure -a. Problem fixed.

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.