How many Raspberry Pis do you have and what are they used for?

Commissario
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
Over the last few years, I've become a bit addicted to Raspberry Pis, if I think of something to use one for, I have absolutely no hesitation in firing one up.

It occurred to me earlier today that I've now got rather a lot of them and I thought I'd work out exactly how many I have and what they're all doing.

I think this is the complete list.

  • Raspberry Pi Zero - Pihole
  • Raspberry Pi Zero - Amateur radio APRS gateway
  • Raspberry Pi Zero W - Christmas tree flashing lights
  • Raspberry Pi Zero W - Internet watchdog
  • Raspberry Pi Zero W - ADS-B relay server (hosting a live feed)
  • Raspberry Pi Zero W - Internet radio
  • Raspberry Pi Zero W - Amateur radio QRSS grabber using QrssPiG
  • Raspberry Pi Zero W - Pihole
  • Raspberry Pi 2 Model B - OpenVPN and ddclient for dynamic DNS updates
  • Raspberry Pi 2 Model B - Remote, running Teamviewer for access to CentOS server (this is the only Pi I've ever had to use the GUI on)
  • Raspberry Pi 3 Model B - UniFi controller
  • Raspberry Pi 3 Model B - Amateur radio DXSpider
  • Raspberry Pi 3 Model B - ADS-B receiver
  • Raspberry Pi 3 Model B - ADS-B receiver (soon to be retired in favour of the one below)
  • Raspberry Pi 3 Model B+ - ADS-B receiver
  • Raspberry Pi 3 Model B+ - Remote ADS-B receiver

How many Pis do you have and what are they doing?
 
Commissario
OP
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
Its utterly rubbish for pihole.
Oh you do talk garbage. I've got around fifty clients running through my two Piholes and they work absolutely perfectly. One is using a USB to ethernet adapter and the other is wireless. Nobody knows which one they're using, dns lookups are so small and quick that it's utterly irrelevant.
When I ping the wired one, the response is less than a millisecond and the wireless one is around 1.3-1.5ms.
 
Commissario
OP
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
what i am saying is the zero does not come with wired network connectivity which makes it a rubbish buy for a pihole box as you need to add a usb network adaptor.
And I'm disagreeing and offering evidence that you don't need to add a usb network adapter because it works perfectly well without one. Are you seriously saying you'd notice a difference in performance from wired to wireless of less than one millisecond?
I don't disagree that wired is generally better than wireless but to say "it's utterly rubbish for pihole" is inaccurate. It's such a light load and passes so little traffic that it doesn't matter a flying hotspur whether you use wired or wireless.
 
Commissario
OP
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
I sort of guessed it would be - You can still get the original Zero but I can't imagine they sell many of them nowadays. It will work perfectly well for you, you won't have any issues with it.

I would suggest that you install Raspbian Stretch rather than Buster though. They've provided a quick incremental patch for Pihole to work with Buster but they don't describe it as being fully compatible yet. Once it is, I'll reimage both mine to Buster.
 
Commissario
OP
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
If you're continually turning it off just by cutting the power, you're almost guaranteed to get SD card corruption at some point. They're a lot better than they used to be but it will happen at some point. Unless you can cleanly turn it off then I wouldn't bother about a Pi. As it happens, it is fairly easy to configure a switch via the GPIO pins that will send a shutdown command and if you're happy to fit one (and remember to use it) then yes, go for it. I don't know what you'd use it for though.
 
Commissario
OP
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
is there a way to sync the two instance of pi-hole so you only have to manage one white list/black list?
Not officially, no. I've seen it discussed in /r/pihole but there's no solution I've been happy with. I just make sure that if I add anything to one of mine, I add it to the other one as well.
 
Commissario
OP
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
I use the x86 version of Raspbian Stretch for my 'dev' Pihole, the one I test things on in a VM. It works really well but that's hardly surprising considering the resources behind it.
 
Commissario
OP
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
I'm using a bash script that calls rsync to keep the black/white lists in sync. I make changes to one particular instance and then within an hour the changes are live on the other instance. The script definitely has the potential to bugger things up but I know my way around Unixesque operating systems and should I manage to break both instances (unlikely as the sync is one way) then I can spin up a new instance in about 15 minutes.
Care to share?
 
Commissario
OP
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
Oh, as simple as that. I'll have a play.

For those who want help setting up an ssh key, it's pretty straightforward and this is how I do it:
Code:
ssh-keygen -t ed25519

Hit enter a couple of times to submit without a password.

Then
Code:
ssh-copy-id [email protected]

Where xxx.xxx.xxx.xxx is the IP of the Pi you're connecting to.

This will store the remote Pi password locally and then you can just ssh into it without having to enter a password.
 
Commissario
OP
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
There's risks to using this script. Firstly I've got it setup so that I'm logging into the secondary Pi-Hole box as root which isn't ideal. I could do the rsync to a different user and then use sudo to move files around but that's not ideal either.
Thanks for posting it.

From what I understood, by default there's no root password. Have you added one? Also, I seem to recall that root login is disabled as well, have you enabled it? Sorry for all the questions, I like to comprehend what I'm doing and why. Your script makes perfect sense, it's just this remote root connection I'm not sure about.
 
Commissario
OP
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
Correct, by default there isn't a password on the root user. Setting one is the same as setting a password for any other user. So you just need to do the following when logged in as pi or whatever user you normally use which is allowed to sudo:
Thanks - What you've described is largely what I'd already found but my sshd_config didn't have the line, even commented out so I've added it.

I then set a root password and tried to log in remotely to set up public/private keys but it wouldn't let me do that until I changed the without-password to yes.

Now when I run the script, it prompts me for a password three times which is what I'd expect from the three files it's copying.

Have I dropped a gonad here by setting a root password? Should I have left it unset and left sshd_config as it was? I suspect I should and that's why I should have been testing this with my Pihole VM rather than an actual Pihole.

It's not the end of the world if I have, I was going to rebuild them (one at a time) to Buster anyway.
 
Commissario
OP
Joined
16 Oct 2002
Posts
2,829
Location
In the radio shack
Which user did you run the ssh-keygen as?
Yup, that was it. I'd run it as pi, not as root. Now I've done that, it's sorted so thanks for the help. This is the sort of thing I should have noticed so it's frustrating not to have realised what was going on there.

I've added a couple of extra files so regex.list and adlists.list are copied as well and I may also add my hosts and 04-pihole-static-dhcp.conf files as well just to keep everything the same between the two boxes.

Then I'll just cron it to run once an hour. Sorted.
 
Back
Top Bottom