udev rule for starting/stopping DisplayLinkManager on plug/unplug
I read about high battery drain with a running DisplayLinkManager so i decided to only start the process when the dock is attached. This is what I have come up with:
Requirements: A working upstart or systemd script At first I created a (very basic) shell script at /usr/local/bin/startDisplayLink.sh for controlling the service because udev can't control services directly. Code:
#!/bin/bash Code:
ACTION=="add", ATTR{product}=="Dell D3100 USB3.0 Dock", RUN+="/usr/local/bin/startDisplayLink.sh start" |
All times are GMT. The time now is 02:58 PM. |
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.