Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions src/fancurve.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
[Unit]
Description=FanCurve
After=network.target

[Service]
Type=simple
ExecStart=/location/of_the/scripts/set_fancurve.sh
Restart=on-failure
User=root

[Install]
WantedBy=multi-user.target
39 changes: 39 additions & 0 deletions src/fancurve.service.instructions
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
To setup:
sudo vi /lib/systemd/system/fancurve.service
sudo systemctl daemon-reload
sudo systemctl enable fancurve
sudo systemctl start|stop|restart|status fancurve <--- Control options

====================================
NOTE: This startup script has the ability to restart itself on failure




Examples of output showing sleep and when a fan curve change occurs.


fireheadman@clauneck:~/scripts$ sudo systemctl status fancurve -l
● fancurve.service - FanCurve
Loaded: loaded (/lib/systemd/system/fancurve.service; enabled; vendor preset: enabled)
Active: active (running) since Wed 2018-04-11 22:05:57 MDT; 1min 3s ago
Main PID: 12312 (set_fancurve.sh)
Tasks: 2
Memory: 296.0K
CPU: 13.565s
CGroup: /system.slice/fancurve.service
├─12312 /bin/bash /home/fireheadman/scripts/set_fancurve.sh
└─12437 sleep 1s

Apr 11 22:05:57 clauneck systemd[1]: Started FanCurve.
fireheadman@clauneck:~/scripts$ sudo systemctl status fancurve -l
● fancurve.service - FanCurve
Loaded: loaded (/lib/systemd/system/fancurve.service; enabled; vendor preset: enabled)
Active: active (running) since Wed 2018-04-11 22:05:57 MDT; 1min 4s ago
Main PID: 12312 (set_fancurve.sh)
Tasks: 3
Memory: 1.1M
CPU: 13.572s
CGroup: /system.slice/fancurve.service
├─12312 /bin/bash /home/fireheadman/scripts/set_fancurve.sh
└─12442 nvidia-settings -a [fan-5]/GPUTargetFanSpeed=60