LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   When I try to start up X on lmde I get an error, also I nuked my /etc/X11 . . . (http://www.linuxquestions.org/questions/linux-software-2/when-i-try-to-start-up-x-on-lmde-i-get-an-error-also-i-nuked-my-etc-x11-897005/)

darkstarbyte 08-12-2011 01:40 PM

When I try to start up X on lmde I get an error, also I nuked my /etc/X11 . . .
 
When I try to start up X on lmde I get an error, also I nuked my /etc/X11 directory with rm * by mistake. (I thought I was in my home directory and I was deleting a nvidia driver.) On my laptop I transfered over the files from my /etc/X11 directory and had a boken symbolic link. I am unsure how to fix it but I have tried. the symbolic link being X. I removed it and replaced with "ln -s /usr/bin/X /etc/X11/X".

I am trying to install the proprietary nvidia drivers from nvidias' site, only do to the fact that lmde does not have a nvidia driver for the latest kernel version. I was told that they have to match up or it will not work, which it didn't. Then I was also told that to get it off the site. That seemed easy enough it installed but I did forget I was in the /etc/X11 directory, because I was taking a look at the X configuration file. I tried to delete the NVIDIA-Linux-x86-280.13.run file with rm * and I removed every non directory file in "/etc/X11/".

After all of that chaos I tried to startx, and I got these results.

X: /etc/X11/X points back to a X wrapper executable, aborting.
xinit: giving up
xinit: unable to connect to X server: Connection refused
xinit: server error

Tell me if you need more information.

qlue 08-12-2011 04:31 PM

At this point I'd re-install as that will probably be easier than re-building /etc/X11

darkstarbyte 08-12-2011 05:59 PM

That was not the answer I was hoping for.

bigrigdriver 08-12-2011 06:10 PM

Are you able to boot into runleve 3? If so, you could boot a liveCD and download the xorg packages to your hard drive, then boot to runlevel 3 and try to install them via dpkg or apt. You would have to edit /etc/apt/sources.list to add the path to the files at the top of the sources.list. I'm not sure how to do it using dpkg.

Quote:

I am unsure how to fix it but I have tried. the symbolic link being X. I removed it and replaced with "ln -s /usr/bin/X /etc/X11/X".
This isn't likely to work in any event. /usr/bin holds executables; /etc/* holds config files.
Quote:

I nuked my /etc/X11 directory with rm * by mistake. (I thought I was in my home directory and I was deleting a nvidia driver.)
I'd suggest you modify the PS1 prompt lines in both your user and root .bashrc files to:
a) change the color of your prompt when switching from user to root as a warning that great damage may happen from one careless keypress
b) add the pwd (present working directory) to your bash prompt so that you will always know where in the directory tree you are when working from the command line. If that makes the prompt longer than you like for issuing commands, add a \n (newline) at the end of the PS1 to show the prompt with pwd, then move the cursor to the line below the prompt.
c) make it a habit when using dangerous commands like rm to always give the path to the file (or directory of files) that you want to rm.

One learns to do simple things like in the School of Hard Knocks. But it can save you from yourself.

darkstarbyte 08-13-2011 01:04 AM

I learned my lesson. Make a back up, back up the backup, and make another one.


All times are GMT -5. The time now is 03:39 AM.