Unable to install Pi-hole dependency package

Have tried to repair and debug but to no avail, it still will not update. Can anyone see the issue in the below report? I have been google searching for possible fixes for hours and cannot find anything to repair the issue. Thank you for any assistance in this matter.

\[✓\] Building dependency package pihole-meta.deb
\[✗\] Installing Pi-hole dependency package
*Error: Unable to install Pi-hole dependency package.
\~$ sudo bash -x /opt/pihole/update.sh*

* *readonly ADMIN_INTERFACE_GIT_URL=https://github.com/pi-hole/web.git*
* *ADMIN_INTERFACE_GIT_URL=https://github.com/pi-hole/web.git*
* *readonly PI_HOLE_GIT_URL=https://github.com/pi-hole/pi-hole.git*
* *PI_HOLE_GIT_URL=https://github.com/pi-hole/pi-hole.git*
* *readonly PI_HOLE_FILES_DIR=/etc/.pihole*
* *PI_HOLE_FILES_DIR=/etc/.pihole*
* *SKIP_INSTALL=true*
* *CHECK_ONLY=false*
* *source '/etc/.pihole/automated install/basic-install.sh'
  ++ set -e
  ++ export PATH+=:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
  ++ PATH+=:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
  ++ trap abort INT QUIT TERM
  ++ : 0
  ++ : 1
  ++ : 255
  +++ cat
  ++ DNS_SERVERS='Google (ECS, DNSSEC);8.8.8.8;8.8.4.4;2001:4860:4860:0:0:0:0:8888                                                       ;2001:4860:4860:0:0:0:0:8844
  OpenDNS (ECS, DNSSEC);208.67.222.222;208.67.220.220;2620:119:35::35;2620:119:53:                                                       :53
  Level3;4.2.2.1;4.2.2.2;;
  Comodo;8.26.56.26;8.20.247.20;;
  Quad9 (filtered, DNSSEC);9.9.9.9;149.112.112.112;2620:fe::fe;2620:fe::9
  Quad9 (unfiltered, no DNSSEC);9.9.9.10;149.112.112.10;2620:fe::10;2620:fe::fe:10
  Quad9 (filtered, ECS, DNSSEC);9.9.9.11;149.112.112.11;2620:fe::11;2620:fe::fe:11
  Cloudflare (DNSSEC);1.1.1.1;1.0.0.1;2606:4700:4700::1111;2606:4700:4700::1001'
  +++ cat
  ++ DNS_SERVERS_IPV6_ONLY='Google (ECS, DNSSEC);2001:4860:4860:0:0:0:0:8888;2001:                                                       4860:4860:0:0:0:0:8844
  OpenDNS (ECS, DNSSEC);2620:119:35::35;2620:119:53::53
  Quad9 (filtered, DNSSEC);2620:fe::fe;2620:fe::9
  Quad9 (unfiltered, no DNSSEC);2620:fe::10;2620:fe::fe:10
  Quad9 (filtered, ECS, DNSSEC);2620:fe::11;2620:fe::fe:11
  Cloudflare (DNSSEC);2606:4700:4700::1111;2606:4700:4700::1001'
  ++ installLogLoc=/etc/pihole/install.log
  ++ coltable=/opt/pihole/COL_TABLE
  ++ webroot=/var/www/html
  ++ webInterfaceGitUrl=https://github.com/pi-hole/web.git
  ++ webInterfaceDir=/var/www/html/admin
  ++ piholeGitUrl=https://github.com/pi-hole/pi-hole.git
  ++ PI_HOLE_LOCAL_REPO=/etc/.pihole
  ++ PI_HOLE_FILES=(list piholeDebug piholeLogFlush setupLCD update version gravit                                                       y uninstall webpage)
  ++ PI_HOLE_INSTALL_DIR=/opt/pihole
  ++ PI_HOLE_CONFIG_DIR=/etc/pihole
  ++ PI_HOLE_BIN_DIR=/usr/local/bin
  ++ PI_HOLE_V6_CONFIG=/etc/pihole/pihole.toml
  ++ fresh_install=true
  ++ adlistFile=/etc/pihole/adlists.list
  ++ IPV4_ADDRESS=
  ++ IPV6_ADDRESS=
  ++ QUERY_LOGGING=
  ++ PRIVACY_LEVEL=
  ++ PIHOLE_INTERFACE=
  ++ V6_CONF_MIGRATION_DIR=/etc/pihole/migration_backup_v6
  ++ '\[' -z root '\]'
  ++ r=20
  ++ c=70
  ++ PIHOLE_META_VERSION_APT=0.7
  +++ cat
  ++ PIHOLE_META_PACKAGE_CONTROL_APT='Package: pihole-meta
  Version: 0.7
  Maintainer: Pi-hole team <adblock@pi-hole.net>
  Architecture: all
  Description: Pi-hole dependency meta package
  Depends: awk,bash-completion,binutils,ca-certificates,cron|cron-daemon,curl,dial                                                       og,bind9-dnsutils|dnsutils,dns-root-data,git,grep,iproute2,iputils-ping,jq,libca                                                       p2,libcap2-bin,logrotate,lshw,procps,psmisc,sudo,unzip
  Section: contrib/metapackages
  Priority: optional'
  +++ cat
  ++ PIHOLE_META_PACKAGE_CONTROL_RPM='Name: pihole-meta
  Version: 0.4
  Release: 1
  License: EUPL
  BuildArch: noarch
  Summary: Pi-hole dependency meta package
  Requires: bash-completion,bind-utils,binutils,ca-certificates,chkconfig,cronie,c                                                       url,dialog,findutils,gawk,git,grep,iproute,jq,libcap,logrotate,lshw,procps-ng,ps                                                       misc,sudo,unzip
  %description
  Pi-hole dependency meta package
  %prep
  %build
  %files
  %install
  %changelog*


* *Thu Dec 18 2025 Pi-hole Team - 0.4*


* *Add logrotate to the list of dependencies*


* *Mon Jul 14 2025 Pi-hole Team - 0.3*


* *Remove nmap-ncat from the list of dependencies*


* *Wed May 28 2025 Pi-hole Team - 0.2*


* *Add gawk to the list of dependencies*


* *Sun Sep 29 2024 Pi-hole Team - 0.1*


* *First version being packaged'
  ++ PIHOLE_META_VERSION_APK=0.3
  ++ PIHOLE_META_DEPS_APK=(bash bash-completion bind-tools binutils coreutils cron                                                       ie curl dialog gawk git grep iproute2-minimal iproute2-ss jq libcap logrotate ls                                                       cpu lshw ncurses procps-ng psmisc shadow sudo tzdata unzip)
  ++ repair=false
  ++ runUnattended=false
  ++ \[\[ -f /opt/pihole/COL_TABLE \]\]
  ++ source /opt/pihole/COL_TABLE*
  +++ '\[' -t 1 '\]'
  ++++ tput colors
  +++ '\[' 8 -ge 8 '\]'
  +++ COL_BOLD=''
  +++ COL_NC=''
  +++ COL_GRAY=''
  +++ COL_RED=''
  +++ COL_GREEN=''
  +++ COL_YELLOW=''
  +++ COL_BLUE=''
  +++ COL_PURPLE=''
  +++ COL_CYAN=''
  +++ TICK='\[✓\]'
  +++ CROSS='\[✗\]'
  +++ INFO='\[i\]'
  +++ QST='\[?\]'
  +++ OVER='\\r'
  ++ \[\[ true != true \]\]


* source /opt/pihole/COL_TABLE
  ++ '\[' -t 1 '\]'
  +++ tput colors
  ++ '\[' 8 -ge 8 '\]'
  ++ COL_BOLD=''
  ++ COL_NC=''
  ++ COL_GRAY=''
  ++ COL_RED=''
  ++ COL_GREEN=''
  ++ COL_YELLOW=''
  ++ COL_BLUE=''
  ++ COL_PURPLE=''
  ++ COL_CYAN=''
  ++ TICK='\[✓\]'
  ++ CROSS='\[✗\]'
  ++ INFO='\[i\]'
  ++ QST='\[?\]'
  ++ OVER='\\r'
* source /opt/pihole/utils.sh
  ++ getFTLConfigValue webserver.paths.webroot
  ++ pihole-FTL --config -q webserver.paths.webroot
  ++ cat
  ++ getFTLConfigValue webserver.paths.webhome
  ++ pihole-FTL --config -q webserver.paths.webhome
  ++ cat
* ADMIN_INTERFACE_DIR=/var/www/html/admin/
* readonly ADMIN_INTERFACE_DIR
* \[\[ '' == --\\c\\h\\e\\c\\k-\\o\\n\\l\\y \]\]
* main
* local 'basicError=\\n  Unable to complete update, please contact Pi-hole Suppor                                                       t'
* local core_update
* local web_update
* local FTL_update
* core_update=false
* web_update=false
* FTL_update=false
* package_manager_detect
* is_command apt-get
* local check_command=apt-get
* command -v apt-get
* PKG_MANAGER=apt-get
* UPDATE_PKG_CACHE='apt-get update'
* PKG_INSTALL='apt-get -qq --no-install-recommends install'
* PKG_REMOVE='apt-get -y remove --purge'
* build_dependency_package
* is_command apk
* local check_command=apk
* command -v apk
* rm -rf '/tmp/pihole-meta\_\*'
* local tempdir
  ++ mktemp -d /tmp/pihole-meta_XXXXX
* tempdir=/tmp/pihole-meta_G1zSa
* chmod 0755 /tmp/pihole-meta_G1zSa
* is_command apt-get
* local check_command=apt-get
* command -v apt-get
* pushd /tmp
* rm -f /tmp/pihole-meta.deb
* mkdir -p /tmp/pihole-meta_G1zSa/DEBIAN
* chmod 0755 /tmp/pihole-meta_G1zSa/DEBIAN
* touch /tmp/pihole-meta_G1zSa/DEBIAN/control
* echo 'Package: pihole-meta
  Version: 0.7
  Maintainer: Pi-hole team <adblock@pi-hole.net>
  Architecture: all
  Description: Pi-hole dependency meta package
  Depends: awk,bash-completion,binutils,ca-certificates,cron|cron-daemon,curl,dial                                                       og,bind9-dnsutils|dnsutils,dns-root-data,git,grep,iproute2,iputils-ping,jq,libca                                                       p2,libcap2-bin,logrotate,lshw,procps,psmisc,sudo,unzip
  Section: contrib/metapackages
  Priority: optional'
* local 'str=Building dependency package pihole-meta.deb'
* printf '  %b %s...' '\[i\]' 'Building dependency package pihole-meta.deb'
  \[i\] Building dependency package pihole-meta.deb...+ dpkg-deb --build --root-ow                                                       ner-group /tmp/pihole-meta_G1zSa pihole-meta.deb
* printf '%b  %b %s\\n' '\\r' '\[✓\]' 'Building dependency package pihole-meta.deb'
  \[✓\] Building dependency package pihole-meta.deb
* popd
* rm -rf /tmp/pihole-meta_G1zSa
* install_dependent_packages
* local 'str=Installing Pi-hole dependency package'
* printf '  %b %s...' '\[i\]' 'Installing Pi-hole dependency package'
  \[i\] Installing Pi-hole dependency package...+ is_command apt-get
* local check_command=apt-get
* command -v apt-get
* '\[' -f /tmp/pihole-meta.deb '\]'
* eval 'apt-get -qq --no-install-recommends install' /tmp/pihole-meta.deb
* printf '%b  %b %s\\n' '\\r' '\[✗\]' 'Installing Pi-hole dependency package'
  \[✗\] Installing Pi-hole dependency package
* printf '  %b Error: Unable to install Pi-hole dependency package.\\n' ''
  Error: Unable to install Pi-hole dependency package.

Which distribution and release are you running?

Try installing a couple of above dependency packages manually with below to see if it fails with an error?

sudo apt-get --no-install-recommends install bash-completion curl

I've run in to a glitch with Debian 11 that fails because git depends on perl and there are no valid candidates for perl anymore.

If OP is on Deb 11, then a check of apt policy perl would show if this ticket is related to that glitch.

Blast, I have Bookworm, Buster and even an old Stretch but no Bullseye to tinker.
Missing Perl is a serious one bc that is a "required" one:

$ apt list ~prequired
Listing... Done
[..]
perl-base/oldstable,now 5.36.0-7+deb12u3 amd64 [installed]

Bullseye is perl 5.32.1

But that package doesn't exist:

The URL is: http://security.debian.org/debian-security/pool/updates/main/p/perl/perl_5.32.1-4+deb11u5_amd64.deb

That's a 404.

The repo doesn't go beyond Deb 12

Linking Improve gravity.db schema by DL6ER · Pull Request #6575 · pi-hole/pi-hole · GitHub because Debian 11 is also a topic there

This file can be found on the archive.debian.org domain, but I'm not sure if this will work: http://archive.debian.org/debian/pool/main/p/perl/perl-base_5.32.1-4+deb11u3_amd64.deb

Is it possible to change the apt repos to use archive.debian.org?

Sure, you can set sources.list (or equivalent) to what ever repo you'd like. The problem would then be that deb11u3 will not satisfy deb11u5 as apt requests. apt will still get a 404 because it does not know to look for alternatives. And deb11u3 is missing the security patches that u4 and u5 applied.

I have once downloaded something for Ubuntu 20.04 or so in order to install it in Debian 13 because I simply needed it to continue : Would that work in this case too ?!

It may work.

But, if my understanding is correct, then Debian have decided to not update Deb 11 and so I would not consider it to be a safe distro version anymore.

If lucky.
Usually you get trapped in dependency forest :wink:

$ apt depends perl
perl
  PreDepends: dpkg (>= 1.17.17)
  Depends: perl-base (= 5.36.0-7+deb12u3)
  Depends: perl-modules-5.36 (>= 5.36.0-7+deb12u3)
  Depends: libperl5.36 (= 5.36.0-7+deb12u3)
$ apt depends perl-base
perl-base
  PreDepends: libc6 (>= 2.35)
  PreDepends: libcrypt1 (>= 1:4.1.0)
  PreDepends: dpkg (>= 1.17.17)

Etc.

You mean dependency hell... (Next door to DLL hell...)

It was this damn thing at the time : How install libssl1.1 on ubuntu 22.04 · GitHub

I needed it for the Ubiquiti UniFi Controller to be able to mix and match some stuff in order to get it working on a CPU that does not have certain instructions onboard...

It was quite the ride... LOL! :rofl:

Latest version of Mint

Get:1 http://archive.ubuntu.com/ubuntu noble-updates/main amd64 curl amd64 8.5.0                           -2ubuntu10.15 \[227 kB\]
Get:2 http://archive.ubuntu.com/ubuntu noble-updates/main amd64 libcurl4t64 amd6                           4 8.5.0-2ubuntu10.15 \[343 kB\]
Get:3 http://archive.ubuntu.com/ubuntu noble-updates/main amd64 libcurl3t64-gnut                           ls amd64 8.5.0-2ubuntu10.15 \[336 kB\]
Fetched 906 kB in 1s (1,767 kB/s)
(Reading database… 1074746 files and directories currently installed.)
Preparing to unpack …/curl_8.5.0-2ubuntu10.15_amd64.deb…
Unpacking curl (8.5.0-2ubuntu10.15) over (8.5.0-2ubuntu10.13)…
Preparing to unpack …/libcurl4t64_8.5.0-2ubuntu10.15_amd64.deb…
Unpacking libcurl4t64:amd64 (8.5.0-2ubuntu10.15) over (8.5.0-2ubuntu10.13)…
Preparing to unpack …/libcurl3t64-gnutls_8.5.0-2ubuntu10.15_amd64.deb…
Unpacking libcurl3t64-gnutls:amd64 (8.5.0-2ubuntu10.15) over (8.5.0-2ubuntu10.13                           )…
Setting up libcurl4t64:amd64 (8.5.0-2ubuntu10.15)…
Setting up crowdsec-firewall-bouncer-nftables (0.0.36)…
***Job for crowdsec-firewall-bouncer.service failed because the control process exited with error code.***
See "systemctl status crowdsec-firewall-bouncer.service" and "journalctl -xeu cr                           owdsec-firewall-bouncer.service" for details.

Error.......

That is an issue with the crowdsec firewall service and not with Pi-hole. We do not install when there is an underlying problem with the server's operating system.

The final line of the quote explains how to research further.

sudo systemctl status --full --no-pager crowdsec-firewall-bouncer.service

and
sudo journalctl -xeu crowdsec-firewall-bouncer.service

Thank you Dan. Problem solved.