FlightAware Discussions

Issue with updating to 3.8.0

I’m running an rtlsdr_v3 with bias tee. the issues began with the build of bias tee software.

I scoured the internet… you’ll see commands I used in the screenshot to make things work.

I eventually want to put graphs back in and the rpi-monitor software.

This is the 3.8.0 sdcard image

Might be a systemd issue on debian buster. (did some googling)
I mean it tells you what to do, so it’s not that bad?

(1) The command you used contains duplicate commands, and unnecessary part && cd src. This duplication as well as extra part are causing warnings and failure.

(2) The daemon reload command you used is daemon_reload, while correct word is daemon-reload

This is the command you used:

sudo service dump1090-fa stop && cd ~/rtl_biast/build/src && ./rtl_biast -b 1 && cd src && sudo service dump1090-fa stop && ./rtl_biast -b 1 && sudo service dump1090-fa start

.
Copy-paste this command:

sudo service dump1090-fa stop && cd ~/rtl_biast/build/src && ./rtl_biast -b 1 && sudo service dump1090-fa start

You didn’t describe the issue that you had. Please describe the problem you’re trying to solve.

PiAware will not start on its own. Since I have the bias tee, the first thing I needed to do was enable it so my Pi was tracking more than a few miles…

I was trying to follow the guides and I suspected that the issues had to do with the new features/kernel.

I did find one site who suggested that there was ‘tv’ drivers - for when you wanna do TV with these… it’d surprise me that the sdcard build would even have it. I ran their suggested command anyway - which was a few drivers… and the tuner fired right up.

I suspected that it wouldn’t remain that way after a reboot and I was correct. This time around, the remove driver command didn’t affect the system.

I am unable to figure out what is causing this behavior. I haven’t went far into diagnosing… i’d guess looking at htop would tell me if something else was trying to use the dongle first.

I have a rather high volume that runs through my pi… so downtime negatively affects all the cool stats that motivate me to do this! I’m site 97097…

Have you seen this guide:

https://www.rtl-sdr.com/getting-the-v3-bias-tee-to-activate-on-piaware-ads-b-images/

Before using the above guide, blacklist the kernel drivers like this:

echo -e 'blacklist rtl2832\nblacklist dvb_usb_rtl28xxu\nblacklist rtl8192cu\nblacklist rtl8xxxu\n' | sudo tee /etc/modprobe.d/blacklist-rtl-sdr2.conf

edit: fixed command line

The command sudo systemctl daemon-reload should only be required once after modifying the bias-t.conf, a reboot should also help.
Anyhow that particular warning shouldn’t be an issue.

2 Likes

By above sentence, do you mean when you reboot Pi:

  • The piaware data feeder does not start automatically
    OR
  • The dump1090-fa does not start automatically

.
What these commands show after reboot

sudo systemctl status dump1090-fa
sudo systemctl status piaware

.

This is what I get after reboot:
(Please ignore the warning. It is harmless)

Linux piaware 4.19.75-v7+ #1270 SMP Tue Sep 24 18:45:11 BST 2019 armv7l

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Sat Jan 18 15:08:26 2020 from 10.0.0.32
pi@piaware:~ $ sudo systemctl status dump1090-fa
Warning: The unit file, source configuration file or drop-ins of dump1090-fa.service changed on disk. Run 'system● dump1090-fa.service - dump1090 ADS-B receiver (FlightAware customization)
Loaded: loaded (/lib/systemd/system/dump1090-fa.service; enabled; vendor preset: enabled)
Drop-In: /etc/systemd/system/dump1090-fa.service.d
└─bias-t.conf
Active: activating (auto-restart) (Result: exit-code) since Sat 2020-01-18 20:41:37 UTC; 27s ago
Docs: https://flightaware.com/adsb/piaware/
Process: 481 ExecStartPre=/home/pi/rtl_biast/build/src/rtl_biast -b 1 (code=exited, status=6)

Jan 18 20:41:37 piaware systemd[1]: dump1090-fa.service: Failed with result ‘exit-code’.
Jan 18 20:41:37 piaware systemd[1]: Failed to start dump1090 ADS-B receiver (FlightAware customization).

pi@piaware:~ $ sudo systemctl status piaware
● piaware.service - FlightAware ADS-B uploader
Loaded: loaded (/lib/systemd/system/piaware.service; enabled; vendor preset: enabled)
Active: active (running) since Sat 2020-01-18 20:41:37 UTC; 1min 11s ago
Docs: https://flightaware.com/adsb/piaware/
Main PID: 495 (piaware)
Tasks: 2 (limit: 2200)
Memory: 8.5M
CGroup: /system.slice/piaware.service
└─495 /usr/bin/piaware -p /run/piaware/piaware.pid -plainlog -statusfile /run/piaware/status.json

Jan 18 20:41:41 piaware piaware[495]: UAT support disabled by local configuration setting: uat-receiver-type
Jan 18 20:42:12 piaware piaware[495]: 0 msgs recv’d from dump1090; 0 msgs sent to FlightAware
Jan 18 20:42:40 piaware sudo[672]: piaware : TTY=unknown ; PWD=/ ; USER=root ; COMMAND=/usr/bin/netstat --program --tcp --wide --all --numeric
Jan 18 20:42:40 piaware sudo[672]: pam_unix(sudo:session): session opened for user root by (uid=0)
Jan 18 20:42:40 piaware sudo[672]: pam_unix(sudo:session): session closed for user root
Jan 18 20:42:40 piaware piaware[495]: no ADS-B data program is serving on port 30005, not starting multilateration client yet
Jan 18 20:42:41 piaware sudo[681]: piaware : TTY=unknown ; PWD=/ ; USER=root ; COMMAND=/usr/bin/netstat --program --tcp --wide --all --numeric
Jan 18 20:42:41 piaware sudo[681]: pam_unix(sudo:session): session opened for user root by (uid=0)
Jan 18 20:42:41 piaware sudo[681]: pam_unix(sudo:session): session closed for user root
Jan 18 20:42:41 piaware piaware[495]: no ADS-B data program seen listening on port 30005 for 64 seconds, next check in 60s
pi@piaware:~ $ sudo systemctl status dump1090-fa
Warning: The unit file, source configuration file or drop-ins of dump1090-fa.service changed on disk. Run ‘systemctl daemon-reload’ to reload units.
● dump1090-fa.service - dump1090 ADS-B receiver (FlightAware customization)
Loaded: loaded (/lib/systemd/system/dump1090-fa.service; enabled; vendor preset: enabled)
Drop-In: /etc/systemd/system/dump1090-fa.service.d
└─bias-t.conf
Active: activating (auto-restart) (Result: exit-code) since Sat 2020-01-18 20:42:46 UTC; 26s ago
Docs: https://flightaware.com/adsb/piaware/
Process: 693 ExecStartPre=/home/pi/rtl_biast/build/src/rtl_biast -b 1 (code=exited, status=6)

Blockquote

dump1090-fa isn’t starting.

I ran wiedehopf’s blacklist code as well. That guide is where I started.

You reboot after blacklisting?

Please also show the output for:

cat /etc/systemd/system/dump1090-fa.service.d/bias-t.conf

Yes.

pi@piaware:~ $ sudo service dump1090-fa stop && cd ~/rtl_biast/build/src && ./rtl_biast -b 1 && sudo service dump1090-fa start
Warning: The unit file, source configuration file or drop-ins of dump1090-fa.service changed on disk. Run ‘systemctl daemon-reload’ to reload units.
Found 1 device(s):
0: Realtek, RTL2838UHIDIR, SN: 00001090

Using device 0: Generic RTL2832U OEM

Kernel driver is active, or device is claimed by second instance of librtlsdr.
In the first case, please either detach or blacklist the kernel module
(dvb_usb_rtl28xxu), or enable automatic detaching at compile time.

usb_claim_interface error -6
pi@piaware:~/rtl_biast/build/src sudo systemctl daemon-reload pi@piaware:~/rtl_biast/build/src sudo rmmod dvb_usb_rtl28xxu rtl2832
pi@piaware:~/rtl_biast/build/src **sudo systemctl daemon-reload** pi@piaware:~/rtl_biast/build/src sudo service dump1090-fa stop && cd ~/rtl_biast/build/src && ./rtl_biast -b 1 && sudo service dump1090-fa start
Found 1 device(s):
0: Realtek, RTL2838UHIDIR, SN: 00001090

Using device 0: Generic RTL2832U OEM
Found Rafael Micro R820T tuner
pi@piaware:~/rtl_biast/build/src $ sudo systemctl status dump1090-fa
● dump1090-fa.service - dump1090 ADS-B receiver (FlightAware customization)
Loaded: loaded (/lib/systemd/system/dump1090-fa.service; enabled; vendor preset: enabled)
Drop-In: /etc/systemd/system/dump1090-fa.service.d
└─bias-t.conf
Active: active (running) since Sat 2020-01-18 20:48:12 UTC; 10s ago
Docs: https://flightaware.com/adsb/piaware/
Process: 1139 ExecStartPre=/home/pi/rtl_biast/build/src/rtl_biast -b 1 (code=exited, status=0/SUCCESS)
Main PID: 1145 (dump1090-fa)
Tasks: 3 (limit: 2200)
Memory: 5.3M
CGroup: /system.slice/dump1090-fa.service
└─1145 /usr/bin/dump1090-fa --device-index 00001090 --gain 39 --ppm 0 --max-range 360 --fix --net --net-heartbeat 60 --net-ro-size 1300 --net-ro-interval 0.2 --net-http-port 0 --net-ri-por

Jan 18 20:48:10 piaware dump1090-fa[1139]: Found 1 device(s):
Jan 18 20:48:10 piaware dump1090-fa[1139]: 0: Realtek, RTL2838UHIDIR, SN: 00001090
Jan 18 20:48:10 piaware dump1090-fa[1139]: Using device 0: Generic RTL2832U OEM
Jan 18 20:48:11 piaware dump1090-fa[1139]: Found Rafael Micro R820T tuner
Jan 18 20:48:12 piaware systemd[1]: Started dump1090 ADS-B receiver (FlightAware customization).
Jan 18 20:48:12 piaware dump1090-fa[1145]: Sat Jan 18 20:48:12 2020 UTC dump1090-fa 3.8.0 starting up.
Jan 18 20:48:12 piaware dump1090-fa[1145]: rtlsdr: using device #0: Generic RTL2832U OEM (Realtek, RTL2838UHIDIR, SN 00001090)
Jan 18 20:48:12 piaware dump1090-fa[1145]: Found Rafael Micro R820T tuner
Jan 18 20:48:12 piaware dump1090-fa[1145]: rtlsdr: tuner gain set to 38.6 dB
Jan 18 20:48:13 piaware dump1090-fa[1145]: Allocating 4 zero-copy buffers

pi@piaware:~/rtl_biast/build/src $

This is what I had to do to make it work.

[Service]
ExecStartPre=/home/pi/rtl_biast/build/src/rtl_biast -b 1

bias-t.conf

Well that means the blacklisting didn’t work, maybe the copy paste wasn’t quite complete.

Anyhow, you can also change the compilation options:
Instead of this line:

cmake ..

Use this line:

cmake .. -DINSTALL_UDEV_RULES=ON -DDETACH_KERNEL_DRIVER=ON

But blacklisting as i posted should work as well.
I’ve posted a comment to change that guide, but they have not seen it.

I made a mistake, the f was missing from conf at the end :slight_smile:
Corrected command line:

echo -e 'blacklist rtl2832\nblacklist dvb_usb_rtl28xxu\nblacklist rtl8192cu\nblacklist rtl8xxxu\n' | sudo tee /etc/modprobe.d/blacklist-rtl-sdr2.conf
sudo rm /etc/modprobe.d/blacklist-rtl-sdr2.con
sudo reboot

This should work and get rid of the old file.

Worked. Thanks wiedehopf

3 Likes

Glad to know your problem is solved by black-listing the rtl modules.

The warning to use above command keeps on appearing every time dump1090-fa is started or Pi is rebooted. Just ignore the warning. it is harmless.

.

The warning is caused by following step:

sudo mkdir /etc/systemd/system/dump1090-fa.service.d
sudo nano /etc/systemd/system/dump1090-fa.service.d/bias-t.conf

Then paste in the following

[Service]
ExecStartPre=/home/pi/rtl_biast/build/src/rtl_biast -b 1

.

This warning can be eliminated if instead of carrying out above procedure, the line

ExecStartPre=/home/pi/rtl_biast/build/src/rtl_biast -b 1

is added to file

/usr/lib/systemd/system/dump1090-fa.service

just above the line starting with ExecStart=

then reboot the Pi or issue following command (only once is enough)

sudo systemctl daemon-reload

CAUTION: Dont modify file dump1090-fa.service unless you fully understand what are you doing.

note that the blacklist is not necessary if you build librtlsdr the sensible way and enable detatching the kernel driver (this is what the standard debian/raspbian build does). So the actual cause here was that librtlsdr was rebuilt with the wrong options.

The sensible way is
cmake .. -DINSTALL_UDEV_RULES=ON -DDETACH_KERNEL_DRIVER=ON

Unfortunately the RTL-SDR Blog guide does not tell to build the sensible way.
This is what it tells:

cd ~
git clone https://github.com/rtlsdrblog/rtl_biast
cd rtl_biast
mkdir build
cd build
cmake ..
make

On a similar note, when installing dump1090-fa or dump978-fa standalone, they are missing the proper UDEV rules i believe.
So if you install it on a standard Raspbian, it will not work if i’m not mistaken.