2

I'm using Ubuntu 13.04 with i3 4.5.1. When i3wm starts, Ctrl-C/-D/-K etc. are working fine. When I start Dropbox, notify-send or change the volume, all Ctrl-something shortcuts stop working.

I can reproduce the issue:

  1. restart X, login to i3wm
  2. open terminal, verify that Ctrl-C, Ctrl-A, Ctrl-K and Ctrl-D work => works
  3. start one of the following programs:
    • Dropbox with /usr/bin/dropbox start
    • trigger an OSD notification with notify-send "Test"
    • change the volume with the volume key
  4. try Ctrl-C, -A, -K and -D in terminal again => does not work anymore

To restore the Ctrl-something shortcuts, I have to restart X. Interestingly, commands with Shift-Ctrl-something still work, if Shift is pressed first.

Here's the output from xev when I press Ctrl-C. Before executing step 3 above:

    KeyPress event, serial 33, synthetic NO, window 0x1a00001,
        root 0x259, subw 0x0, time 7988829, (-219,177), root:(505,197),
        state 0x0, keycode 37 (keysym 0xffe3, Control_L), same_screen YES,
        XLookupString gives 0 bytes: 
        XmbLookupString gives 0 bytes: 
        XFilterEvent returns: False

    KeyPress event, serial 33, synthetic NO, window 0x1a00001,
        root 0x259, subw 0x0, time 7988878, (-219,177), root:(505,197),
        state 0x4, keycode 54 (keysym 0x63, c), same_screen YES,
        XLookupString gives 1 bytes: (03) "^C"
        XmbLookupString gives 1 bytes: (03) "^C"
        XFilterEvent returns: False

    KeyRelease event, serial 33, synthetic NO, window 0x1a00001,
        root 0x259, subw 0x0, time 7988949, (-219,177), root:(505,197),
        state 0x4, keycode 54 (keysym 0x63, c), same_screen YES,
        XLookupString gives 1 bytes: (03) "^C"
        XFilterEvent returns: False

    KeyRelease event, serial 33, synthetic NO, window 0x1a00001,
        root 0x259, subw 0x0, time 7988970, (-219,177), root:(505,197),
        state 0x4, keycode 37 (keysym 0xffe3, Control_L), same_screen YES,
        XLookupString gives 0 bytes: 
        XFilterEvent returns: False

After step 3 from above:

    KeyPress event, serial 33, synthetic NO, window 0x1e00001,
        root 0x259, subw 0x0, time 8064649, (-238,542), root:(486,562),
        state 0x0, keycode 37 (keysym 0xffe3, Control_L), same_screen YES,
        XLookupString gives 0 bytes: 
        XmbLookupString gives 0 bytes: 
        XFilterEvent returns: False

    FocusOut event, serial 33, synthetic NO, window 0x1e00001,
        mode NotifyGrab, detail NotifyAncestor

    FocusIn event, serial 33, synthetic NO, window 0x1e00001,
        mode NotifyUngrab, detail NotifyAncestor

    KeymapNotify event, serial 33, synthetic NO, window 0x0,
        keys:  2   0   0   0   32  0   0   0   0   0   0   0   0   0   0   0
               0   0   0   0   0   0   0   0   0   0   0   0   0   0   0   0

    KeyRelease event, serial 33, synthetic NO, window 0x1e00001,
        root 0x259, subw 0x0, time 8064926, (-238,542), root:(486,562),
        state 0x4, keycode 37 (keysym 0xffe3, Control_L), same_screen YES,
        XLookupString gives 0 bytes:
        XFilterEvent returns: False

I have no idea where I should start debugging the problem. Can you give me some pointers how to find the cause of this problem?

Thanks!

Benedikt

1 Answer 1

1

OK I managed to locate the cause of the problem. For other people having this issue, here's how to find the cause

  1. follow the advice from http://mg.pov.lt/blog/xorg-snafu.html and kill gnome-settings-manager, then check if the Ctrl-shortcuts started to work again. If that's the case, you hit the bug that Marius described on his page and probably should upgrade X.org.
  2. If that didn't solve the problem, use xrestop to get a list of all X applications. Kill one of them, re-try the Ctrl-shortcuts and repeat. You might find which X application had captured the Ctrl key.
  3. If Ctrl-shortcuts still don't work, start killing other processes (found with ps aux), re-try the Ctrl-shortcuts and repeat. One of the processes will be capturing the Ctrl-key. Of course, you might lose data or your system might crash when you randomly kill processes...

For me, 1. and 2. didn't solve the problem. In the third step, I found that dunst was capturing the Ctrl-key. dunst is a notification daemon, Dropbox notifications, notify-send and other On Screen Displays are handled by dunst on my system. That explains why the problem happened as soon as I start one of those programs. I have uninstalled dunst, but for those who want to keep you can also change the modifier key in ~/.config/dunst/dunst (don't set it to ctrl).

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .