Categories
Linux Mastering Development Ubuntu

Ubuntu 18.04 Terminal, Software & Updates, Software Updater not working

I’m new to Linux/Ubuntu. It’s been a few days since I was on my computer, but the Terminal, Software & Updates, Software Updater not working when I fired it up. (Ubuntu 18.04)

I have been using this computer mainly to learn about Linux and coding Python using PyCharm as a hobby so the only software on this system, other than “out of the box” Ubuntu 18.04 is Pycharm and Kite as well as some libraries for coding.

I have tried restarting and a hard reboot. In the top right corner an error “A problem has occurred when checking for updates.” I can’t interact with any of it except toggling “Show notifications”. Clicking on “Show updates” or “Preferences” does nothing.

When I try to open the Terminal by using Ctrl-Alt-T nothing happens. When I click on the Terminal icon I get a spinning icon for about thirty seconds and it show up in the “Activities” area in the top left, but then crashes with no message.

I have been able to access the Terminal through PyCharm. I deactivated the virtual environment and got to my root directory. From there I tried ‘sudo apt-get update’ and received an error:
ModuleNotFoundError: No module named ‘apt_pkg’python

I think what happened is that the last time I was using this computer, I saw some notifications saying I needed to upgrade from python 3.6.9 due to security issues. I was able to upgrade to 3.7.5, but I ran into issues with it using the wrong version as my default. I followed a guide I found online to change it and everything seemed to be working fine. I suspect I somehow either overwrote, uninstalled, or otherwise led my system to overlook Python 2.7–which, as I understand it, is what the terminal and updater would be looking for.

In the terminal session in PyCharm I can’t even get a python version for python to show up.
This code, python --version return the “No module named ‘apt_pkg’ error, however, running python3 --version tells me the version…Python 3.7.5

I have no idea how to rollback the changes I made or make the appropriate changes. Any help would be appreciated. Thanks in advance!

Update:
I’ve also been looking throughout my system to find where Python2 is (or where I think it should be). In /usr/bin/ there are the other versions of Python, but no 2.7. At this point I’m considering just saving my files to a thumbnail and reinstalling Ubuntu.

looking in /usr/bin/ this is what I see: enter image description here

Leave a Reply

Your email address will not be published. Required fields are marked *