My Linux  Mint 13 64-bit system has developed a problem. Whilst I can run basic commands like ls and vi if I try anything more complex (I have tried python2.7, mysql-workbench and addusr) I get:-Could not find platform independent libraries <prefix>Could not find platform dependent libraries <exec_prefix>Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]ImportError: No module named siteI went to another system (Mint 13 32-bit) and ran:-# echo $PYTHONHOME,and got a blank line so no idea what<prefix>[:<exec_prefix>]are?Unsure where to go next?After further Googling I tried both sudo dpkg configure -a and sudo apt-get install -f  with the following results:-HP-255-G1 # sudo dpkg --configure -adpkg: dependency problems prevent configuration of python-appindicator:python-appindicator depends on libappindicator1 (= 0.4.92-0ubuntu1);however:Version of libappindicator1 on system is 0.4.92-0ubuntu1.1.dpkg: error processing python-appindicator (--configure):dependency problems - leaving unconfigureddpkg: dependency problems prevent configuration of python-uno:python-uno depends on libreoffice-core (= 1:3.5.2-2ubuntu1); however:Version of libreoffice-core on system is 1:3.5.7-0ubuntu7.dpkg: error processing python-uno (--configure):dependency problems - leaving unconfiguredErrors were encountered while processing:python-appindicatorpython-unoHP-255-G1 # sudo apt-get install -fReading package lists... DoneBuilding dependency tree Reading state information... DoneCorrecting dependencies... DoneThe following extra packages will be installed:python-appindicator python-unoThe following packages will be upgraded:python-appindicator python-uno2 upgraded, 0 newly installed, 0 to remove and 690 not upgraded.2 not fully installed or removed.E: Could not get lock /var/cache/apt/archives/lock - open (11: Resource temporarily unavailable)E: Unable to lock directory /var/cache/apt/archives/So it looks as if python-uno and python-appindicator are central to some of the issues but where to now?Here is the requested output:-HP-255-G1# apt-cache policy python-uno python-appindicatorpython-uno:Installed: 1:3.5.2-2ubuntu1Candidate: 1:3.5.7-0ubuntu7Version table:1:3.5.7-0ubuntu7 0500 http://archive.ubuntu.com/ubuntu/ precise-updates/main amd64 Packages500 http://security.ubuntu.com/ubuntu/ precise-security/main amd64 Packages*** 1:3.5.2-2ubuntu1 0500 http://archive.ubuntu.com/ubuntu/ precise/main amd64 Packages100 /var/lib/dpkg/statuspython-appindicator:Installed: 0.4.92-0ubuntu1Candidate: 0.4.92-0ubuntu1.1Version table:0.4.92-0ubuntu1.1 0500 http://archive.ubuntu.com/ubuntu/ precise-updates/main amd64 Packages*** 0.4.92-0ubuntu1 0500 http://archive.ubuntu.com/ubuntu/ precise/main amd64 Packages100 /var/lib/dpkg/statusI managed to get the Synaptic Package Manager running from the command line and tried to update python-uno and python-appindicator. This failed but hopefully the output (below) is another clue:-E: /var/cache/apt/archives/python-appindicator_0.4.92-0ubuntu1.1_amd64.deb:subprocess new pre-removal script returned error exit status 1E: /var/cache/apt/archives/python-uno_1%3a3.5.7-0ubuntu7_amd64.deb:subprocess new pre-removal script returned error exit status 1
Linux Mint 13 Problem - No module named site
linux mint;python;libraries
After discussion with the poster on chat, starting http://chat.stackexchange.com/transcript/message/20047753#20047753, it turned out the poster's machine is missing /usr/lib/python2.7, see http://chat.stackexchange.com/transcript/message/20052960#20052960. This accounts for most of the poster's problems. In particular, the errors:Could not find platform independent libraries <prefix>Could not find platform dependent libraries <exec_prefix>Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]ImportError: No module named sitestem from these missing libraries.The next thing to do is to restore the base Python libraries under /usr/lib/python2.7. One way to do this is to download the deb files corresponding to python2.7, python2.7-minimal and libpython2.7, and then install them using dpkg -i. I.e.apt-get download python2.7 python2.7-minimal libpython2.7dpkg -i python*.debOnce this is done, hopefully the package system will stop freaking out. Then install debsums, if it is not already installed, and restore the remaining missing files using debsums -as.