How to Fix Xorg.Conf
- 1). Boot in to Ubuntu. Press "Ctrl," "Alt" and "F2" to switch to TTY2, an alternate command-line console.
- 2). Enter an administrator's login name and password. Input "cd /etc/X11/" into the console, then press "Enter."
- 3). Input "sudo mv xorg.conf /home/xorg.conf.old" into the console. Press "Enter" to rename the existing Xorg configuration file.
- 4). Input one the following commands to stop the GNOME, GNOME3, KDE or X Windows System desktop manager, then press "Enter.". Use "GMD" or "GDM3" for GNOME or GNOME3, "KDM" for KDE and "XDM" for X Windows System:
sudo service gdm stop
sudo service gdm3 stop
sudo service kdm stop
sudo service xdm stop - 5). Type the following command into the console to restore the xorg.conf file, then press "Enter":
sudo Xorg -configure - 6). Input "sudo cp xorg.conf.new /etc/X11/xorg.conf" into the command-line terminal, and then press "Enter" to fix xorg.conf.
- 7). Type "sudo startx," then press "Enter" to initialize Xorg. Input "sudo service gdm start" into the terminal, then press "Enter" to restore the graphical user interface.
Source...