My upstart job which configured my trackpoint sensitivity (Values 255, 255) does not work anymore. How can I get equivalent behaviour with systemd?
Thinkpad – Increase Trackpoint Sensitivity with SystemD on Ubuntu 15.04 or Later
systemdthinkpadtrackpoint
Related Solutions
If you want to, you can instead make a systemd .service
file that does the same thing. A basic systemd .service
file for the above command might look like the following:
[Unit]
Description=Start VNC server
Requires=lightdm.service
After=lightdm.service
[Service]
ExecStart=/usr/bin/x11vnc -auth /var/run/lightdm/root/:0 -display :0 -rfbauth /etc/x11vnc.pass -rfbport 5900 -noxrecord -noxfixes -noxdamage -forever
[Install]
WantedBy=graphical.target
Things to note:
- Because this service relies on lightdm starting up, I've added a
Requires=lightdm.service
. This means that if this service is requested to start, thenlightdm.service
will also be asked to start, but iflightdm.service
fails to start, then this service won't be asked to start. Additionally,After=lightdm.service
is needed so that this service will start after `lightdm.service has finished starting. - The command being run doesn't have
-bg
specified. In systemd, it's preferred that services stay in the foreground, so that systemd knows that they are running. Note that it is possible to specify a PID file for a service that goes into the background. WantedBy=graphical.target
specifies that, as part of starting up your GUI, this should also get started up.
To install this file so that the service is run as root, add this file into /etc/systemd/system
. Then, run sudo systemctl enable <filename>
(where <filename>
is the name of the service file in /etc/systemd/system
). A symlink should be created in /etc/systemd/system/graphical.target.wants/
. After rebooting, when you run systemctl status <filename>
, you should see that the service is recognized and not yet started.
Note that /etc/systemd/system/
is meant for system-wide services that the system administrator (you) add. /lib/systemd/system/
is meant for system-wide services installed by packages. You do not need to make a symlink to /lib/systemd/system/
for the service to load. The below table (taken from the systemd.unit
manpage) describes what each location is for with regards to system services (there are separate paths for user services):
┌────────────────────┬─────────────────────────────┐
│Path │ Description │
├────────────────────┼─────────────────────────────┤
│/etc/systemd/system │ Local configuration │
├────────────────────┼─────────────────────────────┤
│/run/systemd/system │ Runtime units │
├────────────────────┼─────────────────────────────┤
│/lib/systemd/system │ Units of installed packages │
└────────────────────┴─────────────────────────────┘
Best Answer
sudo -i gedit /etc/tmpfiles.d/tpoint.conf
Add the following lines (*):
Adjust the numbers to your liking. Higher = More Fast/Sensitive --
press_to_select
is for tapping on the trackpoint to simulate a click.1
to enable.Save, Exit.
sudo systemd-tmpfiles --prefix=/sys --create
(*) Thinkpad X1 Yoga Or Thinkpad W530 users will need to modify slightly:
w /sys/devices/platform/i8042/serio1/serio2/...
You can find out the exact path on your device via:
Personal Recommendation
After you get used to it, your finger will have to do much less effort into moving the cursor and will greatly reduce any strains or pains in your finger.