I have gpm as my mouse service in X now. However, try
as I might... I could not activate the special
command. How do I do this? I read the man page and
came up with the line
-S ":reboot:/usr/bin/kbd_mode -a"'
this should allow left click to kill init, middle
click to reboot the system and right click to take
over the keyboard. Unfortunately I don't know where to
put this script where it will work. I tried inputing
it into the gpm script like this:
if [ -n "$MOUSETYPE" ]; then
daemon gpm -t $MOUSETYPE -m $MOUSEDEVICE -S
":reboot:/usr/bin/kbd_mode -a"'
else
daemon gpm -m $MOUSEDEVICE
fi
but I got error messages like this:
/etc/init.d/gpm: line 49: unexpected EOF while looking
for matching `''
/etc/init.d/gpm: line 81: syntax error: unexpected end
of file
I don't know where else I would put that command. I
tried removing the end ' but that just caused it to
execute the command and fail to start gpm (no mouse).
I love the idea though and would like to implement it!
I saw something in /etc/gpm-root that looked
interesting though...and maybe this might be the place
to do it....although I am not completely sure what it
is saying....
# I use this to halt and reboot the system, but it
isn't wise to put it
# in widely accessible boxes.
#
# "----" f.nop
# "" f.nop
# "halt" f.bgcmd "/sbin/shutdown -h now"
# "reboot" f.bgcmd "/sbin/shutdown -r now"
# "keyboard" f.bgcmd "/usr/bin/kbd_mode -a"
}
I have it inactivated at the moment although when I
had it in there I did not get any response when I did
the triple left/right click. I added in the keyboard
trick to the original line.
--- Michael Brown <[EMAIL PROTECTED]>
wrote:
> On Fri, 25 May 2001, SI Reasoning wrote:
> > I cannot get XFdrake to properly read my
> system.with
> > the new XFree86. First it does not give the 3.3.6
> or 4
> > choice anymore. Then after it asks questions and I
> set
> > it to config that I always do, it will totally
> lock up
> > the system when doing the test until I have to
> hard
> > reboot. Immediately upon X the first thing I
> notice is
> > that the mouse does not work, then I notice that
> > nothing else does either including our favorite
> ctrl +
> > Alt + BS.Often after such a hard lock, the system
> will
> > kick out to maintenance where I have to do a
> manual fsck.
>
> Not a solution, but something that might come in
> handy:
>
> Executing the command "/usr/bin/kbd_mode -a" will
> take away XF86's control
> of the keyboard, and you can then use Alt-F1 to get
> back to a console and
> find out what's going wrong with X. If you use
> gpm's repeater mode
> (rather than letting X talk to the mouse directly),
> then you can use gpm's
> "Special commands" feature which enables you to
> associate commands with
> unlikely mouse sequences (such as triple-clicks).
> You can therefore set
> up gpm to execute "/usr/bin/kbd_mode -a" if you e.g.
> triple-click both
> buttons then wait for a beep and click the left
> button again, thus giving
> you a handy escape route if XF86 freezes up.
>
> Incidentally, I've found that mouse behaviour in X
> is a lot better when
> routed via gpm - X refused to acknowledge the middle
> button on some mice
> but gpm picked it up happily and forwarded it to X
> in a way that X
> understood. Using gpm also means that you can plug
> the mouse in after
> starting X, or even change from a serial to a PS/2
> mouse in the middle of
> an X session.
>
> HTH,
>
> Michael
>
>
=====
SI Reasoning
[EMAIL PROTECTED]
gnupg/pgp key id 035213BC
__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices
http://auctions.yahoo.com/