Hello.
I just installed debian 11. I want a program to start when I start Debian.
That it is not necessary to open a session, for the program to be executed.
Greetings.
Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230
[Software] Run a program at startup
-
- Posts: 444
- Joined: 2023-02-07 13:35
- Been thanked: 105 times
Re: [Software] Run a program at startup
/etc/rc.local can be used to run commands at the end of the multi-user "runlevel" (.target under systemd).
Make the file executable to enable the script, as per the comments in the file.
Make the file executable to enable the script, as per the comments in the file.
Jeder nach seinen Fähigkeiten, jedem nach seinen Bedürfnissen.
- fabien
- Forum Helper
- Posts: 668
- Joined: 2019-12-03 12:51
- Location: Anarres (Toulouse, France actually)
- Has thanked: 61 times
- Been thanked: 154 times
Re: [Software] Run a program at startup
There is also the possibility to use cron.
man 5 crontab
man 5 crontab
Code: Select all
string meaning
------ -------
@reboot Run once, at startup.
Re: [Software] Run a program at startup
A systemd script in a service unit file will accomplish this. Many examples online.
- kent_dorfman766
- Posts: 540
- Joined: 2022-12-16 06:34
- Location: socialist states of america
- Has thanked: 59 times
- Been thanked: 70 times
Re: [Software] Run a program at startup
The systemd unit approach is more appropriate than the crontab approach. rc.local is fine, but creating a distinct unit service file makes you learn how.