Logo 
Search:

Unix / Linux / Ubuntu Forum

Ask Question   UnAnswered
Home » Forum » Unix / Linux / Ubuntu       RSS Feeds

quick fix for xorg.conf problems from PCLOS Mag

  Date: Dec 27    Category: Unix / Linux / Ubuntu    Views: 427
  

Quick fix for damaged Xorg.conf by vampirefo

My one daughter was trying her hand on updating her graphic card drivers
and got locked out of KDE, eg, she damaged her xorg.conf. LOL we all
been there.

So I wrote this for her so at least she can get her desktop back.

How this works:

1. Go to /etc/X11/xorg.conf as "root", right click xorg.conf, select copy,
name the copy xorg.conf.bak

2.Copy and paste the script found below into Kwrite or your favorite editor
and save in /. I called hers “fix_xorg”, call yours what you want.

3.When you have a problem and you can't login due to xorg.conf problems
you just get a command login, type root <Enter> and then your root password
<Enter>

4.Next, just type /fix_xorg or what ever name you called it, and in just a few
seconds you should be in the root KDE desktop.

5.You can now just end session and type reboot if you want and after reboot
login to your user account.

6.Each time you make an adjustment to your xorg.conf and you like the
adjustment, and you can login, just delete your old xorg.conf.bak and make
a new one from your current working xorg.conf.

7.This way you always have a backup of your most current working xorg.conf,
just in case something goes wrong, you can quickly fix it.

Script:

#!/bin/sh
filename=/etc/X11/xorg.conf.bak
if [ -f "$filename" ]
then
rm -f /etc/X11/xorg.conf
cp /etc/X11/xorg.conf.bak
/etc/X11/xorg.conf
sleep 2
startx
fi


Not being much of a commandline guy I like anything that can help me fix
problems without too much effort. If you feel the same way maybe you can try
this script. Thanks to PCLOS magazine, May 2008. It can be found at:
http://pclosmag.com/html/enter.html. Ubuntu users will have to use sudo su or
sudo -i to have root privileges.


Share: 

 

No Answers Found. Be the First, To Post Answer.

 
Didn't find what you were looking for? Find more on quick fix for xorg.conf problems from PCLOS Mag Or get search suggestion and latest updates.




Tagged: