Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index International Gentoo Users Spanish
  • Search

[keyboard] problema en bash, rarisimo

Foro en español para los usuarios Hispanos de Gentoo.

Moderator: Stolz

Post Reply
  • Print view
Advanced search
21 posts • Page 1 of 1
Author
Message
Dabuti
n00b
n00b
Posts: 9
Joined: Thu Oct 14, 2010 4:55 pm

[keyboard] problema en bash, rarisimo

  • Quote

Post by Dabuti » Thu Oct 14, 2010 5:27 pm

Buenas a todos, me ocurre algo rarísimo tengo 2 pc's con gentoo un sobremesa y un portatil, practicamente uso lo mismo en ambos, el caso que en el poratil no consigo poder escribir acentos eñes simbolo de € etc en bash tty pero si que leo todo a la perfeccion, otra cosa curiosa es que cuando pide el login en la tty puedo escribir estos caracteres especiales, pero una vez logeado no. Si alguien sabe de que puede ser se lo agradecería mucho, llevo mas de 1 mes intentando solucionarlo y nada :S
Top
cameta
Veteran
Veteran
User avatar
Posts: 1394
Joined: Wed Aug 04, 2004 9:51 am

  • Quote

Post by cameta » Thu Oct 14, 2010 6:54 pm

Que tienes en:
/etc/conf.d/keymaps
/etc/rc.conf
y que te dice el comando
locale
Si algo falla LEE el jodido manual, Si sigue fallando LEE BIEN el jodido manual.
Top
Dabuti
n00b
n00b
Posts: 9
Joined: Thu Oct 14, 2010 4:55 pm

  • Quote

Post by Dabuti » Thu Oct 14, 2010 8:23 pm

cameta wrote:Que tienes en:
/etc/conf.d/keymaps
/etc/rc.conf
y que te dice el comando
locale
/etc/conf.d/keymaps

Code: Select all

tux2duo ~ # cat /etc/conf.d/keymaps
# /etc/conf.d/keymaps

# Use KEYMAP to specify the default console keymap.  There is a complete tree
# of keymaps in /usr/share/keymaps to choose from.

KEYMAP="es euro2"
CONSOLEFONT="lat9w-16"


# Should we first load the 'windowkeys' console keymap?  Most x86 users will
# say "yes" here.  Note that non-x86 users should leave it as "no".

SET_WINDOWKEYS="yes"
FIX_EURO="yes"

# The maps to load for extended keyboards.  Most users will leave this as is.

EXTENDED_KEYMAPS=""
EXTENDED_KEYMAPS="backspace keypad euro"


# Tell dumpkeys(1) to interpret character action codes to be 
# from the specified character set.
# This only matters if you set UNICODE="yes" in /etc/rc.conf.
# For a list of valid sets, run `dumpkeys --help`

#DUMPKEYS_CHARSET="ISO-8859-15" 
/etc/rc.conf

Code: Select all

tux2duo ~ # cat /etc/rc.conf
# /etc/rc.conf: Global startup script configuration settings

# UNICODE specifies whether you want to have UNICODE support in the console.  
# If you set to yes, please make sure to set a UNICODE aware CONSOLEFONT and 
# KEYMAP in the /etc/conf.d/consolefont and /etc/conf.d/keymaps config files.

UNICODE="yes"

# Set EDITOR to your preferred editor.
# You may use something other than what is listed here.

EDITOR="/bin/nano"
#EDITOR="/usr/bin/vim"
#EDITOR="/usr/bin/emacs"

CONSOLEFONT="lat9w-16"

# DISPLAYMANAGER has moved to /etc/conf.d/xdm

# XSESSION is a new variable to control what window manager to start
# default with X if run with xdm, startx or xinit.  The default behavior
# is to look in /etc/X11/Sessions/ and run the script in matching the
# value that XSESSION is set to.  The support scripts are smart enough to
# look in all bin directories if it cant find a match in /etc/X11/Sessions/,
# so setting it to "enlightenment" can also work.  This is basically used
# as a way for the system admin to configure a default system wide WM,
# allthough it will work if the user export XSESSION in his .bash_profile, etc.
#
# NOTE:  1) this behaviour is overridden when a ~/.xinitrc exists, and startx
#           is called.
#        2) even if ~/.xsession exists, if XSESSION can be resolved, it will
#           be executed rather than ~/.xsession, else KDM breaks ...
#
# Defaults depending on what you install currently include:
#
# Gnome - will start gnome-session
# kde-<version> - will start startkde (look in /etc/X11/Sessions/)
# Xfce4 - will start a XFCE4 session
# Xsession - will start a terminal and a few other nice apps

XSESSION="Gnome"
locale:

Code: Select all

tux2duo ~ # locale
LANG=es_ES.UTF-8
LC_CTYPE=es_ES.UTF-8
LC_NUMERIC="es_ES.UTF-8"
LC_TIME="es_ES.UTF-8"
LC_COLLATE=C
LC_MONETARY="es_ES.UTF-8"
LC_MESSAGES="es_ES.UTF-8"
LC_PAPER="es_ES.UTF-8"
LC_NAME="es_ES.UTF-8"
LC_ADDRESS="es_ES.UTF-8"
LC_TELEPHONE="es_ES.UTF-8"
LC_MEASUREMENT="es_ES.UTF-8"
LC_IDENTIFICATION="es_ES.UTF-8"
LC_ALL=
Top
cameta
Veteran
Veteran
User avatar
Posts: 1394
Joined: Wed Aug 04, 2004 9:51 am

  • Quote

Post by cameta » Thu Oct 14, 2010 8:48 pm

Yo tengo esto

Code: Select all

# /etc/rc.conf: Global startup script configuration settings

# UNICODE specifies whether you want to have UNICODE support in the console.  
# If you set to yes, please make sure to set a UNICODE aware CONSOLEFONT and 
# KEYMAP in the /etc/conf.d/consolefont and /etc/conf.d/keymaps config files.

UNICODE="yes"

# Set EDITOR to your preferred editor.
# You may use something other than what is listed here.

EDITOR="/bin/nano"
#EDITOR="/usr/bin/vim"
#EDITOR="/usr/bin/emacs"

# DISPLAYMANAGER has moved to /etc/conf.d/xdm

# XSESSION is a new variable to control what window manager to start
# default with X if run with xdm, startx or xinit.  The default behavior
# is to look in /etc/X11/Sessions/ and run the script in matching the
# value that XSESSION is set to.  The support scripts are smart enough to
# look in all bin directories if it cant find a match in /etc/X11/Sessions/,
# so setting it to "enlightenment" can also work.  This is basically used
# as a way for the system admin to configure a default system wide WM,
# allthough it will work if the user export XSESSION in his .bash_profile, etc.
#
# NOTE:  1) this behaviour is overridden when a ~/.xinitrc exists, and startx
#           is called.
#        2) even if ~/.xsession exists, if XSESSION can be resolved, it will
#           be executed rather than ~/.xsession, else KDM breaks ...
#
# Defaults depending on what you install currently include:
#
# Gnome - will start gnome-session
# kde-<version> - will start startkde (look in /etc/X11/Sessions/)
# Xfce4 - will start a XFCE4 session
# Xsession - will start a terminal and a few other nice apps

#XSESSION="Gnome"

Code: Select all

# /etc/conf.d/keymaps

# Use KEYMAP to specify the default console keymap.  There is a complete tree
# of keymaps in /usr/share/keymaps to choose from.

KEYMAP="es"


# Should we first load the 'windowkeys' console keymap?  Most x86 users will
# say "yes" here.  Note that non-x86 users should leave it as "no".

SET_WINDOWKEYS="no"


# The maps to load for extended keyboards.  Most users will leave this as is.

EXTENDED_KEYMAPS=""
#EXTENDED_KEYMAPS="backspace keypad euro"


# Tell dumpkeys(1) to interpret character action codes to be 
# from the specified character set.
# This only matters if you set UNICODE="yes" in /etc/rc.conf.
# For a list of valid sets, run `dumpkeys --help`

DUMPKEYS_CHARSET=""
Si algo falla LEE el jodido manual, Si sigue fallando LEE BIEN el jodido manual.
Top
Dabuti
n00b
n00b
Posts: 9
Joined: Thu Oct 14, 2010 4:55 pm

  • Quote

Post by Dabuti » Thu Oct 14, 2010 9:09 pm

He probado a poner todo igual que el tuyo, pero nada sigue igual. Ya te digo que el teclado salvo en las tty y el emulador de terminal de las X escribe todos los caracteres bien, nose... es super extraño no consigo encontrar el problema :(
Top
cameta
Veteran
Veteran
User avatar
Posts: 1394
Joined: Wed Aug 04, 2004 9:51 am

  • Quote

Post by cameta » Thu Oct 14, 2010 9:47 pm

Este par de archivos son para configurar el teclado cuando te encuentras fuera del entorno Grafico.
Dentro del entorno grafico hay que hacer esto:
Configurando su teclado

Para configurar y usar un teclado internacional, puede copiar el contenido de /usr/share/doc/hal-*/*/use-estonian-layout.fdi.bz2 a /etc/hal/fdi/policy/10-xinput-configuration.fdi:

Listado de Código 4.2: Usando un fichero de configuración existente

# bzcat /usr/share/doc/hal-*/*/use-estonian-layout.fdi.bz2 >
/etc/hal/fdi/policy/10-xinput-configuration.fdi

Ahora puede simplemente editar 10-xinput-configuration.fdi y cambiar el modelo de teclado Estonio (ee) al suyo, como Gran Betraña (gb) o Polonia (pl) <?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- -->
<deviceinfo version="0.2">
<device>
<match key="info.capabilities" contains="input.keymap">
<append key="info.callouts.add" type="strlist">hal-setup-keymap</append>
</match>

<match key="info.capabilities" contains="input.keys">
<merge key="input.xkb.rules" type="string">base</merge>

<!-- If we're using Linux, we use evdev by default (falling back to
keyboard otherwise). -->
<merge key="input.xkb.model" type="string">keyboard</merge>
<match key="/org/freedesktop/Hal/devices/computer:system.kernel.name"
string="Linux">
<merge key="input.xkb.model" type="string">evdev</merge>
</match>

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

Cuando haya terminado, ejecute /etc/init.d/hald restart como root para asegurarse de que HAL toma los cambios de su fichero de configuración.

Te queda algo como esto:
Si algo falla LEE el jodido manual, Si sigue fallando LEE BIEN el jodido manual.
Top
cameta
Veteran
Veteran
User avatar
Posts: 1394
Joined: Wed Aug 04, 2004 9:51 am

  • Quote

Post by cameta » Thu Oct 14, 2010 9:47 pm

Code: Select all

<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- -->
<deviceinfo version="0.2">
  <device>
    <match key="info.capabilities" contains="input.keymap">
      <append key="info.callouts.add" type="strlist">hal-setup-keymap</append>
    </match>

    <match key="info.capabilities" contains="input.keys">
      <merge key="input.xkb.rules" type="string">base</merge>

      <!-- If we're using Linux, we use evdev by default (falling back to
           keyboard otherwise). -->
      <merge key="input.xkb.model" type="string">keyboard</merge>
      <match key="/org/freedesktop/Hal/devices/computer:system.kernel.name"
             string="Linux">
        <merge key="input.xkb.model" type="string">evdev</merge>
      </match>

      <merge key="input.xkb.layout" type="string">es</merge>
      <merge key="input.xkb.variant" type="string" />
    </match>
  </device>
</deviceinfo>
Si algo falla LEE el jodido manual, Si sigue fallando LEE BIEN el jodido manual.
Top
Dabuti
n00b
n00b
Posts: 9
Joined: Thu Oct 14, 2010 4:55 pm

  • Quote

Post by Dabuti » Thu Oct 14, 2010 10:01 pm

cameta wrote:

Code: Select all

<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- -->
<deviceinfo version="0.2">
  <device>
    <match key="info.capabilities" contains="input.keymap">
      <append key="info.callouts.add" type="strlist">hal-setup-keymap</append>
    </match>

    <match key="info.capabilities" contains="input.keys">
      <merge key="input.xkb.rules" type="string">base</merge>

      <!-- If we're using Linux, we use evdev by default (falling back to
           keyboard otherwise). -->
      <merge key="input.xkb.model" type="string">keyboard</merge>
      <match key="/org/freedesktop/Hal/devices/computer:system.kernel.name"
             string="Linux">
        <merge key="input.xkb.model" type="string">evdev</merge>
      </match>

      <merge key="input.xkb.layout" type="string">es</merge>
      <merge key="input.xkb.variant" type="string" />
    </match>
  </device>
</deviceinfo>
Ahí no tengo problema ninguno, en el entorno gráfico funciona perfectamente, mi problema es en modo consola, en las tty (uso bash) leo todo correctamente, pero no puedo escribir caracteres especiales como € ñ ç á é etc...
Top
cameta
Veteran
Veteran
User avatar
Posts: 1394
Joined: Wed Aug 04, 2004 9:51 am

  • Quote

Post by cameta » Fri Oct 15, 2010 10:10 am

Sólo se me ocurre que al tratarse de un portatil el mapa es no le sirve.
Prueba con el mapa es-cp850 en /etc/conf.d/keymaps a ver que ocurre.
KEYMAP="es-cp850"
Pon tambíen una foto del teclado de tu portatil si puedes. Eso puede darnos pistas a ver si no es un teclado qwerty.
Si algo falla LEE el jodido manual, Si sigue fallando LEE BIEN el jodido manual.
Top
Dabuti
n00b
n00b
Posts: 9
Joined: Thu Oct 14, 2010 4:55 pm

  • Quote

Post by Dabuti » Sat Oct 16, 2010 10:28 am

cameta wrote:Sólo se me ocurre que al tratarse de un portatil el mapa es no le sirve.
Prueba con el mapa es-cp850 en /etc/conf.d/keymaps a ver que ocurre.
KEYMAP="es-cp850"
Pon tambíen una foto del teclado de tu portatil si puedes. Eso puede darnos pistas a ver si no es un teclado qwerty.
No hay manera :(, te pongo la foto por aquí del teclado:
http://amd264.dyndns.org/DSC00018.jpg

La verdad que no se me ocurre nada más que hacer. Si te viene alguna idea o alguna información que quieras saber y pueda ayudar... avisa please :)
Gracias.
Top
quilosaq
Veteran
Veteran
Posts: 1596
Joined: Tue Dec 22, 2009 5:07 pm

  • Quote

Post by quilosaq » Sat Oct 16, 2010 3:15 pm

Mira si te configura bien el teclado haciéndolo manualmente.

Code: Select all

# loadkeys es
Top
Dabuti
n00b
n00b
Posts: 9
Joined: Thu Oct 14, 2010 4:55 pm

  • Quote

Post by Dabuti » Sat Oct 16, 2010 5:46 pm

quilosaq wrote:Mira si te configura bien el teclado haciéndolo manualmente.

Code: Select all

# loadkeys es
Si, carga el mapa /usr/share/keymaps/i386/qwerty/es.map.gz y lo hace correctamente :S
Top
quilosaq
Veteran
Veteran
Posts: 1596
Joined: Tue Dec 22, 2009 5:07 pm

  • Quote

Post by quilosaq » Sat Oct 16, 2010 6:39 pm

Comprueba que tienes configurado tu sistema para que el el servicio keymaps se cargue durante el arranque

Code: Select all

rc-status boot
Si no lo está lo añades con

Code: Select all

# rc-update add keymaps boot
Top
Dabuti
n00b
n00b
Posts: 9
Joined: Thu Oct 14, 2010 4:55 pm

  • Quote

Post by Dabuti » Sat Oct 16, 2010 8:50 pm

quilosaq wrote:Comprueba que tienes configurado tu sistema para que el el servicio keymaps se cargue durante el arranque

Code: Select all

rc-status boot
Si no lo está lo añades con

Code: Select all

# rc-update add keymaps boot
Si que lo carga :S

Code: Select all

tux2duo dabuti # rc-status boot
Runlevel: boot
 alsasound                                                                                                                                                    [ started  ]
 bootmisc                                                                                                                                                     [ started  ]
 checkfs                                                                                                                                                      [ started  ]
 checkroot                                                                                                                                                    [ started  ]
 clock                                                                                                                                                        [ started  ]
 consolefont                                                                                                                                                  [ started  ]
 hostname                                                                                                                                                     [ started  ]
 keymaps                                                                                                                                                      [ started  ]
 localmount                                                                                                                                                   [ started  ]
 modules                                                                                                                                                      [ started  ]
 net.lo                                                                                                                                                       [ started  ]
 rmnologin                                                                                                                                                    [ started  ]
 urandom                                                                                                                                                      [ started  ]
Top
quilosaq
Veteran
Veteran
Posts: 1596
Joined: Tue Dec 22, 2009 5:07 pm

  • Quote

Post by quilosaq » Sat Oct 16, 2010 10:25 pm

¿Te ocurre sólo cuando entras como root o también con cualquier otro usuario?
Top
Dabuti
n00b
n00b
Posts: 9
Joined: Thu Oct 14, 2010 4:55 pm

  • Quote

Post by Dabuti » Sat Oct 16, 2010 11:01 pm

quilosaq wrote:¿Te ocurre sólo cuando entras como root o también con cualquier otro usuario?
Con cualquier usuario, justo cuando pide el login: puedo escribir todo tipo de caracteres pero una vez logeado sea el usuario que sea, no puedo escribir los caracteres especiales € acentos ñ etc...
Top
quilosaq
Veteran
Veteran
Posts: 1596
Joined: Tue Dec 22, 2009 5:07 pm

  • Quote

Post by quilosaq » Sat Oct 16, 2010 11:09 pm

Yo diría que tienes algún script, que se ejecuta automáticamente, y que está cargando un mapa de teclado erróneo. ¿Qué archivos tienes en /etc/profile.d?
Top
Dabuti
n00b
n00b
Posts: 9
Joined: Thu Oct 14, 2010 4:55 pm

  • Quote

Post by Dabuti » Sun Oct 17, 2010 10:46 am

quilosaq wrote:Yo diría que tienes algún script, que se ejecuta automáticamente, y que está cargando un mapa de teclado erróneo. ¿Qué archivos tienes en /etc/profile.d?
Pues... poca cosa:

Code: Select all

tux2duo ~ # ls /etc/profile.d/
bash-completion.sh  java-config-2.csh  java-config-2.sh
Top
quilosaq
Veteran
Veteran
Posts: 1596
Joined: Tue Dec 22, 2009 5:07 pm

  • Quote

Post by quilosaq » Sun Oct 17, 2010 2:20 pm

Corrijo mi último mensaje. No puede ser debido a la ejecución incorrecta de un loadkeys porque loadkeys necesita permisos de root y en este caso le pasa a todos los usuarios.

¿Qué carácter te sale cuando pulsas la tecla ñ? ¿Y componiendo la á?
Top
esteban_conde
Veteran
Veteran
User avatar
Posts: 1670
Joined: Wed Jun 04, 2003 10:59 am

  • Quote

Post by esteban_conde » Sun Oct 17, 2010 6:42 pm

esteban@localhost ~ $ loadkeys es
Loading /usr/share/keymaps/i386/olpc/es.map.gz
conjeturando iso-8859-1 diaeresis
Couldn't get a file descriptor referring to the console
quilosaq wrote:No puede ser debido a la ejecución incorrecta de un loadkeys porque loadkeys necesita permisos de root
Si te fijas el comando de arriba lo he ejecutado como usuario.
Saludos a tod@s, Esteban.
Top
quilosaq
Veteran
Veteran
Posts: 1596
Joined: Tue Dec 22, 2009 5:07 pm

  • Quote

Post by quilosaq » Sun Oct 17, 2010 8:14 pm

Tienes razón esteban_conde, si que se puede ejecutar como usuario normal aunque he visto casos en los que da mensajes de error si ya hay un mapa de teclado cargado.
Top
Post Reply
  • Print view

21 posts • Page 1 of 1

Return to “Spanish”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic