Karabiner-Elements icon indicating copy to clipboard operation
Karabiner-Elements copied to clipboard

Karabiner stops working properly after going to sleep in MacOS Monterey 12.3.1

Open jaideeprana opened this issue 2 years ago • 21 comments

MacOS: Monterey 12.3.1 Karabiner: 14.4.0

Problem: Twice now, I've returned to my laptop in the morning and Karabiner is no longer functioning properly and my modifications within Karabiner no longer work. Restarting Karabiner did not solve the issue. Restarting the computer did solve the problem.

jaideeprana avatar May 05 '22 19:05 jaideeprana

Same issue.

unknown0xff avatar May 07 '22 18:05 unknown0xff

I have this issue too. Restart seems to fix it.

olivier-leduc avatar May 08 '22 18:05 olivier-leduc

@unknown0xff and @olivier-leduc please up-vote the issue so that it gets prioritized.

jaideeprana avatar May 08 '22 19:05 jaideeprana

Seems like my mac that is on Monterey 12.3.1 (A) has this but another mac of mine that is on 12.4 (B) does not have the same problem. Not sure if that is due to (A) being intel and (B) being apple silicon.

Let me try updating (A) to 12.4 and see if the problem persists.

chunleng avatar May 17 '22 16:05 chunleng

Seems like my mac that is on Monterey 12.3.1 (A) has this but another mac of mine that is on 12.4 (B) does not have the same problem. Not sure if that is due to (A) being intel and (B) being apple silicon.

Let me try updating (A) to 12.4 and see if the problem persists.

Seem like upgrading to 12.4 did not work for intel mac. i guess this issue does not affect apple silicon

chunleng avatar May 18 '22 00:05 chunleng

Can confirm that the issue exists in Mac OS 12.4 as well.

jaideeprana avatar May 19 '22 11:05 jaideeprana

Checking "Prevent your Mac from automatically sleeping when the display is off" (under battery > power adapter system preference) works temporarily at the cost of more power usage. Maybe this will help people who are heavily dependent on Karabiner

Screen Shot 2022-05-20 at 14 07 16

chunleng avatar May 20 '22 05:05 chunleng

just upgraded to 12.5 and the problem is still present.

olivier-leduc avatar Aug 12 '22 21:08 olivier-leduc

Issues still exist for me with upgrade to macOS v12.6

kopach avatar Sep 18 '22 19:09 kopach

Workaround: Just discovered, that for me, it's enough to kill Karabiner-DriverKit-VirtualHIDDeviceClient for karabiner to start working again. This process will start back again in few seconds and Karabiner works normally after that 2022-11-08_08-53

kopach avatar Nov 08 '22 07:11 kopach

Super thank you @kopach for the workaround. For the time being I have a rk alias (restart karabiner) that I'll resort to whenever Karabiner stops working.

# .zshrc file
alias rk="sudo pkill Karabiner-DriverKit-VirtualHIDDeviceClient"

I'm happy to dig up more debug information whenever the problem happens if it helps solving it.

amalbuquerque avatar Nov 15 '22 13:11 amalbuquerque

Here is update to @amalbuquerque alias, which works now with newer version of Karabiner (14.11.0)

sudo pkill karabiner_console_user_server

So, in my case it looks like this now

# .zshrc file
alias restart-karabiner="sudo pkill karabiner_console_user_server"

kopach avatar Jan 20 '23 20:01 kopach

I have the same issue on macOS 13.1, Apple Silicon, 14" 2021 M1 MBP. Karabiner Elements 14.11.0. Restarting Karabiner fixes it.

snarfed avatar Jan 28 '23 18:01 snarfed

Feels similar to #1932. I am also experiencing this often, sudo pkill karabiner_console_user_server does not work for me. However, opening activity monitor and killing everything that has karabiner in its name seems to work mostly.

SirVer avatar Jan 29 '23 19:01 SirVer

Could be an issue of macOS itself. I sometimes experience similar behavior with macOS native calendar app. It stops syncing at some point (which is very difficult to spot until you've missed some invitation already) and the only way to fix this without system reboot is to kill calendar and related service running under the hood (there are few of them, don't remember which one exactly responsible for this).

kopach avatar Jan 31 '23 14:01 kopach

Here is update to @amalbuquerque alias, which works now with newer version of Karabiner (14.11.0)

sudo pkill karabiner_console_user_server

So, in my case it looks like this now

# .zshrc file
alias restart-karabiner="sudo pkill karabiner_console_user_server"

Hello, I experienced same issue in Big Sur 11.7 (recently upgraded to monterey and still persist so I downgraded back to big sur), do I need to type that in terminal? oh did your keyboard affected with that too? because my wired keyboard seems not working completely whenever karabiner stop working after macbook wake from sleep :/

chryscaelum avatar Aug 23 '23 10:08 chryscaelum

I'm on macOS Ventura 13.4 for some time already. And this defect isn't reproducible for me. If someone else could confirm this — the issue could be closed.

kopach avatar Aug 29 '23 11:08 kopach

I'm still facing this issue on macOS Ventura 13.6 and Karabiner 14.12.0 on a 2019 MacBook pro. sudo pkill karabiner_console_user_server works for me.

I've noticed that it happens more often if I allow the laptop to go to sleep by itself on battery. I can't remember it happening recently if I have shut the lid and made it sleep myself, or when it was plugged in.

siddharth-krishna avatar Sep 25 '23 18:09 siddharth-krishna

I had this issue on M2 Air. Sometimes after opening the lid, the karabiner modifications weren't working. The whole computer seemed to be somewhat freezy and unusable. It was not exactly freezed, but some apps freezed, and the keyboard sometimes did not work correctly: I could see modifiers pressed (I have sticky keys enabled), but I could not type.

After upgrading to macOS Sonoma 14.2.1, sometimes the OS gets stuck after I open the lid and enter my password. It keeps spinning that spinner icon and nothing happens. I wonder if this new issue is the same one I had before, and related to Karabiner, or if it's something else.

NightMachinery avatar Jan 07 '24 21:01 NightMachinery

After upgrading to macOS Sonoma 14.2.1, sometimes the OS gets stuck after I open the lid and enter my password. It keeps spinning that spinner icon and nothing happens. I wonder if this new issue is the same one I had before, and related to Karabiner, or if it's something else.

One time when Karabiner had stopped working, I locked the screen and then tried to login again. It got stuck with a spinner. So my guess is that the problem is indeed with Karabiner.

There was another report of something very similar to my case happening that was caused by karabiner:

Occasional semi-freeze of my Mac Mini M1 ... - Apple Community

So a bit of digging around and I found that there was a setting in 'Security & Privacy' for Input Monitoring which included old references to Karabiner Elements, that I had previously installed before getting my Logitech MX keys and then uninstalled, but leaving references to two components of this software behind; I removed them and rebooted and since then (touch wood) haven't hadn't any issue!


@siddharth-krishna

I've noticed that it happens more often if I allow the laptop to go to sleep by itself on battery. I can't remember it happening recently if I have shut the lid and made it sleep myself, or when it was plugged in.

This problem happens when I close the lid myself and the laptop is connected to a power source. I doubt these matter.

The only thing I can say is that macOS Sonoma made everything much worse. This used to happen every week or so. Now it happens like every day.

NightMachinery avatar Jan 09 '24 22:01 NightMachinery

One thing I am suspicious of; do you guys have a steady WiFi? I use mobile hotspots to connect to the internet, and so when the laptop wakes from sleep, it usually has no network connections. I remember reading somewhere that Apple keeps trying to verify the keyboard's signature using the internet and this can cause the system to crash or semi-freeze when there is no connection.

NightMachinery avatar Jan 09 '24 22:01 NightMachinery