Bug 518281

Summary: No spanish keyboard after DVD installation
Product: [openSUSE] openSUSE 11.2 Reporter: Miquel A. Noguera <ibz>
Component: X.OrgAssignee: Egbert Eich <eich>
Status: RESOLVED FIXED QA Contact: E-mail List <xorg-maintainer-bugs>
Severity: Normal    
Priority: P3 - Medium CC: acsat, andrew, coolo, ctrippe, eich, info, matti.kukkola, metast, novellbmw, radomir.cernoch, ricardoivaras, sndirsch, tnagy1024
Version: Milestone 6   
Target Milestone: ---   
Hardware: i586   
OS: openSUSE 11.1   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: Here you are my YaST logs
Xorg.0.log
11-keymap.fdi
/etc/sysconfig
/etc/sysconfig/keyboard
/usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi
/var/log/Xorg.0.log
/etc/sysconfig/keyboard
/usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi
output of for i in `hal-find-by-capability --capability "input.keys"`; do lshal -u $i; done as normal user
Xorg.0.log for leny2010s report

Description Miquel A. Noguera 2009-07-01 14:23:00 UTC
Created attachment 301987 [details]
Here you are my YaST logs

User-Agent:       Mozilla/5.0 (X11; U; Linux i686; es-ES; rv:1.9.1.0) Gecko/20090617 SUSE/3.5.0-2.2 Firefox/3.5

Spanish keyboard works fine in console but not in X (KDE4 selected)

I had similar problem with milestone 2, but it was corrected after first online update.


Reproducible: Always

Steps to Reproduce:
1. Install Milestone 3
2. No spanish keyboard under X
3.
Comment 1 Stefan Dirsch 2009-07-01 14:45:14 UTC
Please attach 

- /etc/sysconfig
- /usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi
- /var/log/Xorg.0.log

*seperately* in *plain/text* format.
Comment 2 Miquel A. Noguera 2009-07-01 17:54:23 UTC
Created attachment 302077 [details]
Xorg.0.log
Comment 3 Miquel A. Noguera 2009-07-01 17:56:41 UTC
Created attachment 302079 [details]
11-keymap.fdi
Comment 4 Miquel A. Noguera 2009-07-01 18:00:06 UTC
Created attachment 302082 [details]
/etc/sysconfig
Comment 5 Miquel A. Noguera 2009-07-01 18:02:56 UTC
Since /etc/sysconfig is a directory I send it to you as tgz.
Comment 6 Stefan Dirsch 2009-07-02 00:22:24 UTC
(In reply to comment #4)
> Created an attachment (id=302082) [details]
> /etc/sysconfig

keybaord: KEYTABLE="es.map.gz"

(In reply to comment #5)
> Since /etc/sysconfig is a directory I send it to you as tgz.

Typo. I wanted to write /etc/sysconfig/keyboard. :-(

(In reply to comment #3)
> Created an attachment (id=302079) [details]
> 11-keymap.fdi

<merge key="input.xkb.layout" type="string">es</merge>

Up to here everything looks fine.

(In reply to comment #2)
> Created an attachment (id=302077) [details]
> Xorg.0.log

(**) Option "xkb_rules" "evdev"
(**) Option "xkb_model" "evdev"
(**) Option "xkb_layout" "us"

xkb_layout should be "es" here. I do not understand this and I can't reproduce
either.

This one looks weird:

  (EE) config/hal: couldn't initialise context: (null) ((null))

hald was not running yet when X started? Whatever

==> WORKSFORME

P.S:: eyboard layout is a user setting anyway and needs to be set by user in
the Xsession (KDE4 here) anyway.
Comment 7 Alex Breidenbroich 2009-07-07 12:49:16 UTC
Same Problem here for me on two boxes with german keyboards (also milestone3).

The solution for me was to add the entry

Option "AutoAddDevices" "off"

into the "ServerFlags" section of xorg.conf, so i assume a problem with hal...
Comment 8 Stefan Dirsch 2009-07-07 14:00:12 UTC
Alex, same questions to you.

Please attach 

- /etc/sysconfig/keyboard
- /usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi
- /var/log/Xorg.0.log

*seperately* in *plain/text* format.
Comment 9 Stefan Dirsch 2009-07-07 14:02:17 UTC
Of course without having set 

  Option "AutoAddDevices" "off"
Comment 10 Alex Breidenbroich 2009-07-07 16:30:01 UTC
Created attachment 303530 [details]
/etc/sysconfig/keyboard
Comment 11 Alex Breidenbroich 2009-07-07 16:31:38 UTC
Created attachment 303533 [details]
/usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi
Comment 12 Alex Breidenbroich 2009-07-07 16:32:35 UTC
Created attachment 303534 [details]
/var/log/Xorg.0.log
Comment 13 Stefan Dirsch 2009-07-07 16:46:13 UTC
(In reply to comment #10)
> Created an attachment (id=303530) [details]
> /etc/sysconfig/keyboard

KEYTABLE="de-latin1-nodeadkeys.map.gz"

(In reply to comment #11)
> Created an attachment (id=303533) [details]
> /usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi

     <merge key="input.xkb.layout" type="string">de</merge>
     <merge key="input.xkb.variant" type="string">nodeadkeys</merge>

(In reply to comment #12)
> Created an attachment (id=303534) [details]
> /var/log/Xorg.0.log

(II) XKB: reuse xkmfile /var/lib/xkb/compiled/server-B20D7FC79C7F597315E3E501AEF10E0D866E8E92.xkm
[...]
(**) Option "xkb_rules" "evdev"
(**) Option "xkb_model" "evdev"
(**) Option "xkb_layout" "us"

Do we have some cache issue here? Could you remove this file

  rm /var/lib/xkb/compiled/server-B20D7FC79C7F597315E3E501AEF10E0D866E8E92.xkm

and try again?
Comment 14 Alex Breidenbroich 2009-07-07 16:56:03 UTC
Im sorry, that didnt helped, problem still persits...
Comment 15 Stefan Dirsch 2009-07-07 17:00:27 UTC
It's a bit weird. There's another cache file, which is apparently used.

  /var/lib/xkb/compiled/server-D378AD8F86E560F712A83EE36E4E5E92C595B9BD.xkm

Could you remove this as well and restart your Xserver?
Comment 16 Alex Breidenbroich 2009-07-07 17:16:50 UTC
No, that neighter didnt the trick - shall i try to delete all .xkm files?
Comment 17 Stefan Dirsch 2009-07-07 17:58:10 UTC
I don't think this would help unless they are loaded by the Xserver, but you can try.
Comment 18 Stefan Dirsch 2009-07-22 16:14:00 UTC
Cannot reproduce this issue. Just installed Milestone 3 (KDE) with spanish keyboard and it's active.

/etc/sysconfig/keyboard:
  KEYTABLE="es.map.gz"

/usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi:
  <merge key="input.xkb.layout" type="string">es</merge>

/var/log/Xorg.0.log:
  (**) Option "xkb_rules" "evdev"
  (**) Option "xkb_model" "evdev"
  (**) Option "xkb_layout" "es"

Thus I can only close this one as WORKSFORME.
Comment 19 Miquel A. Noguera 2009-07-27 15:34:09 UTC
Last weekend I did a new fresh Milestone4 install and problem persists, then we can't close it.

IMHO, bugs 520012 and 524200 are identical: X keyboard is set to "us" instead to the selected one in installation.

In text console, keyboard works as espected.
Comment 20 Stefan Dirsch 2009-07-27 19:53:47 UTC
(In reply to comment #19)
> IMHO, bugs 520012 and 524200 are identical: X keyboard is set to "us" instead
> to the selected one in installation.

I agree with Bug #520012. Bug #524200 is something different.
Comment 21 Stefan Dirsch 2009-07-27 19:54:19 UTC
*** Bug 520012 has been marked as a duplicate of this bug. ***
Comment 22 Stephan Kulow 2009-08-04 15:20:02 UTC
X works fine without hal being started, it will wait for it to start up. but it seems there is a bug that it does not set the keyboard layout. Why is the keyboard a user setting, btw? I don't think two users on a system have different keyboards in front of the computer.
Comment 23 Stefan Dirsch 2009-08-04 15:42:03 UTC
(In reply to comment #22)
> X works fine without hal being started, it will wait for it to start up. but it
> seems there is a bug that it does not set the keyboard layout. 

This would be an explanation for the logfile in comment #2, for the logfile in comment #12 it is not.

> Why is the keyboard a user setting, btw? I don't think two users on a system 
> have different keyboards in front of the computer.

Why not?
Comment 24 Miquel A. Noguera 2009-08-16 10:25:59 UTC
I'm sorry but today I did a new fresh M5 install and problem persists, so it's necessary to reopen this bug :-(

Looking at /etc/X11/xorg.conf, I've found the solution:

  # Driver "kbd" will be disabled unless 'Option "AutoAddDevices" "off"' 
  # is set in "ServerFlags" section.

but this option is missing in ServerFlags section.

In fact, adding this parameter, everything is fine again :-)

So, please add it to default xorg.conf and close then this bug as fixed.

Thanks.
Comment 25 Stefan Dirsch 2009-08-16 10:38:57 UTC
This is meant as a hint how to enable this section! It's not the solution! I still can't reproduce the issue, even if hald is not running when X starts and starting hald afterwards.
Comment 26 Christian Trippe 2009-08-18 19:58:08 UTC
I have the same problem with Milestone 5. Instead German keyboard layout I got us.
Comment 27 Stefan Dirsch 2009-08-18 22:14:19 UTC
(In reply to comment #26)
> I have the same problem with Milestone 5. Instead German keyboard layout I got
> us.

I don't see that issue either. I'm using a german keyboard without any xorg.conf
and no keyboard configuration enabled in KDE or any .xinit/.xsession script.
Comment 28 Christian Trippe 2009-08-19 12:40:17 UTC
(In reply to comment #27)
> I don't see that issue either. I'm using a german keyboard without any
> xorg.conf
> and no keyboard configuration enabled in KDE or any .xinit/.xsession script.

After a new install of Milestone 5 I _have_ a xorg.conf, however removing it does not help.
Comment 29 Stefan Dirsch 2009-08-19 13:19:44 UTC
> After a new install of Milestone 5 I _have_ a xorg.conf.

Known issue, which is already tracked. BTW, that's the xorg.conf from installation without any Input section.
Comment 30 Christian Trippe 2009-08-21 10:51:08 UTC
I do not have the problem (us keyboard) with a fresh install of the KDE Live CD from Milestone 6 (before I did a DVD install). However is this bug not the same as bug 531818?
Comment 31 Stefan Dirsch 2009-08-21 10:54:39 UTC
No, the brazilian keyboard layout is *very* special. Bug #531818 I can reproduce whereas this bug I cannot.
Comment 32 Christian Trippe 2009-08-25 08:32:37 UTC
There is another bug with the same content against KDE Workspace (bug 498314). Still present for some with Milestone 6. Maybe it is a KDE issue as I have found no report for the problem with gnome.
Comment 33 Alex Breidenbroich 2009-08-25 09:03:46 UTC
In M6 i just had to go to yast -> language and change from us to german - so i think it is an issue while installing...
(I installed M6 from kde4 live cd, build 235, x84_64)

Also the wrong keyboard settings was applied to the whole system - console and x11...
Comment 34 Stefan Dirsch 2009-08-25 09:38:59 UTC
(In reply to comment #33)
> In M6 i just had to go to yast -> language and change from us to german - so i
> think it is an issue while installing...
> (I installed M6 from kde4 live cd, build 235, x84_64)

Sounds like /etc/sysconfig/keyboard:KEYTABLE is not written during LiveCD installation appropriately. Or the user changed the keyboard configuration via the desktop (user setting!) and expected this to be the global keyboard configuration for a LiveCD installation as well.

> Also the wrong keyboard settings was applied to the whole system - console and
> x11...

Makes perfectly sense. In a xorg.conf-less world global keyboard layout is now
defined via /etc/sysconfig/keyboard:KEYTABLE (there is a mapping to X11 keyboard layout).
Comment 35 Alex Breidenbroich 2009-08-25 10:14:12 UTC
(In reply to comment #34)
> Sounds like /etc/sysconfig/keyboard:KEYTABLE is not written during LiveCD
> installation appropriately. Or the user changed the keyboard configuration via
> the desktop (user setting!) and expected this to be the global keyboard
> configuration for a LiveCD installation as well.

I haven't changed anything in KDE itself - this happend direct at first boot. Also KDE was completly in English (so language settings seems to be affected too).
All I did was to change the language setting in yast to german - after that all is fine.
What makes this kind of a showstopper for me is that i use special chars in my passwords - means i can't log into the system, before i messed up with the US keys for these special chars (if anyone would use a german ä,ü,ß or something like that, there would be _no_ way to log in, if i'm right...)
Comment 36 Stefan Dirsch 2009-08-25 10:23:49 UTC
Well, I'm afraid I dont know enough about LiveCD and LiveCD installation. How is a user supposed to define the keyboard layout when running the LiveCD? Running the appropriate KDE/Gnome configuration tool? Anything else, i.e. maybe system-wide? How is the system-wide keyboard configuration done when installing a LiveCD?
Comment 37 Alex Breidenbroich 2009-08-25 11:02:05 UTC
(In reply to comment #36)
> How is the system-wide keyboard configuration done when installing
> a LiveCD?

Installer asks on the first screen - see http://en.opensuse.org/Image:OS11.1-live-inst-1.png
Comment 38 Alex Breidenbroich 2009-08-25 11:23:43 UTC
(In reply to comment #36)
> Well, I'm afraid I dont know enough about LiveCD and LiveCD installation. How
> is a user supposed to define the keyboard layout when running the LiveCD?
> Running the appropriate KDE/Gnome configuration tool? Anything else, i.e. maybe
> system-wide?

I switch(ed) to german in the grub menu, like you can do in the dvd too - but i assume most users will use the english environment to install....

Wich brings up another question - what will happen if a user set the password to e.g. '3$g2!n-6' in the english liveCD on an non-us keyboard (at least he thinks he do so, because he can't see it...) and select another language in the first install dialog?

Sorry for the double post.
Comment 39 Stephan Kulow 2009-08-25 12:04:44 UTC
Do you get or don't you get correct entries in /etc/sysconfig if you select german before booting?
Comment 40 Stefan Dirsch 2009-08-25 12:10:52 UTC
(In reply to comment #37)
> Installer asks on the first screen - see
> http://en.opensuse.org/Image:OS11.1-live-inst-1.png

(In reply to comment #38)
> I switch(ed) to german in the grub menu, like you can do in the dvd too - but i
> assume most users will use the english environment to install....

Thanks. So we have consistent and expected behaviour.
Comment 41 Stefan Dirsch 2009-08-25 12:14:07 UTC
(In reply to comment #38)
> Wich brings up another question - what will happen if a user set the password
> to e.g. '3$g2!n-6' in the english liveCD on an non-us keyboard (at least he
> thinks he do so, because he can't see it...) and select another language in the
> first install dialog?

On a LiveCD specifying the password is not the first thing you do, right? Thus I believe the user notices this issue and changes the keyboard layout before changing/entering the password.
Comment 42 Christian Trippe 2009-08-25 12:22:48 UTC
> On a LiveCD specifying the password is not the first thing you do, right? Thus
> I believe the user notices this issue and changes the keyboard layout before
> changing/entering the password.

But it also happens with DVD install, see my comment 26 and 30 and also https://bugzilla.novell.com/534023 which is probably related.
Comment 43 Stefan Dirsch 2009-08-25 12:26:56 UTC
This bugreport is getting a mess. As usual discussing seperate issues by different people doesn't help. :-(
Comment 44 Miquel A. Noguera 2009-08-25 16:28:18 UTC
Last weekend I tested M6 and got different results depending on media :-/

M6 Live-CD/KDE:
---------------
- Booting to it, keyboard works fine :-)
- Installing it, generates a wrong /etc/sysconfig/keyboard (replacing it with the one generated with DVD, everything is fine again).

M6 DVD:
-------
- Generates a right /etc/sysconfig/keyboard
- according to /etc/sysconfig/keyboard, tty console's keyboard is set to spanish, wich is ok
- X keyboard is allways set to us, wich is wrong

Here the questions are:

a) why are behaving diferent CD a DVD media? is it due to changes between builds or are we setting it up in a different way?

b) why X keyboard is set ignoring /etc/sysconfig/keyboard? where do we store here system wide default keyboard?
Comment 45 Miquel A. Noguera 2009-08-25 16:53:20 UTC
In reply to comment #39:

> Do you get or don't you get correct entries in /etc/sysconfig if you select
>german before booting?

Not with DVD media, yes with CD-Live-KDE

In reply to comment #40:

> Thanks. So we have consistent and expected behaviour.

No, we haven't: selecting 'spanish' before booting, i get 'spanish' in tty console, and us in X, wich at least is inconsistent.
Comment 46 Miquel A. Noguera 2009-08-25 17:02:29 UTC
In reply to comment #38

> what will happen if a user set the password to e.g. '3$g2!n-6'

This "is not" a big problem, because at least all this signs are present in us keyboard.

The big problem is when you set the password to something like "caña-2ç4" (I did it during M3-DVD install, when I opened this bug): in this case there is no way to login, then no chance to setup keywoard in KDE/GNOME preferences and system turns inusable.
Comment 47 Stefan Dirsch 2009-08-25 19:33:05 UTC
(In reply to comment #44)
> Last weekend I tested M6 and got different results depending on media :-/
> 
> M6 Live-CD/KDE:
> ---------------
> - Booting to it, keyboard works fine :-)
> - Installing it, generates a wrong /etc/sysconfig/keyboard (replacing it with
> the one generated with DVD, everything is fine again).

Please open a seperate bugreport filed against YaST2. You selected the right keyboard layout in http://en.opensuse.org/Image:OS11.1-live-inst-1.png?

> M6 DVD:
> -------
> - Generates a right /etc/sysconfig/keyboard
> - according to /etc/sysconfig/keyboard, tty console's keyboard is set to
> spanish, wich is ok
> - X keyboard is allways set to us, wich is wrong

This is this bug, I never could reproduce.

> a) why are behaving diferent CD a DVD media? is it due to changes between
> builds or are we setting it up in a different way?

It's the same setup, i.e. no xorg.conf in use any longer unless you run
sax2 manually and set 'Option "AutoAddDevices" "off" in this file.

> b) why X keyboard is set ignoring /etc/sysconfig/keyboard? where do we store
> here system wide default keyboard?

/etc/X11/xdm/keytable4hal is called by xdm init script, reads /etc/sysconfig/keyboard:KEYTABLE, maps it to the appropriate X keyboard layout and generates /usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi. This again is read by hald
and been provided as keyboard setting to the Xserver. Something like this.
Comment 48 Stefan Dirsch 2009-08-25 19:34:37 UTC
(In reply to comment #45)
> > Thanks. So we have consistent and expected behaviour.
> 
> No, we haven't: selecting 'spanish' before booting, i get 'spanish' in tty
> console, and us in X, wich at least is inconsistent.

Which I can't reproduce.
Comment 49 Stefan Dirsch 2009-08-25 19:37:35 UTC
Egbert, could you try to reproduce. I simply can't.
Comment 50 Tristan Hoffmann 2009-08-27 15:48:46 UTC
Just installed Milestone6 x86_64 from DVD (no live dvd or live cd).
I had the same problem, I started the DVD by just pressing Enter for install.
When the graphical system started I left English (US) as language setting but changed the keyboard to german with deadkeys.
I selected kde manually added thunderbird and pidgin to the software selection.

The installed system has the german keyboard layout at the mode (Strg+Alt+F1), but kdm and kde do still use the us keyboard layout. 
I hope this helps you reproduce this bug.

In case its needed, my system is a M2A-VM Mainbard (690G Chipset).
Comment 51 Egbert Eich 2009-08-31 15:25:59 UTC
OK, I cannot reproduce the issue here either.
Originally I had 
KEYTABLE="us"
which gave me an us keyboard.
This I changed to:
KEYTABLE="de-latin1-nodeadkeys"
I did: 
init 3; init 5; # restart the Xserver
logged in via KDE, got a german keybard.

Those people who see this problem, could you please start a 'failsave' session, and in the xterm which opens do: 'setxkbmap -print'?
If this tells you something about 'us' on the symbol line please attach:
a. /etc/sysconfig/keyboard
b. /usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi
c. the output from 'setxkbmap -print'.
Comment 52 Tristan Hoffmann 2009-08-31 18:52:49 UTC
Ok, I just started a new session as failsave.
setxkbmap -print shows:
xkb_keymap {
        xkb_keycodes  { include "evdev+aliases(qwerty)" };
        xkb_types     { include "complete"      };
        xkb_compat    { include "complete"      };
        xkb_symbols   { include "pc+us+inet(evdev)"     };
        xkb_geometry  { include "pc(pc104)"     };
};

Just to be clear, I just changed the keyboard layout for installation, language is still English(US), in case this matters.
Comment 53 Tristan Hoffmann 2009-08-31 18:54:22 UTC
Created attachment 316044 [details]
/etc/sysconfig/keyboard
Comment 54 Tristan Hoffmann 2009-08-31 18:55:16 UTC
Created attachment 316045 [details]
/usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi
Comment 55 Egbert Eich 2009-09-01 06:31:47 UTC
(In reply to comment #52)
> Ok, I just started a new session as failsave.
> setxkbmap -print shows:
> xkb_keymap {
>         xkb_keycodes  { include "evdev+aliases(qwerty)" };
>         xkb_types     { include "complete"      };
>         xkb_compat    { include "complete"      };
>         xkb_symbols   { include "pc+us+inet(evdev)"     };
>         xkb_geometry  { include "pc(pc104)"     };
> };
> 
> Just to be clear, I just changed the keyboard layout for installation, language
> is still English(US), in case this matters.

It shoudln't. The information in the sysconfig/keyboard and in the 11-keymap.fdi file are both correct:
- KEYTABLE="de-latin1.map.gz"
- <merge key="input.xkb.layout" type="string">de</merge>

Tristan, have you restarted the Xserver after you changed to a German keyboard?
(logging out of the session doesn't restart the server any more, doing 'init 3; init 5' from the console seems to be the easiest way to do this).
Comment 56 Tristan Hoffmann 2009-09-01 08:24:28 UTC
I already changed the keyboard layout during installation (not at the isolinux menu but in the first  yast installation step, before selecting new installation).
I've already restarted the whole system several times and still have german layout at the console (Strg+Alt+F1) and US layout at KDE 4.3.
Comment 57 Egbert Eich 2009-09-01 16:47:52 UTC
Ok, thanks! Tristan, could you please get and attach the output of:

for i in `hal-find-by-capability --capability "input.keys"`; do lshal -u $i; done
Comment 58 Tristan Hoffmann 2009-09-01 19:48:18 UTC
Created attachment 316253 [details]
output of for i in `hal-find-by-capability --capability "input.keys"`; do lshal -u $i; done as normal user

output of 

for i in `hal-find-by-capability --capability "input.keys"`; do lshal -u $i; done 

as normal user
Comment 59 Egbert Eich 2009-09-02 13:42:49 UTC
(In reply to comment #58)
> Created an attachment (id=316253) [details]
> output of for i in `hal-find-by-capability --capability "input.keys"`; do lshal
> -u $i; done as normal user
> 
> output of 
> 
> for i in `hal-find-by-capability --capability "input.keys"`; do lshal -u $i;
> done 
> 
> as normal user

There is a bunch of stuff missing.
There should be lines like:
  input.x11_driver = 'evdev'  (string)
  input.xkb.layout = 'de'  (string)
  input.xkb.model = 'pc104'  (string)
  input.xkb.rules = 'base'  (string)
This seems to be a HAL issue: HAL doesn't seem to merge 
/usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi.
Looking at the attachment in comment #54 I cannot see why as the condition
 <match key="info.capabilities" contains="input.keys">
is met by those entries.
There seems to be an issue with HAL.
Comment 60 Stefan Dirsch 2009-09-02 14:44:48 UTC
Kay, any ideas what's going on here?
Comment 61 Miquel A. Noguera 2009-09-02 20:48:32 UTC
Comparing /usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi with 11.1 /usr/share/hal/fdi/policy/10osvendor/10-keymap.fdi, one line is missing:

diff -Nur 10-keymap.fdi 11-keymap.fdi
--- 10-keymap.fdi       2009-09-02 20:46:27.009431415 +0200
+++ 11-keymap.fdi       2009-09-02 20:25:58.769835777 +0200
@@ -17,6 +17,7 @@
       </match>

       <merge key="input.xkb.layout" type="string">es</merge>
+      <merge key="input.xkb.variant" type="string" />
     </match>
   </device>
 </deviceinfo>

Reintroducing this line has fixed for me this bug in ALL my 6 problematic systems.

Is this a feature or is just the bug we ar looking for?
Comment 62 Stefan Dirsch 2009-09-02 21:55:36 UTC
Good catch, Miquel! Changed this now in keytables4hal script (xorg-x11 package in X11:XOrg project; also SR'ed for openSUSE:Factory).

Tristan, Alex, Christian. Can you confirm that adding this line fixes the issue?
Comment 63 Egbert Eich 2009-09-02 22:07:10 UTC
(In reply to comment #62)
> Good catch, Miquel! Changed this now in keytables4hal script (xorg-x11 package
> in X11:XOrg project; also SR'ed for openSUSE:Factory).
> 
> Tristan, Alex, Christian. Can you confirm that adding this line fixes the
> issue?

It's strange actually. According to the HAL specs the variant property isn't even mandatory.
Comment 64 Stefan Dirsch 2009-09-03 08:59:31 UTC
*** Bug 535020 has been marked as a duplicate of this bug. ***
Comment 65 Tristan Hoffmann 2009-09-03 10:46:22 UTC
I can confirm that adding the line from comment #61 fixes the issue.
Thanks!
Comment 66 Egbert Eich 2009-09-03 11:23:41 UTC
I'm wondering if due to a change in system time during configuration the cache file is newer than the 11-keymap.fdi file and thus the cache didn't get updated.
If someone who still sees this issue could just make a touch on 
 /usr/share/hal/fdi/policy/20thirdparty/11-keymap.fdi
or alternatively remove the hald cache file:
 /var/cache/hald/fdi-cache
Apart from this I have no explanation why the elements from 11-keymap.fdi have not been merged. I cannot find anything in the HAL code (and it wouldn't make sense to me) which would check for individual device properties.
Comment 67 Egbert Eich 2009-09-03 12:00:34 UTC
NEEDINFO to Kay again.
Comment 68 Kay Sievers 2009-09-03 12:23:43 UTC
What's the question please?
Comment 69 Egbert Eich 2009-09-03 13:40:25 UTC
Looking at hald code the cache gets invalidated thru an inotify but only regenerated if the cache file timestamp is older than the timestamp of at least one of the files. Also during the lifetime if hald it seems like even though the cache is marked invalid it only gets regenerated when a new device is registered.
I would think it ought to be regenerated the main loop whenever some request comes in. But I'm just starting to get familiar with HAL.
Comment 70 Egbert Eich 2009-09-03 13:45:50 UTC
Kay, I wonder if you could shed some light on what we are seeing here:
A .fdi file gets added, it's supposed to add input.xkb.* properties to input.key devices but even after several reboots those entries don't show up in the lshal output.
Then suddenly when a new input.xkb.* property is added things start to work.
I've tried to give an explanation in comment #66 and contemplated on some observations in comment #69.
Maybe you can give us an idea here. Because I'm afraid adding xkb.variant entries may have fixed the problem for people who already see them but will not address the issue for people who freshly install their system.
Comment 71 Kay Sievers 2009-09-03 14:26:34 UTC
(In reply to comment #69)
> I would think it ought to be regenerated the main loop whenever some request
> comes in.

I don't know anything about this code, sorry.

> But I'm just starting to get familiar with HAL.

Hope you noticed that HAL will die and go away soon. It's in maintenance mode and no longer developed. So anything else than important bug fixes would be pretty much a waste of time.

(In reply to comment #70)
> Kay, I wonder if you could shed some light on what we are seeing here:
> A .fdi file gets added, it's supposed to add input.xkb.* properties to
> input.key devices but even after several reboots those entries don't show up in
> the lshal output.

I have no idea how that can happen. If you can reproduce it, you can try to run HAL in debug mode, and see if the log says something. The instructions to enable logging are here:
  http://en.opensuse.org/HAL#Debugging.2FBugreporting
Comment 72 Kay Sievers 2009-09-03 14:28:24 UTC
(In reply to comment #71)
> (In reply to comment #69)
> > I would think it ought to be regenerated the main loop whenever some request
> > comes in.
> 
> I don't know anything about this code, sorry.

Forgot to say, that only newly added devices will see the new fdi properties. Adding an fdi file, or changing one will only affect newly added devices, not already existing ones.
Comment 73 Kay Sievers 2009-09-03 16:54:43 UTC
We also need to be sure that all this isn't a behavior caused by a probably mis-compiled HAL package, like in this bug:
  https://bugzilla.novell.com/show_bug.cgi?id=535661
Comment 74 Egbert Eich 2009-09-03 20:44:23 UTC
Ok, with my last patch to xorg-x11 which removes the hald cache before restarting hald I assume this issue is fixed.
Please feel free to add further test results. If my assumption proves wrong we can reopen the ticket.
Comment 75 Stefan Dirsch 2009-09-06 14:14:36 UTC
*** Bug 537078 has been marked as a duplicate of this bug. ***
Comment 76 Tim Fechtner 2009-09-14 07:36:30 UTC
Works fine in M7
Comment 77 Tim Fechtner 2009-09-14 07:37:53 UTC
*** Bug 498314 has been marked as a duplicate of this bug. ***
Comment 78 Bernhard Wiedemann 2009-10-04 06:43:22 UTC
Does bug 542009 have a different cause? I'm still seeing it in MS7 and MS8 but not on every platform (VirtualBox works, Laptop(Amilo Pro 2030) has bug)
maybe related: bug 534023, bug 534300
Comment 79 Stefan Dirsch 2009-10-04 09:03:25 UTC
These have different causes, and are unrelated, yes.
Comment 80 Ricardo Varas 2009-10-09 03:40:53 UTC
With M8 it works fine for me, so I got spanish layout after install.
Comment 81 Andrew Lindley 2009-10-15 17:42:56 UTC
Installing 11.2 RC1 KDE LiveCD results in a US keyboard map rather than the chosen UK one on an Acer Aspire One ZG5 AOA 150. I have no 11-keymap.fdi in /usr/share/hal/fdi/policy/20thirdparty . setxkbmap -print   results in

xkb_keymap {
        xkb_keycodes  { include "evdev+aliases(qwerty)" };
        xkb_types     { include "complete"      };
        xkb_compat    { include "complete"      };
        xkb_symbols   { include "pc+us+inet(evdev)"     };
        xkb_geometry  { include "pc(pc104)"     };
};

/etc/sysconfig/keyboard has

KEYTABLE="us.map.gz"
Comment 82 Andrew Lindley 2009-10-15 17:47:06 UTC
Created attachment 322719 [details]
Xorg.0.log for leny2010s report
Comment 83 Andrew Lindley 2009-10-15 19:21:27 UTC
The path taken at installation was to select Installation from the ISOLINUX menu. Choose UK country at the first screen and allow it to automatically select UK keyboard.  After that the defaults were  (retaining existing /home), save for selecting Copy of System Emails and the user details. 

The problem is overcome by post install using Yast2 to set the country language.

The LiveCD was booted of a USB stick after being dd 'd as per en.opensuse.org instructions.
Comment 84 Andrew Lindley 2009-10-15 19:22:44 UTC
The path taken at installation was to select Installation from the ISOLINUX menu. Choose UK country at the first screen and allow it to automatically select UK keyboard.  After that the defaults were  (retaining existing /home), save for selecting Copy of System Emails and the user details. 

The problem is overcome by post install using Yast2 to set the country language.

The LiveCD was booted of a USB stick after being dd 'd as per en.opensuse.org instructions.
Comment 85 Stefan Dirsch 2009-10-15 22:40:27 UTC
1. This bug is not about installation from LiveCD.
2. The location for the .fdi file has changed to /etc/hal/fdi/policy/...

AFAIK there are various bugreports about wrong keyboard layout after installation from LiveCD. In case you can't find any of these, open a new one against YaST or installation component. I really don't want to discuss unrelated issues in a 84+ comments bug. It's already confusing enough.