install-keymap doesn't make setting permanent

Bug #198483 reported by furicle
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
console-common (Ubuntu)
Confirmed
Medium
Unassigned

Bug Description

Binary package hint: console-data

Ubuntu 7.10 gutsy

console-data 3:1.02-2ubuntu4

The man page states 'install-keymap [...] puts the result in /etc/console/boottime.kmap.gz which will be loaded into the kernel at boot time.'

However when I try it, it seems to be in effect only until I reboot.

/etc/console/boottime.kmap.gz is created and *I think* is ok - but I'm no keymap expert :-)

Background - I'm trying to use tn5250 (from package of the same name) who's readme states I can use loadkeys us5250.map (which is included) to add F21 thru F24 and Shift-Tab to the standard linux kernel keymap.
If I run install-keymap us5250.map it does activate those keys, but only until I reboot.

If this is the expected behaviour then I could add something to run on boot I suppose, but then the man page is wrong.

Comments appreciated,

Brian

Revision history for this message
Colin Watson (cjwatson) wrote :

console-data is no longer installed by default and is no longer used or supported. (Actually install-keymap lives in console-common, but the same applies to that.) Ideally you need to use something involving console-setup.

The modern approach to what I think you're trying to do would be to add support for this keymap to XKB; at that point you can select the right layout and variant in /etc/default/console-setup, run 'setupcon --save', and run 'update-initramfs -u'.

It looks kind of tricky to come up with a variant of install-keymap that still works with the new world order, unfortunately ...

Changed in console-data:
importance: Undecided → Medium
status: New → Confirmed
Revision history for this message
Edouardj (edouard-jugie) wrote :

So what is the solution before the next ubuntu?

I must modify my conf of sudo to add:
myname ALL=NOPASSWD: /usr/sbin/install-keymap

then i add a new session for my account (auto start): /usr/sbin/install-keymap my_keymap

Revision history for this message
wateenellende (fpbeekhof) wrote :

The problem is now in the console-common package.

The keymay is not set at boot time. Originally, I had a US-qwerty layout, then changed it to dvorak. Now, the consoles are qwerty, to log into X i have to type my password in qwerty, and then I have a dvorak session.

Running the script 'sudo /etc/init.d/keymap.sh' does not fix the problem, although /etc/console/boottime.kmap.gz is definitely a dvorak layout. If I run 'sudo loadkeys -q /etc/console/boottime.kmap.gz' from the command line, it works.

So my suspicion is that the /etc/init.d/keymap.sh script is broken.

I have other computers on which I installed ubuntu with a dvorak keyboard right away, and the problem is not present on those.

Revision history for this message
wateenellende (fpbeekhof) wrote :

The keymaps.sh script stops because it detects setupcon, and decides that console-setup will take over.

console-setup by means of setupcon loads /etc/console-setup/cached.kmap.gz , which is qwerty. Overwriting it with a dvorak-keymap and then calling:
$ sudo setupcon -v
$ sudo update-initramfs -k all -u
will make sure all terminals have the desired keymap on boot.

Question: what is the regular automated procedure to do this ?
Remark: I now have dvorak on console, dvorak in X - but I must still type my password in qwerty to log into X, even though I've selected dvorak in the keyboard menu below.

:-(

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.