Are you seeking to upgrade Pi-hole to the latest version on your Ubuntu or Debian Server? This guide can help you.

The process of updating Pi-hole is a easy to implement.

Pi Hole is a network-wide ad blocker. Basically, it is a DNS sinkhole which protects your devices from unwanted content / ads, without installing any special client-side software.

Here at LinuxAPT, as part of our Server Management Services, we regularly help our Customers to Install Software on your CentOS Server.

In this context, we will look into how to update Pi-hole subsystems using the CLI.

How to update Pi-hole on Ubuntu or Debian Linux distros?

To begin, you need to update your system packages and operating system. 

For Debian/Ubuntu Linux server, you need to run the following apt-get and apt commands;

sudo apt-get update
sudo apt-get upgrade

Then, to effect changes made during the system update process, reboot the server with the following command;

sudo reboot

The process of Updating and Upgrading Pi-hole with an OpenVPN on Ubuntu/Debian Linux?

To update Pi-hole subsystems, first run the following command to check the version of pihole available on the server;

pihole version

This will display an output such as this;

Pi-hole version is v4.3.2 (Latest: v4.4)
AdminLTE version is v4.3.2 (Latest: v4.3.3)
FTL version is v4.3.1 (Latest: v4.3.1)

How to update Pi-hole on Debian and Ubuntu Server?

To do this run the following command;

pihole -up

Or you can execute the command;

pihole updatePihole

Expect to see the following output;

[i] Checking for updates...
  [i] Pi-hole Core: update available
  [i] Web Interface: update available
  [i] FTL: update available
  [i] Pi-hole core files out of date, updating local repo.
  [?] Check for existing repository in /etc/.pihole
  [?] Update repo in /etc/.pihole
  [i] If you had made any changes in '/etc/.pihole/', they have been stashed using 'git stash'
  [i] Pi-hole Web Admin files out of date, updating local repo.
  [?] Check for existing repository in /var/www/html/admin
  [?] Update repo in /var/www/html/admin
  [i] If you had made any changes in '/var/www/html/admin/', they have been stashed using 'git stash'
  [i] FTL out of date, it will be updated by the installer.
  [?] Root user check
         :cccclll:.      ..,,
          :ccccclll.   ;ooodc
           'ccll:;ll .oooodc
                 .. ','.
        .........  ....  .........
        ..........      ..........
        ..........      ..........
        .........  ....  .........
  [i] Existing PHP installation detected : PHP version 7.2.24-0ubuntu0.18.04.3
  [i] Performing unattended setup, no whiptail dialogs will be displayed
  [?] Disk space check
  [?] Update local cache of available packages
  [?] Checking apt-get for upgraded packages... up to date!
  [i] Installer Dependency checks...
  [?] Checking for apt-utils
  [?] Checking for dialog
  [?] Checking for debconf
  [?] Checking for dhcpcd5
  [?] Checking for git
  [?] Checking for iproute2
  [?] Checking for whiptail
  [i] Performing reconfiguration, skipping download of local repos
  [?] Resetting repository within /etc/.pihole...
  [?] Resetting repository within /var/www/html/admin...
  [i] Main Dependency checks...
  [?] Checking for cron
  [?] Checking for curl
  [?] Checking for dnsutils
  [?] Checking for iputils-ping
  [?] Checking for lsof
  [?] Checking for netcat
  [?] Checking for psmisc
  [?] Checking for sudo
  [?] Checking for unzip
  [?] Checking for wget
  [?] Checking for idn2
  [?] Checking for sqlite3
  [?] Checking for libcap2-bin
  [?] Checking for dns-root-data
  [?] Checking for resolvconf
  [?] Checking for libcap2
  [?] Checking for lighttpd
  [?] Checking for php7.2-common
  [?] Checking for php7.2-cgi
  [?] Checking for php7.2-sqlite3
  [?] Enabling lighttpd service to start on reboot...
  [?] Checking for user 'pihole'
  [i] FTL Checks...
  [?] Detected x86_64 architecture
  [i] Checking for existing FTL binary...
  [i] Latest FTL Binary already installed (v4.3.1). Confirming Checksum...
  [i] Checksum correct. No need to download!
  [?] Checking for user 'pihole'
  [?] Installing scripts from /etc/.pihole
  [i] Installing configs from /etc/.pihole...
  [i] Existing dnsmasq.conf found... it is not a Pi-hole file, leaving alone!
  [?] Copying 01-pihole.conf to /etc/dnsmasq.d/01-pihole.conf
  [i] Installing blocking page...
  [?] Creating directory for blocking page, and copying files
  [?] Backing up index.lighttpd.html
      No default index.lighttpd.html file found... not backing up
  [?] Installing sudoer file
  [?] Installing latest Cron script
  [?] Installing latest logrotate script
  [i] Backing up /etc/dnsmasq.conf to /etc/dnsmasq.conf.old
  [?] man pages installed and database updated
  [i] Testing if systemd-resolved is enabled
  [i] Systemd-resolved is not enabled
  [?] Restarting lighttpd service...
  [?] Enabling lighttpd service to start on reboot...
  [i] Restarting services...
  [?] Enabling pihole-FTL service to start on reboot...
  [?] Restarting pihole-FTL service...
  [?] Deleting existing list cache
  [i] Pi-hole blocking is enabled
  [i] Neutrino emissions detected...
  [?] Pulling blocklist source list into range
  [i] Target: raw.githubusercontent.com (hosts)
  [?] Status: Retrieval successful
  [i] Target: mirror1.malwaredomains.com (justdomains)
  [?] Status: Retrieval successful
  [i] Target: sysctl.org (hosts)
  [?] Status: Retrieval successful
  [i] Target: zeustracker.abuse.ch (blocklist.php?download=domainblocklist)
  [?] Status: Retrieval successful
  [i] Target: s3.amazonaws.com (simple_tracking.txt)
  [?] Status: Retrieval successful
  [i] Target: s3.amazonaws.com (simple_ad.txt)
  [?] Status: Retrieval successful
  [i] Target: hosts-file.net (ad_servers.txt)
  [?] Status: Retrieval successful
  [?] Consolidating blocklists
  [?] Extracting domains from blocklists
  [i] Number of domains being pulled in by gravity: 147565
  [?] Removing duplicate domains
  [i] Number of unique domains trapped in the Event Horizon: 125233
  [i] Nothing to whitelist!
  [i] Number of regex filters: 0
  [?] Parsing domains into hosts format
  [?] Cleaning up stray matter
  [?] Force-reloading DNS service
  [?] DNS service is running
  [?] Pi-hole blocking is Enabled
  [i] The install log is located at: /etc/pihole/install.log
Update Complete! 
  Current Pi-hole version is v4.4
  Current AdminLTE version is v4.3.3
  Current FTL version is v4.3.1

How to test the updated pi-hole version on Ubuntu?

After the update process, you can visit pi-hole admin web interface via its URL such as http://ip_address/admin/ to display an updated pi-hole screen and version info at the bottom of page.

To see the version information, run the command as shown below;

pihole -v

You will get an output such as;

Pi-hole version is v4.4 (Latest: v4.4)
AdminLTE version is v4.3.3 (Latest: v4.3.3)
FTL version is v4.3.1 (Latest: v4.3.1)

How to check pi-hole for updates?

To do this, run the following command;

pihole updatePihole --check-only

Need to install any Software on your CentOS, Ubuntu and Debian Server? We are available to help you today.


This guide will show you how to easily update and upgrade Pi-hole with an OpenVPN on Ubuntu/Debian Linux server.

More Linux Tutorials

We create Linux HowTos and Tutorials for Sys Admins. Visit us on IbmiMedia.com

Also for Tech related tips, Visit forum.outsourcepath.com or General Technical tips on www.outsourcepath.com