[Linux/Ubuntu] How to fix graphic issues (nvidia display)

Hi,

Sometimes after usual system update/upgrade your graphic drivers can also get updated. On some occasions you may have few issues after such update including for example:

  • cannot login to the system
  • blank screen / black screen
  • login loop
  • and simialar

In order to fix it you will need to login to separate console, so first thing is:

CTRL + ALT + F2

And then try the following actions:

  • sudo apt-get update
  • sudo apt-get upgrade
  • sudo apt-get install gdm 
  • sudo dpkg-reconfigure lightdm // and choose lighttdm
  • sudo apt-get purge nvidia* // remove nvidia
  • sudo apt-get dist-upgrade
  • sudo apt-get install nvidia-current
  • sudo update-alternative --config i386-linux-gnu_gl_conf // or x86_64-linux-gnu_gl_conf 
  • // find out which version you got nvidia-xxx
  • then: sudo apt-get install nvidia-xxx-updates
  • sudo nvidia-xconfig
  • sudo reboot

A bit of command chaos but it did the trick :)