xorg settings on diskless client

Suppose you have diskless stations with different graphics cards but that you loaded the kernel module for the card at boot-up.

The user's home directory is also nfs mounted at /home

Trying to start a window-manager fails because the initial ~/xorg.conf settings don't match the properties of the card on the diskless client. What can be done here?
- Do you modify xorg.conf with conditionals?
- Do you modify something like ~/.login.conf to check IP's of host and run xorg-IP.conf?
 
I do this by having multiple xorg.conf files in /usr.local.etc/X11 and creating the corresponding symlink based by the hostname after mounting /usr.local.etc to /usr/local/etc with nullfs with a service script.
 
I got it working - The video driver had not loaded for some reason. When I kldload'ed it, the screen came up. The mouse is not working however, even though I started dmesg, hald and moused before startx (mouse works in the tty's)

@xibo: Sounds like a neat idea, although I'm not sure I quite get the details. So for each diskless station (IP's ending in 10-20) you place xorg10.conf, xorg11.conf, etc in /someplace/X11. But why do you mount_nullfs that folder and I also do not understand where you do this:
and creating the corresponding symlink based by the hostname
 
I'm using xorg.conf.foo and xorg.conf.bar for systems foo and bar, and then [cmd="ln"] -s xorg.conf.`hostname -s` xorg.conf[/cmd] it, which is basically the same as the inet-address approach without the need to sed.

I'm mounting it via nullfs because I'm not having a 'dedicated' /usr/local for the NFS root - instead, I'm sharing the boot server's one (as I don't have any ``secret'' data stored there to begin with). And since it's shared readonly, and the client might need to modify elements in /usr/local/etc, each client gets a local copy of it.

Most probably it would be smarter to use unionfs for this purpose.

I also didn't have a working mouse or keyboard in X11 when booting to NFS root. In fact, hald service is making output about paging-errors when started, so I disabled AllowEmptyInput like everyone else does when suspecting hald issues, and the HIDs are working ever since ;)
 
@wblock: I think my error is from hald, since I have no "work-arounds" to bypass it.
just let xorg-server use hald by default
Which is what I'm doing! Diskless clients boot from a separate world (pxeboot), /usr is mounted nfs/ro from boot server's usr, var is a cpio.gz mounted with md. Am I missing a setting in sysctl.conf?

@xibo: OK, so you are doing the same thing for /usr/local/etc that the handbook suggests for /etc. You did it with nullfs, I'm doing it by md-mounting conf/<IP>/var.cpio.gz. I just did not want to create a second gz for etc is all. In my original question, I had client-machine and client-users confused and was thinking about putting the config in /home/username - which is silly of course. As I noted, confused the 2 client types.
 
Beeblebrox said:
@wblock: I think my error is from hald, since I have no "work-arounds" to bypass it.

That was to tell the story of why AEI is bad and not to use it.

xorg does not need hal at all. AutoAddDevices Off can be used to disable it with xorg, or xorg-server can be built with the HAL option turned off.
 
"AAD Off" at least got the keyboard working and I now have some semblance of control through the arrow key which at least brings up the application menu - but the mouse is still out.
/var/log/Xorg.0.log gets created (didn't before), log shows mouse entry and this:
Code:
(EE) config/hal: couldn't initialize context: unknown error
 
That error is normal and can be ignored. Rebuilding xorg-server without hal should make it go away entirely.

As far as the mouse goes, it depends. First, consider removing the mouse device entries in xorg.conf in case it isn't using standard values. xorg will still detect and use the mouse on startup. PS/2 mice need to have moused enabled in /etc/rc.conf. USB mice automatically run moused via devd, if devd is running.
 
Back
Top