# Virtualbox and VNC keyboard layout (Spanish) not working



## Jose Luis (Oct 14, 2015)

I have installed Virtualbox on FreeBSD 9.3 It works ok, but I have the next problem.

I have installed Oracle Linux as guest.

When I use the console via VNC, the mapping of several keys don't work.

I have a Spanish keyboard.

I have configured the keyboard in Linux with setxkbmap(1) , but there isn't a difference.

I have read several pages about the subject, and it seems that only American keyboard works.

Is there some possibility to solve the mapping of the keyboard? I have been looking for a solution for several hours, but without success.

Regards


----------



## Jose Luis (Oct 14, 2015)

If I change the keyboard of the keyboard in my PC (it is a PC with NetBSD): `setxkbmap -layout en`, it works ok. The Linux guest is configured with a Spanish keyboard running `setxkbmap -layout es`. The problem, is that I have to change the keyboard configuration for run other applications, but at least I can use it.


----------



## fredvs (Oct 15, 2015)

Hello,

Do you use Xorg? If yes, did you try with this => `setxkbmap es` ?

Fre;D


----------



## Jose Luis (Oct 17, 2015)

fredvs said:


> Hello.
> 
> Do you use xorg ?
> If yes, did you try with this => `setxkbmap es` ?
> ...


Yes I tried with this command. It doesn't work.


----------



## Jose Luis (Oct 17, 2015)

Jose Luis said:


> If I change the keyboard of the keyboard in my PC (it is a PC with NetBSD): `setxkbmap -layout en`, it works ok. The Linux guest is configured with a Spanish keyboard (`setxkbmap -layout es`). The problem, is that I have to change the keyboard configuration for run other applications, but at least I can use it.


I was wrong.

It works more keys, but not all. Keys with Alt Graph don't work.

The more useful keyboard configuration that I can obtain is configure all in US keyboard, and "imagine" that I have a English keyboard instead of a Spanish keyboard.

Is this the actual state of console/VNC with Virtualbox? or is there some other possibility?


----------



## cpm@ (Oct 19, 2015)

AFAIK the keyboard handling is severely limited, and only the US keyboard layout works. Other keyboard layouts will have at least some keys which produce the wrong results (often quite surprising effects), and for layouts which have significant differences to the US keyboard layout it is most likely unusable.

Please, read the Oracle VM VirtualBox User Manual for further details.


----------



## tingo (Oct 21, 2015)

Follow-up question: is it possible to change the keymap only locally, that is only in the xterm / shell from where you are starting the vncviewer?
`setkbmap us` changes the keyboard layout globally, which get annoying very fast.

Update: ok, I had forgotten this - I can set up keyboard switching like this `setxkbmap no,us -option grp:rwin_toggle` which allows me to switch to the us layout (and back) with the right windows key.


----------

