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.