Started A Blog Today…

So I started a blog today. I’m not sure if I’ll really give it the attention that it’ll need but heck I sometimes feel like sharing my thoughts. Anyway I started this blog because I was updating my computer last night and it crashed. I couldn’t find readily how to fix it so I wanted to detail the process that I went through. And here we go.

So last night my computer popped up a message telling me that there was an update available for Ubuntu so naturally I felt obliged to update to the new version. I was heading out anyway so I figured I’d let it run while I was out of the house. So I clicked update, waited for the prompts for permission that I figured it’d request and then closed everything else out. When I closed out Chome though, I noticed that the screen went black. “Eh I’m sure it’s just updating the video driver or something” and off I went. I came back later last night and the screen was still black. It was on (not in sleep mode) but it was just black. So I unplugged the cable for the screen and plugged it back in. Well now the monitor just went to sleep mode. Something bad has obviously happened but I don’t really feel like going through the troubleshooting process. To bed I go.

So after much procrastination I’ve come to troubleshooting my computer. As it is always the first step you should do I should restart the computer. Did I? No. I logged into my router so that I could maybe ssh into the computer and see if I could just save myself the effort of troubleshooting anything. (After 20-60 minutes… Seriously Linksys/Cisco we need to have a talk) I get the IP of my computer on the network and try to ssh in. NOPE. No success of course. Do we restart now? Okay fine. We’ll restart.

Purple screen pops up, Ubuntu is loading, awesome! Boom, black screen again. Okay but we have ways to make you talk Mr. Computer… CTRL + ALT + F1… Seriously? Nothing still? Ugh okay… I’m going to have to reinstall Ubuntu or something, this is frustrating. But before that let’s see if anyone else has had this issue before. I’m sure I’m not the first guy. Yay for StackExchange! Step one, boot into recovery. Cool let’s do this.

Hold CTRL [While booting (purple screen before the Ubuntu logo)] — JamesTheAwesomeDude

Nope, It’s just loading Ubuntu into a black screen… Let’s see what Ubuntu has to say about this

Quickly press and hold the Shift key, which will bring up the GNU GRUB menu. (If you see the Ubuntu logo, you’ve missed the point where you can enter the GRUB menu.) —Ubuntu Wiki

Still nope. Did I mess up GRUB? Sigh. Maybe I’ll just repeatedly hit both Shift keys and both CTRL keys until something happens like I did in my Windows days. Dun dun! I’m into the boot menu. For the record, and I did want to know the proper thing to do, I had success because of tapping the shift key. Anyway on we go, what’s next?

You should see a screen with a purple background (sometimes it’s black) and a few options. One of these is labeled as a “Recovery Mode”. Choose it.

During the startup, you’ll see a bunch of text on the screen, maybe some errors. Don’t panic. Once it finishes, choose “Drop to root shell prompt”.  — JamesTheAwesomeDude

Sweet we’re in! Okay now to the bottom of his answer where we’re repairing Ubuntu. Cool just 4 commands.

dpkg-reconfigure -a
apt-get updateapt-get dist-upgrade
reboot

Well before we get into this let’s make sure we have internets.

ping 192.168.1.1
No network
sudo ifconfig eth0 upsudo dhclient eth0
ping 192.168.1.1

Success! Now to the script.

dpkg-reconfigure -a
(Brings up dpkg reconfigure flag help… okay well let’s just move on)
apt-get update
(Read only error. Alllrrriiiggghhhttt…. Let’s see here… Ah we gotta remount the drive)
mount -o remount,rw /apt-get update
(Yay it’s doing something… nope error’d but I got the correct command that I need to run!)
dpkg -configure –a
(Success, moving on…)
apt-get update
(Updates the repos)
apt-get dist-upgrade

Error getting authority: Error initializing authority: Could not connect: No such file or directory (g-io-error-quark, 1)
Error getting authority: Error initializing authority: Could not connect: No such file or directory (g-io-error-quark, 1)
[  OK  ] Started Braille Device Support.

(Somethings’ happening! Aannnd we’re frozen. Looks like a total of one other person has had this error before. And he’s posted about it. But there are no answers.  Alright well I guess I’ll just move on)
Restart

And just like that Ubuntu booted into the desktop environment. But for safe measures I went through the four steps of fixing a botched upgrade and resarted again. This time I had no issues the entire way though. Yay. I hope that this article will help someone out there who thinks they’ve broken their OS with an upgrade or if you’re just trying to get into the recovery menu. Below is the steps I took to get it working again without the comments. I think that the step that solved my problems was the dpkg reconfigure because that’s the only step that really did anything successfully.


TL;DR Steps

  1. Press shift to open the grub menu (or hold shift or hold ctrl or smash different keys ’till it works)
  2. Test for internet: ping 192.168.1.1
    If you don’t have internet:
    sudo ifconfig eth0 up
    sudo dhclient eth0
    Might be wlan0 if you have wifi – I think that’s the name. You could always find your device via ifconfig.
  3. mount -o remount,rw /
  4. dpkg -configure –a (or dpkg-reconfigure -a)
  5. You might try restarting to see if your problem has been fixed by this point if not you’ll want to just continue from here.
  6. sudo apt-get upgrade
  7. sudo apt-get dist-upgrade
  8. reboot

That’s what worked for me. Feel free to drop a comment if something else worked for you!

Cheers!