How-to Install dump1090-fa on Arch Linux x64_86 and on AlarmPi


#1

Build and Install dump1090-fa on following distros of Arch Linux

(1) Arch Linux x64_x86
(2) AlarmPi (Arch Linux for armhf RPi 2/3 )

STEP-1

1.1 - Create a file install-dump-fa.sh
1.2 - Make it executable
1.3 - Open it in nano to edit it

[abcd@archlinux ~]$ sudo touch install-dump1090-fa.sh
[abcd@archlinux ~]$ sudo chmod +x install-dump1090-fa.sh
[abcd@archlinux ~]$ sudo nano install-dump1090-fa.sh

STEP-2

2.1 - Copy-paste following code in the newly created file install-dump1090-fa.sh
2.2 - Save the file (Ctrl+o) and close it (Ctrl+x)

NOTE: Scroll down to see full code. Only part is displayed in the window below

#!/bin/bash
#first move to home directory
#all subsequent code is relative to home directory
cd ~/

#Install build tools and dependencies
yes | sudo pacman -Sy git wget make pkg-config gcc rtl-sdr lighttpd

#Clone source code
sudo git clone https://github.com/flightaware/dump1090.git

cd ~/dump1090

#Do you have bladeRF? 
#If not, you dont need to install its support package
#Make dump1090-fa package WITHOUT bladeRF

sudo make BLADERF=no

#CONFIGURE DUMP1090-FA
sudo cp ~/dump1090/dump1090  /usr/bin/dump1090-fa
sudo mkdir -p /usr/share/dump1090-fa
sudo cp -r ~/dump1090/public_html  /usr/share/dump1090-fa/html
sudo cp ~/dump1090/debian/dump1090-fa.default  /etc/default/dump1090-fa
sudo cp ~/dump1090/debian/dump1090-fa.service  /lib/systemd/system/dump1090-fa.service
sudo systemctl enable dump1090-fa.service
sudo useradd --system dump1090

## CONFIGURE LIGHTTPD
sudo cp /etc/lighttpd/lighttpd.conf  /etc/lighttpd/lighttpd.conf.orig
sudo mkdir /etc/lighttpd/conf.d
sudo cp ~/dump1090/debian/lighttpd/88-dump1090-fa-statcache.conf  /etc/lighttpd/conf.d/
sudo cp ~/dump1090/debian/lighttpd/89-dump1090-fa.conf  /etc/lighttpd/conf.d/

#Add "server.module" and "include" lines in lighttpd.conf
sudo chmod 777  /etc/lighttpd/lighttpd.conf
sudo echo ""  >> /etc/lighttpd/lighttpd.conf
sudo echo "server.modules += ( \"mod_alias\" )" >> /etc/lighttpd/lighttpd.conf
sudo echo "include \"/etc/lighttpd/conf.d/*\""  >> /etc/lighttpd/lighttpd.conf
sudo chmod 644  /etc/lighttpd/lighttpd.conf

sudo systemctl enable lighttpd
sudo systemctl restart lighttpd
sudo systemctl restart dump1090-fa

#
#

STEP-3

3.1 - Run the script

[abcd@archlinux ~]$ ./install-dump1090-fa.sh

STEP-4

4.1 - Open your broeser and see SkyView map at this address:
localhost/dump1090-fa
IP-of-Pi/dump1090-fa/

STEP-5

5.1 - Open file /etc/default/dump1090-fa for editing

[abcd@archlinux ~]$ sudo nano /etc/default/dump1090-fa

.
5.2 - Scroll down to following line
RECEIVER_OPTIONS="--device-index 0 --gain -10 --ppm 0 --net-bo-port 30005"

.
5.3 - Add --lat xx.xxxx lon yy.yyyy so line becomes like below
NOTE: Replace xx.xxxx and yy.yyyy by your actual latitude and longitude

RECEIVER_OPTIONS="--device-index 0 --gain -10 --ppm 0 --net-bo-port 30005 --lat xx.xxx --lon yy.yyyy"

.
5.4 - Save (Ctrl+o) and Close (Ctrl+x) the file

.
5.5 - Restart dump1090-fa

[abcd@archlinux ~]$ sudo systemctl restart dump1090-fa

5.6 - Clear browser cache (Ctrl+Shift+Delete) and Reload browser (Ctrl+F5) and see your SkyView map.

ENJOY !


#2

I have too an Core2Duo quad-cpu Q6600 doing nothing around. It would be an interesting exercise… even if in the end will take too much power to run.


#3
  1. The installation of dump1090-fa is easy if you use script I have posted above.

    I had real problem in integration of SkyView map with lighttpd. Whatever I try, lighttpd wont serve the SkyView. Instead it served only its page in document.root directory, although I have included following files in lighttpd.conf:

    88-dump1090-fa-statcache.conf
    89-dump1090-fa.conf

    It took me 3 days to finally discover that unlike Debian flavour of lighttpd, the Arch flavour of lighttpd does NOT have the module “mod_alias” enabled by default. Adding following line in file /etc/lighttpd/lighttpd.conf did the magic:

    server.modules += ( "mod_alias" )

  2. Installation of Arch Linux and AlarmPi distro itself is the harder part. The live .iso is without auto install. For RPi, no burnable image for microSD card available. One has to create, format and mount linux partions manually, and then do all the configuration and settings manually. It is a good learning process, though very frustrating. It took me several failed attempts and several days to finally succeed in installing Arch Linux x64_86 on my desktop, and AlarmPi on microSD card of RPi.

  3. NEXT PROJECT (Not yet tried):
    How to install PIAWARE on Arch Linux / AlarmPi?


#4

I am happy that you took time figure out those :smiley: Like the lack of alias module above!


#5

The first post gave installation of dump1090-fa on Arch Linux “by hand”, i.e. no installation package was build, only the executeable binary was built, and the the script carried out configuration steps.

Now I have written script to build dump1090-fa installation package for Arch Linux. This is in the arch Linux’s standard format and consists of two script files PKGBUILD and install.install.

I intended to upload these to AUR (Arch User’s Repository), but this requires adding a public key for SSH. The site is very user-UNfriendly, and I am unable to add SSH public Key. I made innumerable number of tries, but always got this message:
The SSH public key is invalid.
Finally I got fed up, and uploaded my work on GitHub…very easy.

How to built dump1090-fa’s installation Package for Arch Linux and AlarmPi

git clone https://github.com/abcd567a/dump1090-fa-arch.git
cd dump1090-fa-arch
ls
install.install  PKGBUILD  README.md

makepkg -si

Last command above will build following package

dump1090-fa-latest-1-*.pkg.tar.xz
#here the * will be either  x86_64 or armh6 or armh7, depending on your Computer or RPi architecture

After building the package, it will also offer to install the pakage immediately [yes/no].
Alternatively you can install it later by command

sudo pacman -U dump1090-fa-latest-1-*.pkg.tar.xz  

README.md

#dump1090-fa (AUR) for Arch Linux

Enter cloned directory. It contains following two files
PKGBUILD
install.install

Give command “makepkg -si”

Above command will:

(1) Check for conflicts with existing other versions of dump1090
(2) Install dependencies rtl-sdr, lighttpd, and bladerf
(3) Will build package dump1090-fa-latest--.pkg.tar.xz
(4) Offer to install the above package[yes/no]

The above package can be install later also by following command:
cd dump1090-fa-arch
sudo pacman -U dump1090-fa-latest--.pkg.tar.xz

#=========================================================
T H I N G - TO - DO (AFTER INSTALLATION IS COMPLETED)
#=========================================================
To make SkyView Map show range rings, do following:

(1) Open file “dump1090-fa” for editing

sudo nano  /etc/default/dump1090-fa 

(2) In the opened file, go to following line:
RECEIVER_OPTIONS="–device-index 0 --gain -10 --ppm 0 --net-bo-port 30005"
In above line, add your latitude and longitude, so the line becomes like below:
RECEIVER_OPTIONS="–device-index 0 --gain -10 --lat xx.xxxx --lon yy.yyyy --ppm 0 --net-bo-port 30005"
NOTE: Repalce xx.xxxx and yy.yyyy by your actual latitude and Longitude

(3) Restart dump1090-fa

sudo systemctl restart dump1090-fa 

(4) Clear browser cache and reload browser