Note: This is not for the older versions of Ubuntu.

1. Go to Nvidia site and download the driver for your model.

2. Save the driver somewhere on your file system, that may be your home folder or /opt.

3. Press Ctrl+Alt+F1 and go to terminal. Enter terminal as root.

4. Then to end xserver, More >