# [solved] Keyboard does not work in X

## nowhereman

Hi,

I have a real big problem after the latest update

xorg-server-1.7.7 doesn't accept any keyboard input

I also upgraded to xorg-server-1.8.2 trying to fix the problem,

but that still didn't change a thing

I have a keyboard plugged in via USB and another via PS/2 for testing

both work under windows, in the linux console but not in X

the mouse works without any problem in X

I'm on the stable amd64-tree (except for xorg-server-1.8.2 and its few dependencies)

Xorg-log says the keyboard is added successfully: http://www.privatepaste.com/8357cc661c

The config lies in /etc/X11/xorg.conf.d/10-keyboard.conf: http://www.privatepaste.com/download/66a2995e5c

as the keyboard is working in the console, I think it is X-related.

any idea what the cause could be?

There is another thing, I haven't figured out yet. Not sure whether it's related to the keyboard issue.

But just to be sure I don't miss anything: The DVI-Connection to the display is not working correctly. Neither does it work in Windows nor at early boot or in the linux console.

Only if I force it in X via the option "ConnectedDisplays" "DFP". I get X to display something via DVI. But only in 640x480. And I get a lot of errors about undetectable EDID.

I'm grateful for any hint you could give me. Although the keyboard issue is much more pressing, I don't want to workaround the DVI-problem with VGA as a long term solution.

nowhereman

----------

## rndusr

Have you rebuilt your X drivers?

```
emerge -1av $(qlist -IC x11-drivers/)
```

----------

## nowhereman

yes I have done that

the thing is, he doesn't complain about no driver being avaiable or the keyboard failing to be added

he just doesn't accept any input

I just tried using the 'kdb' driver instead of 'evdev', but the thing got even stranger.

I couldn't type anything into the username, and password fields, but when I opened a menu,

the focus moved on its own, as if the down-arrow-key was held down

but maybe thats just because the kbd-driver doesnt work

----------

## Randy Andy

Hi nowhereman

The reason for your trouble is, that your have to comment out at least the whole input section of your xorg.conf with >xorg-server-1.8.

In most cases you don't need xorg.conf anymore, but for keyboard settings.

Do it simmilar for your language with your new xorg.conf (backup your old for sure)

Here's my content:

```

cat /etc/X11/xorg.conf

Section "InputClass"

    Identifier  "keyboard-all"

    Driver      "evdev"

    Option      "XkbLayout"  "de"

    Option      "XkbVariant" "nodeadkeys"

    MatchIsKeyboard "on"

EndSection

```

Your make.conf has to contain only 

```
INPUT_DEVICES="evdev synaptics" 
```

into this line now, synaptics only if you are using a touchpad

If you have to change that line rebuild again like this:

emerge -1av $(qlist -IC x11-drivers)

Much succes, Andy.

----------

## nowhereman

ok, here is what I did

xorg.conf is like you described it

but I had mouse and keyboard in INPUT_DEVICES

so I removed that in make.conf and did emerge -uDNv world

that reemerged x11-base/x11-drivers

with emerge --depclean both xf86-input-keyboard and xf86-input-mouse got removed

then I did the emerge -1av $(qlist -IC x11-drivers), which reinstalled xf86-input-evdev along with some video-drivers

thanks for the help,

but still nothing has changed  :Sad: 

mouse works, keyboard doesn't

my above paste of xorg.conf.d/10-keyboard.conf doesn't seem to work anymore, so here it is again: http://pastie.org/1279140

xorg.conf itself contains only settings for standbytime, suspendtime and offtime

----------

## Randy Andy

Hi nowhereman,

so far as well, aside of your xorg.conf.d/10-keyboard.conf

I guess it's not needed anymore.

My

```
 ls /usr/share/X11/xorg.conf.d/

10-evdev.conf
```

 only contains the file showed.

 So try to delete the 10-keyboard.conf file.

My 10-evdev.conf file i didn't create by my own looks like this:

```

cat /usr/share/X11/xorg.conf.d/10-evdev.conf

#

# Catch-all evdev loader for udev-based systems

# We don't simply match on any device since that also adds accelerometers

# and other devices that we don't really want to use. The list below

# matches everything but joysticks.

Section "InputClass"

        Identifier "evdev pointer catchall"

        MatchIsPointer "on"

        MatchDevicePath "/dev/input/event*"

        Driver "evdev"

EndSection

Section "InputClass"

        Identifier "evdev keyboard catchall"

        MatchIsKeyboard "on"

        MatchDevicePath "/dev/input/event*"

        Driver "evdev"

EndSection

Section "InputClass"

        Identifier "evdev touchpad catchall"

        MatchIsTouchpad "on"

        MatchDevicePath "/dev/input/event*"

        Driver "evdev"

EndSection

Section "InputClass"

        Identifier "evdev tablet catchall"

        MatchIsTablet "on"

        MatchDevicePath "/dev/input/event*"

        Driver "evdev"

EndSection

Section "InputClass"

        Identifier "evdev touchscreen catchall"

        MatchIsTouchscreen "on"

        MatchDevicePath "/dev/input/event*"

        Driver "evdev"

EndSection

```

So give it a try,

Andy.

----------

## nowhereman

wow, that worked out, I removed xorg.conf, 10-keyboard.conf and 10-display.conf and the keyboard works

thanks so much

now I just have to figure out, how to get the keyboard-layout right

...

that is strange; it is actually the XkbVariant setting, that caused the error

latin1 seems to be not valid, nodeadkeys works now

Why did I get no error message in the logfile?

So again, thanks a lot for all the help.

----------

## Randy Andy

nowhereman,

fine that i could help you out.

To set your keyboard Layout, you could use my xorg.conf from post above.

Eventually you have to add something for the keyboard layout there.

I don't need it, cause i've set it via the control Gui of KDE.

Best regards, Andy.

----------

