You are not logged in.
Hello everyone,
I am using [kanata](https://github.com/jtroo/kanata) to rebind my keyboard, and I am running it as a systemd service, as described [here](https://github.com/jtroo/kanata/blob/ma … p-linux.md).
After a recent update, the service will not start, unless I manually run "sudo modprobe uinput" after every reboot.
The error I get before running the command above looks like:
```
$ kanata
12:00:41.9878 [INFO] kanata v1.9.0 starting
12:00:41.9884 [WARN] No defcfg is defined. Consider whether the process-unmapped-keys defcfg option should be yes vs. no. Adding defcfg with process-unmapped-keys defined will remove this warning.
12:00:41.9884 [INFO] process unmapped keys: false
12:00:41.9891 [INFO] config file is valid 12:00:41.9892 [ERROR] Failed to open the output uinput device. Make sure you've added the user executing kanata to the uinput group
12:00:41.9892 [ERROR] Permission denied (os error 13)
```
I added uinput to "/etc/modules-load.d/uinput.conf" and I can start the service by "systemctl --user start kanata.service", but "systemctl --user enable kanata.service" does not make it start automatically for some reason.
Is there a way to overcome this and start it automatically?
What recent change might have caused this behavior?
Last edited by arismav (2025-09-19 12:01:59)
Offline
Systemd has this in it's changelog
* systemd-udevd ignores OWNER=/GROUP= settings with a non-system
user/group specified in udev rules files, to avoid device nodes being
owned by a non-system user/group. It is recommended to check udev
rules files with 'udevadm verify' and/or 'udevadm test' commands if
the specified user/group in OWNER=/GROUP= are valid.
Similarly, systemd-networkd refuses User=/Group= settings with a
non-system user/group specified in .netdev files for Tun/Tap
interfaces.
"Non-system groups" are likely groups with a GID higher than 1000 so a quick fix would be to make sure the GID of uinput is lower than that, but this feels ugly, I'd assume a proper session rule should work better? But not sure whether kanata hard expects the uinput group, but that a simple reload of the module works around this also sounds weird.
Offline
Thanks a lot for the explanation V1del.
I suppose it would be good to ask the kanata people about it to see if there's any elegant solution to this.
Hopefully Ill have an update soon.
Offline
I experience the same issue except I can not start Kanata even after I run `sudo modprobe uinput`.
Offline
A fix has been provided here: https://github.com/jtroo/kanata/issues/1799
Offline