当计算机启动时,我想以根用户的身份运行脚本。这是早些时候在rc.local中完成的,但现在不是了。
我试过的是:
/etc/profile.d中/pathto/script.sh中添加/etc/profile/pathto/script.sh &中添加/etc/xdg/openbox/autostart该脚本用于设置powertop推荐的内容;当我运行sudo /pathto/script.sh时,脚本工作得很好。
发布于 2013-05-08 14:30:12
你可以把它放在你的crontab中
@reboot /pathto/script.shhttps://unix.stackexchange.com/questions/74995
复制相似问题