[SOLVED] Voyage Linux: British keyboard mismapping
Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
I've got a new Voyage Linux command-line only virtual machine running on VirtualBox OSE under Ubuntu 12.04. The keyboard mapping isn't correct and it has the following missmapping (and possibly more):
"\" produces "<"
"|" (shift \) produces ">"
"~" produces "|"
"#" produces "\"
it has the usual US vs UK reversals of '"' and '@', which suggests that the keymap is based on US.
I tried installing console-data, doing dpkg-reconfigure console-data and choosing QWERTY, British to no avail.
All help gratefully received.
Last edited by Geoff_L; 01-06-2013 at 03:01 PM.
Reason: To mark as solved
It's set up for US, by the look of it, or somewhere else anyhow. The Classic one for US is @ instead of " and vice versa. Command line only, check your $LOCALE setting. echo $LOCALE $LC_ALL $LANG
Files in /usr/share/kbd/i386/keymaps/qwerty/ (or something like that). Often configured in init scripts and login files (/etc/profile.d/*). Not unusual to have this stuff set multiple times. If there's a default symlink, change it. Man setfont, I think.
Unfortunately, those environment variables aren't set and /etc/profile.d contains nothing I can see about keyboards. I've found one keymap with a filename that suggests it to be the one to use, but I don't know how to configure the console to use it. Any further help would be welcome.
produce nothing? Right then, it's running on defaults. Set LANG in /etc/profile.d
Slackware also has a defkeymap.map.gz and a ko.map.gz, the latter being a symlink. The defkeymap should point to your default key map. Then simply invoking sefont loads it (I think). Ditto for default font. Both, iirc are settable. Play with setfont until you are happy.
Unfortunately, setfont isn't installed. For info, Linux Voyage is based on Debian Sqeeze rather than Slackware.
Delving a little further turned up some comments in /etc/default/keyboard that suggested adding: KMAP=/usr/share/keymaps/i386/qwerty/uk.kmap.gz to /etc/default/keyboard might do the trick -- but that didn't work, even after rebooting. FWIW, I'm having issues with LAMP also on this distro (a known good application can't connect to MySQL data and doesn't return the expected errors) and having installed various utilties trying to correct the keyboard mapping and resolve other issues, the disk image is getting less and less lightweight. So I might need to look elsewhere. That said, it would still be nice to resolve the issues with this distro, and I'm learning a lot in the process!
apt-get install kbd
might do things for you. Worth a shot. For the record, I have Debian squeeze on a machine with the hostname pipsqueak, my raspberry Pi. The total install is under 2 Gig. THAT has setfont, but not loadkeys.
installing kbd didn't fix the issue. However, doing loadkeys /usr/share/keymaps/i386/qwerty/uk.kmap.gz does give the correct mapping for the current session. So I guess I need to make that permanent, but I don't know where to add that command.
FWIW, the hard disk on the VM is 2GB and includes a swap partition. I chose Voyage Linux because it claims that typical installs weigh in at less than 128MB. However, with LAMP and all the utils I've installed, my installation has grown to over 400MB, which is too much as there's insufficient headroom after the expected data volume is loaded. So I need to strip out everything that isn't strictly necessary once I've got the machine doing what I need it to do.
This is a strange distro as /etc/rc.d doesn't exist (I have /etc/rc.local and several /etc/rc?.d directories) so I considered inserting the command into /etc/rc.local -- although that might be overkill as the comment in that file suggests it runs at each runlevel entered. However, after the third session where I issued the command manually, the new keymapping somehow seems to have become permanent. I'm confused, but I guess the issue is solved.
/etc/rc.local will be the place. Never mind the comment. If this is run more than once, the sky doesn't fall in.
Thanks again for staying with this. For info, while resolving another issue I discovered that Linux Voyage has its own idiosyncrasies and that the best place to insert 'run once on boot' instructions is probably /etc/init.d/voyage-util, which is proprietary to Voyage. That said, I've now created a second VM with this distro and a reproducible way to install the correct keyboard mapping is:
Run apt-get update (needed because almost no repository info is included 'out of the box').
apt-get install kbd
apt-get install console-data
Run loadkeys to installed the preferred mapping. After the previous steps, the mapping files can be found from /usr/share/keymaps/. For example, I ran loadkeys /usr/share/keymaps/i386/qwerty/uk.kmap.gz