TurnKey Linux Virtual Appliance Library

UK keyboard mapping problem

I'm using Turnkey Wordpress appliance, and can't see how to change the keyboard mapping to UK so I can get the | # ~ ` symbols etc.  In Windows, I use the Standard 101/102-Key keyboard type, and all symbols are mapped as expected.


Google suggested "loadkeys uk", but the WP appliance says:

Loading uk

/usr/bin/ckbcomp: Can not find file "symbols/uk" in any known directory


How can I resolve this UK keyboard mapping issue?



UK keyboard mapping problem


No-one's replied as of yet & all the suggested fixes I've found via Google for changing Ubuntu's keyboard map via the CLI don't work in Turnkey based appliances :-(

A colleague has started using Turnkey's Redmine appliance as of this morning & he has exactly the same problem :-(

Could someone please show how changing KB mapping to UK via CLI can be done on Turnkey appliances?

Many thanks.


Have you tried reconfiguring the system

Have you run "dpkg-reconfigure console-setup" to choose a UK keyboard?

dpkg-reconfigure console-setup to remap UK keboard

Thanks Chaim, that worked!  I now get all the keyboard symbols mapped correctly in the WP appliance CLI.

I also tried the following command as it is non-interactive and therefore could be put in a startup script, but I get a "command not found" error & I currently don't know what I should apt-get install to get it to work:

setlocale en_GB.utf8


Jeremy's picture

Do you mean that the settings don't stick after reboot?

Or are you looking for a way to have it preconfigured for your scenario during intial install?

I'd like to have it preconfigured during initial install

I'd love to have it preconfigured for 104 keyboard in English so we don't have any issues wrt using various symbols e.g. | \ ~ etc after logging in for the 1st time.



Please excuse my ignorance,

Please excuse my ignorance, but why? What about all the other people that don't want that. Why should be default to that? Again, not trying to be a pain. I honestly don't know. If the default doesn't suit somebody, for example, if they have a German or a Czech keyboard, the just run the config script as you did. That is what all of the major os installations do.

Jeremy's picture

Perhaps you could create a tklpatch for this?

Then you can patch any iso you please. I would imagine such a patch could be easily adjusted to suit other alternative keyboards and help out others with a similar situation. But as you've no doubt realised, the trick will be to automate the config (so it can be done unattended - thus allowing a patch to be created).

Now I'm no programmer and don't know enough regarding this sort of thing, but when creating my OpenVZ templates quite some time ago I installed the localepurge package. It also requires user input to set which locales to keep. I found that during the install process a config file is created. If I inserted this conf file (prior to install of localepurge) I could force the install to assume yes/ok to all questions and it worked fine. Perhaps a similar procedure would work for you too?

Another option (which may be easier and is probably closer to accepted practce) could be to "preseed' the answers to questions. Have a look at the section called "Preseeding a Debain package" on the Dev Wiki. Its brief and may require some experimenting to get it to work right. If you get it working perhaps you could elaborate the info on the wiki to provide a more conprehensive description of the process.

Good luck :)

script/casper-functions error after reconfiguring keyboard

I installed turnkey-core-beta-lucid-x86 in a VM & after I did sudo dpkg-reconfigure console-setup & made the necessary choices for 104 key keyboard, I got the following errors which didn't happen in  Turnkey Core (Ubuntu 8.04.3 LTS) 2009.10-2:

sudo dpkg-reconfigure console-setup
.: 13: Can't open /scripts/casper-functions
.: 6: Can't open /scripts/casper-functions

Liraz Siri's picture

Could be a bug

Thanks for reporting this. It looks like you may have found a bug in either TurnKey or Ubuntu. We'll look into it!

Oh and sorry for the ridiculously late reply. We've been inside a tight development cycle for TKLBAM.

If anybody else is searching

If anybody else is searching the forums to try and fix a UK or international keyboard, the above solution does not seem to work on the latest Turnkey Core based on debian squeeze (12.0rc2). Instead you need

dpkg-reconfigure keyboard-configuration   # pick keyboard layout etc
dpkg-reconfigure console-setup  # pick console font size etc
/etc/init.d/console-setup reload  # make changes effective (or reboot)

Thanks Philip!!

Thanks Philip!!

Post new comment

The content of this field is kept private and will not be shown publicly. If you have a Gravatar account, used to display your avatar.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <p> <span> <div> <h1> <h2> <h3> <h4> <h5> <h6> <img> <map> <area> <hr> <br> <br /> <ul> <ol> <li> <dl> <dt> <dd> <table> <tr> <td> <em> <b> <u> <i> <strong> <font> <del> <ins> <sub> <sup> <quote> <blockquote> <pre> <address> <code> <cite> <strike> <caption>

More information about formatting options

Leave this field empty. It's part of a security mechanism.
(Dear spammers: moderators are notified of all new posts. Spam is deleted immediately)