Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

So I managed to fairly severely mess up my graphics card driver. I was trying to install OpenCL using instructions from here: http://orbigo.net/2012/07/installing-nvidia-opencl-cuda-sdk-in-ubuntu-12-04-lts/

I dropped down to a shell using ctrl+alt+F1, and stopped the lightdm service. Then I ran the file from nVidia. For some reason I thought it would be a good idea to install the driver that came with the package. When I tried to restart lightdm after this, my system showed the ubuntu splash screen and then froze up with a black screen with a blinking cursor. I then tried to reboot my computer, but it seems to lock up while starting up. I get the Ubuntu splash screen, but then I get a black screen listing a bunch of services that have been started. The last service on this list is lightdm, which it says started ok, but it seems to freeze after that.

I believe Ubuntu has some sort of recovery option on the grub menu, so I tried loading into that. The problem here is that I can't seem to get into the grub menu. It appears to be the same issue as this: Grub Menu doesn't appear when pressing SHIFT

I booted up using a LiveCD with Ubuntu 12.04 on it, and tried fixing the grub as per the answer I linked. Unfortunately because I'm running off a LiveCD, it doesn't seem to like the update-grup step, since the boot table is different or something like that... I get the error: error: cannot find a device for / (is /dev mounted?). when I try this. I also tried grub-install /dev/sda but I seem to get the same error here.

I'm running Ubuntu 12.10. I forget exactly what graphics card I have, but it's an older (~6 years or so?) nVidia one. There aren't any other OS's installed on my machine.

Any help to get my computer back into a usable state without having to reinstall the OS would be appreciated.

UPDATE: I have managed to fix grub using the boot-repair tool, and can get into recovery mode. Now I just have to figure out how to fix my graphics card driver from here. The root terminal option is working.

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

I managed to resolve this issue. The first step was to fix grub such that I could boot into recovery mode. I did this using an Ubuntu 12.04 LiveCD, as outlined here:

https://help.ubuntu.com/community/RecoveringUbuntuAfterInstallingWindows

I used the graphical method (boot-repair).

Once grub was repaired, I rebooted my computer (removing the LiveCD), and booted into recovery mode (from the grub menu, I selected advanced boot options for ubuntu, and then the recovery mode for the most recent kernel version (the second option from this menu)).

From recovery mode, I selected the "network" option to enable networking. This took about 5 mins or so to actually connect to the network, and wasn't very obvious that it was actually working. Once networking was enabled, I selected the "root" option to drop to terminal. From here, I ran the following command:

apt-get install nvidia-current --reinstall

Which reinstalled my graphics card driver. I also reinstalled lightdm (apt-get install lightdm --reinstall), although I'm not sure as to whether or not this was actually helpful.

At this point I rebooted the computer with the command reboot, and everything was back to normal.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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