1 1
SaiHou

OrangePi Zero Stable Debian Jessie 3.4.113

Recommended Posts

Hello there,

 

I am looking a way to get / write a script for the file to be run on startup.

 

I am running PiAware with dump1090-fa installed. I would like to having the

view1090-fa --modeac

to be auto run when the system is ON. Is there a way to get this work without my concern in the future?

 

Currently if I need to run this command, I need to run SSH and remote the Pi to run this command from my PC. Thank you in advance.

 

Regards,

SaiHou

Share this post


Link to post
Share on other sites
16 hours ago, martinayotte said:

You may call this command at startup using /etc/rc.local ...

 

Hi martinayotte,

 

Thank you for the advise.

 

Is it something like:-

 

sudo nano /etc/rc.local

  GNU nano 2.7.4                 File: /etc/rc.local

#!/bin/sh -e
#
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to disable this script please use systemd to control the service:
# systemctl disable rc-local.service
#
# By default this script does nothing.

view1090-fa --modeac

exit 0

Then reboot and the view1090-fa --modeac will run automatically? Thank you once again.

 

Regards,

SaiHou

Share this post


Link to post
Share on other sites
12 hours ago, martinayotte said:

Right !

For other kind of apps which run in background, ampersand need to be added, example :


python run_for_ever.py &

 

Thanks for the reply. It only works in Armbian Debian Jessie.

For the Raspbian Jessie it will not work. Any clue on this to solve it?

Thanks once again.

Share this post


Link to post
Share on other sites
22 minutes ago, martinayotte said:

euuh ? /etc/rc.local should exist on both !

I'm don't know what can be wrong in Rasbian ...

 

Hi martinayotte,

 

I have no idea. Both OS has this file but only the Armbian is working, Raspbian is not. No clue.

 

Anyway, thank you for sharing info.

 

Regards.

Share this post


Link to post
Share on other sites
1 1