Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 4 Jun 2007 10:30:52 -0400
From:      John Nielsen <lists@jnielsen.net>
To:        freebsd-questions@freebsd.org
Cc:        Jim Capozzoli <saltmiser@gmail.com>
Subject:   Re: X11 & console setup
Message-ID:  <200706041030.52444.lists@jnielsen.net>
In-Reply-To: <4661CC79.1020608@daleco.biz>
References:  <37f72b1f0706021126g3347c683u37a87d3145e6e571@mail.gmail.com> <4661CC79.1020608@daleco.biz>

next in thread | previous in thread | raw e-mail | index | archive | help
On Saturday 02 June 2007 04:00:57 pm Kevin Kinsey wrote:
> Jim Capozzoli wrote:
> > Hello list,
> >
> > I have 3 monitors and 3 video cards.  However, one videocard and
> > monitor isn't very "X11 friendly." (X11 barely starts on it).  I was
> > wondering if it would be possible to have X11 running on two of the
> > monitors, and then have a full screen console (like a ttyv0) on the
> > third monitor (so I could constantly leave top or something sweet
> > running on there :D).  This is all with FreeBSD 6.2/i386 and Xorg 6.9
> > or 7.2.  Any suggestions?  Thanks.
>
> It should do "do-able", perhaps somewhat easily. 
> /usr/ports/x11-servers/x2x is what comes to mind --- IIRC, Greg "groggy"
> Lehey of "The Complete FreeBSD" fame uses this for several displays, and
> has notes on his setup in her personal pages at www.lemis.com.

That link is here: http://www.lemis.com/grog/hardware.html

However, I'm not sure x2x is relevant to the OP--It can be used to allow one 
mouse and keyboard to be used on multiple X servers, but doesn't have 
anything to do with console mode.

I don't know if the setup the OP wants is possible or not, but here are some 
notes:

The FreeBSD console always runs on the "primary" display as determined by the 
BIOS. Most systems give you a choice between using AGP or PCI as the primary 
display. If you have multiple PCI cards it is usually the first one on the 
bus (physically this is often the one closest to the CPU). Not sure how ISA 
figures in. You will want to make your "bad" videocard and monitor the 
primary display.

Once you have that, I'd just run an "Xorg -configure" to get started. If X 
comes up at all using the config generated from that then it will be a good 
starting point. Try commenting out the device and screen sections (and 
possibly also a line under ServerLayout) for your "bad" display and see if X 
comes up on the other two. By default it expects to be running on the console 
so I'm not sure what will happen here. You also want it to grab the keyboard 
and mouse unless you have a second keyboard. Some trial and error and further 
research are probably required. Play with startx vs xdm, see what happens 
when you press ctrl-alt-f1, etc. I'm assuming you'll want to use Xinerama to 
join the two X displays and allow window-dragging between them, etc.

If you don't get acceptable results using your original plan, you can always 
hack together your own "console" to run on the weakest display under X (using 
the vesa driver if necessary). If possible (not sure it is), don't make it 
part of your Xinerama display. Then don't run a window manager on it. Use 
xsetroot as part of your X init script to control what's on the background. 
This will apply to your entire display but the WM will probably take over 
once it starts on the "good" screens. You could make one or more scripts to 
run things on your "bad" screen by doing something like this:

#!/bin/sh
DISPLAY=:0.1	#might also be :0.2 or :0.0
export DISPLAY
xterm -r -geometry 120x60 /usr/bin/top

Experiment with the geometry settings to see what fills your screen 
appropriately. You might also want to get a nice bitmap font to give the 
xterm more of a terminal "feel". I have one I stole from bochs or somewhere 
that's not bad (I use it for Nethack). E-mail me off-list if you want it.

That should just about do it. Do write back to the list to tell us what you 
learn and what works the best.

JN



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200706041030.52444.lists>