Non-root script

Non-root script

You are here:
< All Topics
Table of Contents

THE PURPOSE OF THIS DOCUMENT IS TO HOW TO START FEEDING RAWFLIGHT WITH SCRIPT THAT DOES NOT REQURE ROOT PRIVILEGES

IMPORTANT!
This script has to be run as root. This is caused by Linux Security Policy that does not allow to run Bash Scripts as standard user. After installation, you can delete this script.

This script uses Cron. Please Follow this document very carefully.

This manual has been written using Hyper-V Ubuntu 19.10 Virtual Machine with x64 Architecture. The way of working on this script is the same on ARM-based devices like Raspberry Pi with Raspian. Please do not care about this fact.

STEP 1 – Introduction – please read it carefully

This script is written completely another way than Root Script. It is much more automated, so no preparation action is required. This script checks your Receiver for all required software, if some if the software is not installed, it will simply install it. Please proceed to Step 2.

STEP 2 – Download script and prepare it

  1. Download script using wget:
    wget —nocheckcertificate https://rawflight.eu/nonroot_rawflight.sh

  2. As sudoer (or root), make this script executable. For this training purposes, we will do it as sudoer. If your account is not in sudoer group, login as root (su).

  3. Execute script. Remember to run it as root or sudoer. Otherwise, you will receive prompt: You need to run this script as root.
  4. When you run this script, it will scan your system for socat and dump1090 and its forks like dump1090-fa or dump1090-mutability.
    If the script will not wind socat, it will automatically install it. It will do the same in case of no dump1090 installed. Also, script will install all missing dependencies. It will take a while.

  5. Take a look at the screenshot. This is very, very important step, because you need to assign a user to the cron job. This user will control socat feed service.
    DEFAULT USERNAME IS: pi
    If username of the user that will handle this cron job is different than pi, you need to provide correct username there.
    For this training purposes, username is demovm. Enter your username and then click “enter”.
    You will get information as on the screenshot below:

IMPORTANT:
If after providing username you received error:
no cronab for yoursername
Please execute command:
crontab -e
If you will see the line as on the screenshot, eveything is fine. This command created crontab for this user with the username provided in script.

If this line does not exist, please exit Crontab using Ctrl+X (if Nano editor used) and execute script again.