Home | News | Download | Packages | Forum | Wiki | Github

How to set trackpoint settings on boot? Command in rc.local commands leads to permission denied


I want to increase my trackpoint speed and sensitivity so I added the commands below to my /etc/rc.local file

# Default rc.local for void; add your custom commands here.

echo -n 255 > /sys/devices/platform/i8042/serio1/speed 
echo -n 255 > /sys/devices/platform/i8042/serio1/sensitivity

# This is run by runit in stage 2 before the services are executed
# (see /etc/runit/2).

However, upon boot, before I’m prompted to login to my console, I see that the command fails with the following error message.

cannot create /sys/devices/platform/i8042/serio1/sensitivity: Permission denied

I thought /etc/rc.local was run with administrative privileges, is it not?


sounds like the device is not even there yet.


“Permission denied” can come up in all sorts of circumstances even when you are root.


 cd /sys/devices
 mkdir test123
 echo 'Mooo' > anothertest

Both of these commands will try to create files/folders in the sysfs filesystem. sysfs is not a normal disk filesystem (like ext4, fat, etc), it’s one designed to provide an interface and some info; not to permanently store data.

My guess: the file you are trying to write to does not exist this early in the boot process; so sysfs thinks you are trying to create a new file. It probably gets added by udev a bit later. You’ll probably need to create a service that waits for the file to exist, then writes to it.


Thanks for the explanation.

Are there other alternatives than creating a service? Having to create a service to simply set the trackpoint speed and sensitivity seems overkill.

But, if there’s no other way – then I will.

(Masato the Empty) #5

I thought sysfs originated completely with the kernel (udev is userland and deals with populating /dev and other actions). But I’m not an expert so I’d recommend the OP seek more info if he wants to be sure.

If I’m correct, then you shouldn’t have to wait for any service unless that service is triggering some kernel module load that wouldn’t otherwise occur. And if that’s the case, then you just need to figure out what module/interface needs loading and see that it gets done before you try to touch said interfaces.


Do you have a configuration file for your touchpad in:


Whenever I have had to reconfigure my trackpoint/touchpad, I’ve had to copy that file to:


then make the changes. Pretty sure the file needs to be made executable as well.


Just read Arch Linux’s bit on Trackpoint, which suggest to create a service since it seems that the interfaces appear too late in the boot process.

There have been reports on the forums that the attributes/files under /sys/devices/platform/i8042/serio1/serio2/ appear too late in the boot process for the above (or similar) udev rule(s) to have an effect on them. Instead, a systemd.path unit can be used to configure attributes of the TrackPoint.

(Matthew Underwood) #8

Did you ever figure out a solution to this problem? I’m going through the same pains currently.


I think the right place is /etc/X11/xorg.conf.d/


I don’t have that directory structure.

The 90-consolekit file was located in /etc/X11/xinit/xinitrc.d so I just went with that.

May be a glitch on my end, I’ve been using the mk-live scripts to roll my own iso’s so I won’t rule out having done something.


Because you place your file in the wrong folder. :wink: