请告诉我如何在启动时自动执行以下命令,而不必每次都手动输入:
sudo thinkfan -n发布于 2016-12-12 21:08:18
只需通过键入以下命令启用rc.local文件
sudo systemctl enable rc-local.service之后,将您想要的所有命令添加到以下文件中
nano /etc/rc.local发布于 2016-12-12 21:06:18
正如在zmalltalker.com上所描述的,您必须创建一个systemd服务。
创建一个文件,例如具有以下内容的/usr/lib/systemd/system/thinkfan.service:
[Unit]
Description=simple and lightweight fan control program
[Service]
ExecStart=/usr/sbin/thinkfan -q -n
[Install]
WantedBy=multi-user.target启用并启动服务。
sudo systemctl enable thinkfan.service
sudo systemctl start thinkfan.servicehttps://askubuntu.com/questions/859991
复制相似问题