From mboxrd@z Thu Jan  1 00:00:00 1970
Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org)
	by finch.gentoo.org with esmtp (Exim 4.60)
	(envelope-from <gentoo-user+bounces-95771-garchives=archives.gentoo.org@lists.gentoo.org>)
	id 1M8bJK-0008Kn-5m
	for garchives@archives.gentoo.org; Mon, 25 May 2009 14:37:55 +0000
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 6C54FE0395;
	Mon, 25 May 2009 14:37:52 +0000 (UTC)
Received: from dcnode-02.unlimitedmail.net (smtp.unlimitedmail.net [94.127.184.242])
	by pigeon.gentoo.org (Postfix) with ESMTP id 1D550E0395
	for <gentoo-user@lists.gentoo.org>; Mon, 25 May 2009 14:37:51 +0000 (UTC)
Received: from ppp.zz ([137.204.208.78])
	(authenticated bits=0)
	by dcnode-02.unlimitedmail.net (8.14.3/8.14.3) with ESMTP id n4PEbeed000388
	for <gentoo-user@lists.gentoo.org>; Mon, 25 May 2009 16:37:41 +0200
From: Etaoin Shrdlu <shrdlu@unlimitedmail.org>
To: gentoo-user@lists.gentoo.org
Subject: [gentoo-user] Strange problems with keyboard over vnc
Date: Mon, 25 May 2009 16:53:14 +0200
User-Agent: KMail/1.9.9
Precedence: bulk
List-Post: <mailto:gentoo-user@lists.gentoo.org>
List-Help: <mailto:gentoo-user+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-user+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-user+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-user.gentoo.org>
X-BeenThere: gentoo-user@lists.gentoo.org
Reply-to: gentoo-user@lists.gentoo.org
MIME-Version: 1.0
Content-Type: text/plain;
  charset="utf-8"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
Message-Id: <200905251653.14458.shrdlu@unlimitedmail.org>
X-UnlimitedMail-MailScanner-From: shrdlu@unlimitedmail.org
X-Spam-Status: No
X-Archives-Salt: cce84f7b-b914-4929-990b-e8ac47597589
X-Archives-Hash: 5bcaa5db9dbb22e933ccf9d1392829b6

I don't even know what to google for in this case.

I have a remote box running gentoo with kde 3.5, to which I connect using 
VNC (krfb on the remote box, krdc on the local one).

(the actual connection goes via a ssh tunnel, but I think that is not 
relevant here)

All used to work fine, until some days ago the remote site had a power 
outage and the box was turned off. So I asked someone at the remote site 
to turn it on (just pressing the big red switch, basically), and I could 
happily connect via VNC again. Everything seemed to work fine, except 
that at some point I realized that I was not able to enter uppercase 
characters. That is, pressing (for example) shift+r on the local 
keyboard produces a lowercase r, regardless of which shift key I use 
(left or right is the same). This happens in every program (xterm, 
kmail, konsole, etc.). Caps lock works fine though.

But the weirdness does not stop here. Accidentally, I discovered that if 
I press shift, and then press another key and keep it pressed to trigger 
repetition, I get this:

$ sSSSSSSSSsssssssssss

or this:

$ 5%%%%%%%%55555555555

in both cases, the first character is output immediately; since the key 
(s or 5) is hold pressed, after a brief interval repetition starts, with 
the expected output for shift+that key, but that lasts only for 8 
repetitions, and after that it reverts to the non-shift version. The 
number 8 seems to be constant. All of this happens just keeping the key 
pressed, without releasing it. (yes, it's difficult to explain!)

Another strange thing is that combinations that involve pressing multiple 
keys, one of which is shift (like for example altgr+shift+[ to get an 
open brace) seem to produce the expected result (ie, { in this example).

Out of curiosity, I tried to connect to the remote box using krdc from 
another gentoo+kde box, and I got exactly the same results. To complete 
the picture, when using the original local box to connect to a different 
remote box with the same setup everything works fine, so it seems a 
problem of that specific remote box.

I tried to rebuild krdc on the local box and krfb on the remote one, no 
luck.

Nothing changed in installed software releases: xorg-x11 on the remote 
box is 7.2, xorg-server is 1.5.3-r6, with a pretty basic setup (just 
keyboard, mouse and graphics adapter, no hal or other fancy stuff; I can 
post the config as well as any other information if needed).

As I said before, I don't know even where to start looking here.

Thanks in advance for any help.