You are not logged in.
Pages: 1
Hello,
First of all I would like to let you know that I am a Newbie with Linux and Python. I have a Python script on my Raspberry Pi running on Arch Linux. To start the script, I use this command:
sudo pythong2 screen/screen.pyand it works perfectly. Now, my question is, how I can run this script automatically on start-up?
Offline
Arch Linux doesn't run on ARM: https://bbs.archlinux.org/viewtopic.php?id=153431
https://wiki.archlinux.org/index.php/Autostarting
You have to post what exactly do you mean by 'start-up': booting to console, straight to X - if so, what WM / DE etc.
Offline
Not a Programming issue, moving to NC...
Offline
https://wiki.archlinux.org/index.php/Sy … vice_files
Asuming your script is something that should be run at startup, and not at login by your user.
Evil #archlinux@libera.chat channel op and general support dude.
. files on github, Screenshots, Random pics and the rest
Offline
Hello
I have a Python program running in an Raspberry. (As Mr.Elending, Karol points) It starts at startup, not at login, and it keeps running.
I'll tell what I've done, but surely is very interesting read more about it.
You must use a system's de service unit. Locate it in /etc/systemd/system.
Example:
/etc/systemd/system/ana-server.service
[Unit]
Description=Servidor TCP/IP-Serie para la comunicacion con los sensores del Arduino
After=syslog.target network.target
[Service]
ExecStart=/usr/share/analog/analogArduinoServer.py
Restart=on-abort
[Install]
WantedBy=multi-user.targetTry first with
systemctl daemon-reload
systemctl start ana-server.serviceIf it works, do the next to it start at boot:
systemctl enable ana-server.serviceAbout the Python script:
In my case I've change its permissions to executable.
Too, I think, you can put in parameter ExecStart=python /usr/share/analog/analogArduinoServer.py
You can move your Python script to another place.
Last edited by Alber (2014-01-05 17:58:14)
Because not all of us are native English speakers, try no to use slang or abbreviations, thank you.
Offline
Pages: 1