# Complex X11 Problem



## wafflesausage (Dec 23, 2010)

I recently screwed up my FreeBSD workstation and have been trying, with little luck, to restore it to its previous settings. At this point, the only remaining problem (that I know of at least) is getting X11 to work. Startx only works with root, but the keyboard and mouse don't work, X11 will only start for non-root users if it's invoked by xinit- the keyboard and mouse don't work here either. When I try to startx as a non-root user I get a looped error stating "No protocol specified". I have enabled dbus and hald in /etc/rc.conf, gone through all the usual steps to getting X up and running, and I am at a complete loss as to what to do. I am considering completely removing and reinstalling anything that has to do with X11. Does anyone have knowledge as to how one would go about doing this or perhaps be able to suggest an alternative?
Any and all help would be greatly appreciated


----------



## wblock@ (Dec 23, 2010)

If X runs as root, it's okay.  Ignore the mouse and keyboard for now, one thing at a time.  So the problem becomes how to find out what's wrong with your user.  As your user, what do echo $HOME and echo $DISPLAY say?


----------



## wafflesausage (Dec 23, 2010)

echo $HOME returns an expected /home/lucer, echo $DISPLAY returns a blank line.


----------



## wblock@ (Dec 23, 2010)

Let's start with the basics.  Please show your xorg.conf and /var/log/Xorg.0.log from when you try to startx as a normal user.  It might also be useful to use script(1) to capture the session where you're trying to start X (HowTo).


----------



## wafflesausage (Dec 23, 2010)

Strangely enough I don't have a /etc/xorg.conf file.
The contents of my /var/log/Xorg.0.log can be found here http://pastebin.com/kcwxVe86


----------



## wblock@ (Dec 23, 2010)

An easy test: create a new user, with all the defaults.  Does startx work for that user?


----------



## wafflesausage (Dec 23, 2010)

When I run X with the new user, I get lines of error messages saying 
	
	



```
Shared object "libXau.so.6" not found
```


----------



## wafflesausage (Dec 23, 2010)

Also, for the new user, I get similar error messages for zsh.


----------



## SirDice (Dec 23, 2010)

wafflesausage said:
			
		

> When I run X with the new user, I get lines of error messages saying Shared object "libXau.so.6" not found.



Try reinstalling x11/libXau.


----------



## wblock@ (Dec 23, 2010)

wafflesausage said:
			
		

> Also, for the new user, I get similar error messages for zsh.



Well, it's something.  Avoid changes to the new user's default shell, .cshrc, and in fact anything environment-related for now.  That will eliminate that stuff as a problem.


----------



## wafflesausage (Dec 24, 2010)

The problem's been solved, but the solution was drastic and unelegant. I just whipped up a set up script and reinstalled the whole system. There were more problems with it than just X, and I figured a fresh install would do me better. I've learned my lesson and will be preserving permissions in my following backups.


----------

