Alan Hargreaves' Blog

The ramblings of a former Australian SaND TSC* Principal Field Technologist

Dual Head gotcha in build 37 on sparc

On my desk I have a dual headed Ultra 80. Until now, I’ve managed to run dual headed by having the following line in the bottom of /etc/dt/config/Xservers (line broken for clarity, it’s a single line in the file.

:0   Local local_uid@console root /usr/openwin/bin/Xsun :0 -nobanner\
-dev /dev/fb0 right defdepth 24 -dev /dev/fb1 left defdepth 24

However, it looks like as of b37, the legacy dtlogin startup scripts have been removed from all but /etc/init.d

OK, I could have put the symlinks back but this seemed like a good opportunity to switch.

Now after a lot of digging, I noticed the following code in /usr/X11/bin/Xserver.

99  getprop options/server_args
100  if [ "$PROPVAL" != "" ] ; then
102  fi

If we go back to find the getprop function, we see that it does a svcprop -q -p options/server_args application/x11/x11-server to get this value.

Digging in to the smf documentation I find that all I should need to do is

# svccfg -s application/x11/x11-server
svc:/application/x11/x11-server> listprop options/*
options/default_depth        integer  24
options/server               astring  /usr/openwin/bin/Xsun
options/stability            astring  Evolving
options/tcp_listen           boolean  true
options/value_authorization  astring  solaris.smf.manage.x11
options/server_args          astring
svc:/application/x11/x11-server> setprop options/server_args =
"-dev /dev/fb0 right defdepth 24 -dev /dev/fb1 left defdepth 24"
Note: line broken for clarity, this was typed as a single line.
svc:/application/x11/x11-server> listprop options/server_args
options/server_args  astring  "-dev /dev/fb0 right defdepth 24 -dev /dev/fb1 left defdepth 24"
svc:/application/x11/x11-server> end

Unfortunately, on restarting gdm2-login, I now find that it won’t start at all. A little more searching showed up:

6218143 Xserver doesn’t parse SMF server_args correctly

Until this one gets fixed (which should be a pretty simple fix), the only workaround (unless I want to go back to dtlogin) is to go in and modify /etc/X11/gdm/gdm.conf.

We need to add the arguments directly to where we call /usr/X11/bin/Xserver. This turns out to be the second instance of Xserver in the file (Standard server). The first is the failsafe (we don’t want to play with that), the third and fourth are for Terminal Server and Chooser respectively. I changed the line to read as follows:

command=/usr/X11/bin/Xserver -audit 0 -nobanner -dev /dev/fb0\
right defdepth 24 -dev /dev/fb1 left defdepth 24
Note: line broken for clarity, this was typed as a single line.

Oh yes, you’ll want to take the setting out of application/x11/x11-server.

# svccfg -s application/x11/x11-server
svc:/application/x11/x11-server> setprop options/server_args = ""
svc:/application/x11/x11-server> end

Well that’s at least gotten me running with the dual screens again, it only took me about three and a half hours to work out (sigh). Let’s hope the bug is fixed quickly so we can do this correctly. It might also be nice to see some documentation of how to get SPARC machines running in multiheaded configurations.

Technorati Tags:


Written by Alan

April 9, 2006 at 8:07 pm

Posted in OpenSolaris

One Response

Subscribe to comments with RSS.

  1. The instructions for setting up dual headed SPARC configurations are the same today as they’ve been since dtlogin was added to Solaris 2.6 – as long as you stick with dtlogin. The change in current Nevada builds is simply that dtlogin links in the /etc/rc*.d directories were replaced with a proper SMF service.
    (and yes, the Xserver script SMF args fix should be easy, it’s just been low enough priority to not hit the top of my to-do list yet)

    Alan Coopersmith

    April 10, 2006 at 10:57 am

Comments are closed.

%d bloggers like this: