Welcome! Log In Create A New Profile

Advanced

another toy: pi hole on orange pi zero

Posted by asterix 
another toy: pi hole on orange pi zero
November 08, 2018 02:36PM
bought a tiny SBC: orange pi zero a couple of years ago, @ about $10 including shipping at that time, but now is $15.73

https://www.aliexpress.com/item/New-Orange-Pi-Zero-H2-Quad-Core-Open-source-512MB-development-board-beyond-Raspberry-Pi/32761500374.html?spm=2114.search0104.3.1.45c17b82apKMgl&ws_ab_test=searchweb0_0,searchweb201602_3_10065_10068_10130_10547_319_317_10548_10696_5728811_453_10084_454_10083_10618_10139_10307_537_536_5733215_5733315_328_10059_10884_5731015_10887_5733115_100031_5733415_321_5730015_322_10103_5733612_5733515,searchweb201603_55,ppcSwitch_0&algo_expid=e7a2451d-c163-4afb-961b-57d4ac9100cf-0&algo_pvid=e7a2451d-c163-4afb-961b-57d4ac9100cf

didn't use it more than one year, this week installed debian from armbian.com, then put pi-hole on it, very easy, just one command.

curl -sSL https://install.pi-hole.net | bash


pi-hole also comes with dnsmasq, so you can use it for DNS caching. From web-gui, you can find which website/server your devices visit, and easily block them.

https://pi-hole.net/



Edited 5 time(s). Last edit at 11/09/2018 07:04PM by asterix.
Martin from Dortmund
Re: another toy: pi home on orange pi zero
November 09, 2018 08:48AM
I think you used "PI hole" and not "PI home"...

Nice tool to get rid of annoying advertising...
Since throughput for Pi hole is not very high, it might be possible to install it on my dockstar ...
Martin from Dortmund
Re: another toy: pi home on orange pi zero
November 09, 2018 08:56AM
Uhh,
Dockstar only has 128 MByte RAM, pi-hole requries more ....

https://docs.pi-hole.net/main/prerequesites/
Quote

Pi-hole is very lightweight, and does not require much processing power

~52MB of free space
512MB RAM
Re: another toy: pi home on orange pi zero
November 09, 2018 07:06PM
Martin from Dortmund Wrote:
-------------------------------------------------------
> I think you used "PI hole" and not "PI home"...
>
> Nice tool to get rid of annoying advertising...
> Since throughput for Pi hole is not very high, it
> might be possible to install it on my dockstar ...

Haha, sorry about my typo. actually I also consider to use my dockstar as pi-hole, but the hardware too weak.
Re: another toy: pi home on orange pi zero
November 09, 2018 07:10PM
Martin from Dortmund Wrote:
-------------------------------------------------------
> Uhh,
> Dockstar only has 128 MByte RAM, pi-hole requries
> more ....
>
> https://docs.pi-hole.net/main/prerequesites/
>
Quote

> Pi-hole is very lightweight, and does not require
> much processing power
>
> ~52MB of free space
> 512MB RAM
>
>

I had docstar, pogoplug, goflex home, but raspberry/orange pi can do much more, and more fun.
Re: another toy: pi home on orange pi zero
December 27, 2018 01:57PM
I just got pi-hole up and running on my Pogoplug Pro. It was not an easy task for me, but others might find it easier. Short summary is you run the standard install script, then manually re-install FTL from source, then restart some services and boom!

The Pogoplug Pro seems to handle running the latest version of pi-hole just fine. Uses about 19% of the available memory. I'm running shairport-sync, smb shares, forked-daapd, and now pi-hole and sitting around 65mb of ram usage.
Re: another toy: pi home on orange pi zero
January 02, 2019 08:34AM
any chance of a writeup.....?? then bodhi can include it in the wiki

cdlenfert Wrote:
-------------------------------------------------------
> I just got pi-hole up and running on my Pogoplug
> Pro. It was not an easy task for me, but others
> might find it easier. Short summary is you run the
> standard install script, then manually re-install
> FTL from source, then restart some services and
> boom!
>
> The Pogoplug Pro seems to handle running the
> latest version of pi-hole just fine. Uses about
> 19% of the available memory. I'm running
> shairport-sync, smb shares, forked-daapd, and now
> pi-hole and sitting around 65mb of ram usage.
Martin from Dortmund
Re: another toy: pi hole on orange pi zero
January 09, 2019 02:02AM
According to .... https://oldwiki.archive.openwrt.org/toh/cloudengines/pogoplugpro ... the pogoplug pro has only 128 MByte RAM.

And according to https://discourse.pi-hole.net/t/hardware-software-requirements/273 ....

Hardware

Pi-hole is very lightweight as it only handles DNS queries and returns a blank HTML file so it doesn’t need much processing power.

    ~52MB of free space
    512 MB RAM

Is it REALLY running without any problems with only 128 MB RAM?
What is running beneath Pi Hole on your Pogoplug Pro?
Re: another toy: pi hole on orange pi zero
January 09, 2019 03:40AM
I actually wrote up a quick guide on how to install the pi-hole software on a pogoplug a few days ago. You can find it here:

https://www.reddit.com/r/pihole/comments/abgrog/quick_pihole_install_guide_for/

Doing a basic install with the default block-lists on a pogoplug mobile (v4-a1-01) has it idling at roughly 50MB of RAM consumed according to htop. This is using bodhi's latest rootfs (debian stretch) with no other services running. That is to say beyond the services that are running on the base rootfs provided by bodhi.

I've included the write up here for convenience/posterity's sake:

Note: This is all done with sudo not as the root user. I had some weird issue where I tried doing the following as root and it ended up breaking the system in such a way that the only recourse was to format/install a new rootfs.

THE ISSUE:
When running the install script one liner:

Quote

curl -sSL https://install.pi-hole.net | bash

It fails at the enabling lighttpd service to start on reboot step and dumps back to the shell prompt.

Edit:
Upon further testing, this error only seems to happen when using systemd instead of init. On a fresh rootfs install this error will not happen and instead will fail with "DNS resolution is not available". This is fixed by installing a compatible pihole-FTL as described below. Fixing the systemd error requires a different solution of manually creating/enabling the pihole-FTL service inside of /etc/init.d/ and copying over the "pihole" script inside of /etc/.pihole to /usr/local/bin/. You will also need to install a compatible pihole-FTL binary as described below.

THE WORKAROUND:
Unfortunately, if you've already run the above curl command you'll need to start over with a fresh rootfs/debian install as no matter what I tried the install breaks in such a way that nothing I did would allow it to advance past "enabling lighttpd service" message. I'm sure there's a way to fix it but honestly it was just faster to reinstall the system.

Working from a fresh/updated install you'll want to download the pi-hole source code release v4.0, unzip it, and run the automated installer. This was the last version I can verify completes most of the way through. I have not tried others beyond the version of the script that is installed by the traditional installer, which ultimately fails:

Quote

wget https://github.com/pi-hole/pi-hole/archive/v4.0.zip
unzip v4.0.zip
cd pi-hole-4.0/automated\ install/
sudo ./basic-install.sh

The installer will now progress as normal. Setup your pi-hole as you normally do, however this installer will also fail as it downloads a non-compatible version of pihole-FTL that will not run on armel processors. It should fail at the restarting DNS step if memory serves.

Now we need to compile a compatible version of pihole-FTL, but before we can do that you need to compile a recent version of nettle. You can do so by running the following commands. You will need a swap file if your system is running < (or equal to) 128MB of RAM :

Quote

sudo apt install build-essential libgmp-dev m4
wget https://ftp.gnu.org/gnu/nettle/nettle-3.4.tar.gz
tar -xvzf nettle-3.4.tar.gz
cd nettle-3.4
./configure
make
sudo make install

Finally we can compile pihole-FTL. You will need a swap file if your system is running < (or equal to) 128MB of RAM :

Quote

git clone https://github.com/pi-hole/FTL.git
cd FTL
make
sudo make install

For those of you that don't want to bother with compiling pihole-FTL from source, I've taken the liberty of compiling it for you. Keep in mind you're trusting that I haven't messed with the binary in some nefarious way (i haven't) but for peace of mind, you really should be compiling from source. Below are the md5 and sha1 sums for the precompiled pihole-FTL binary:

MD5SUM: e21ecad7064389de2f2c4e7fef21226c
SHA1SUM: 6e69e9b1582e468bdb8599b5d2112a38416809c2

Quote

wget https://www.dropbox.com/s/tp57akun04pec13/pihole-FTL-v4.1.2.zip?dl=0
mv pihole-FTL-v4.1.2.zip?dl=0 pihole-FTL-v4.1.2.zip
unzip pihole-FTL-v4.1.2.zip
sudo install -m 0755 pihole-FTL /usr/bin
sudo /sbin/setcap CAP_NET_BIND_SERVICE,CAP_NET_RAW,CAP_NET_ADMIN+eip /usr/bin/pihole-FTL

After that reset your pihole password:
Quote

pihole -a -p

and restart the pihole service:

Quote

sudo service pihole-FTL restart

And finally update the blocklists via the webinterface to re-load blocklists. Running the gravity.sh script probably does the same thing I just found this way easier. If anyone finds any issues/errors I'll update the post. Hopefully this helps someone else!

EDIT: I have noticed some weird issue where the pihole-FTL service starts and then quickly crashes after a reboot. Restarting the service immediately after seems to work and is stable from then on. Until the next reboot.



Edited 4 time(s). Last edit at 03/14/2019 09:58PM by alexr.
Re: another toy: pi hole on orange pi zero
January 09, 2019 04:11AM
Thanks alexr for a really good writeup! I'll include it in the Wiki.

@cdlenfert, please do a writeup on Pogo Pro, too.

I think the Pi-hole official requirements is probably on a consevative side. The basic rootfs I've built for Kirkwood and OXNAS boxes are quite lean, so 128MB RAM on these boxes was proven to be enough to run Pi-hole.

-bodhi
===========================
Forum Wiki
bodhi's corner
Re: another toy: pi hole on orange pi zero
January 09, 2019 10:56AM
I created a how to post for the Pogoplug Pro. I've been running PiHole for over a week now with no issues. This installs version 4.1.1.

https://forum.doozan.com/read.php?2,76234
Author:

Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: