pihole-ads-catcher icon indicating copy to clipboard operation
pihole-ads-catcher copied to clipboard

ads-catcher does not install cleanly

Open sholl opened this issue 6 years ago • 7 comments

I tried to install V1.3.0 to my raspbian-image with the following error: Enable and start systemd service ... Failed to retrieve unit: No such method 'GetUnit' Failed to start ads-catcher.service: Unknown unit: ads-catcher.service See system logs and 'systemctl status ads-catcher.service' for details. ads-catcher.service couldn't start. dpkg: error processing package ads-catcher (--install): subprocess installed post-installation script returned error exit status 1 Processing triggers for man-db (2.7.6.1-2) ... Errors were encountered while processing: ads-catcher

Looking deeper into it I found that the service will not start.

root@raspberrypi:/etc/systemd/system# systemctl start ads-catcher.service Failed to start ads-catcher.service: Unknown unit: ads-catcher.service See system logs and 'systemctl status ads-catcher.service' for details. root@raspberrypi:/etc/systemd/system# systemctl status ads-catcher.service Failed to get properties: No such interface ''

Uninstalling does not work as well: root@raspberrypi:/etc/systemd/system# dpkg -r ads-catcher
(Reading database ... 99335 files and directories currently installed.)
Removing ads-catcher (1.3.0) ...
Stop and disable systemd service ...
Failed to stop ads-catcher.service: Unknown unit: ads-catcher.service
See system logs and 'systemctl status ads-catcher.service' for details.
Failed to get load state of ads-catcher.service: No such property 'LoadState'
dpkg: error processing package ads-catcher (--remove):
subprocess installed pre-removal script returned error exit status 1
Parse pi-hole logfile ...
[Sat Apr 13 19:35:45 CEST 2019] ads-catcher-blacklister
Parsing all logfiles ...
[i] r1---sn-4g5e6nez.googlevideo.com already exists in blacklist, no need to add! .... Enable and start systemd service ...
Failed to retrieve unit: No such method 'GetUnit'
Failed to start ads-catcher.service: Unknown unit: ads-catcher.service
See system logs and 'systemctl status ads-catcher.service' for details.
ads-catcher.service couldn't start.
dpkg: error while cleaning up:
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
ads-catcher

Do you have any hints

sholl avatar Apr 18 '19 20:04 sholl

Could you launch these commands and post output please : $ cat /etc/os-release $ systemctl --version

To uninstall package, you can use : $ sudo dpkg --purge --force-all ads-catcher

pebdev avatar Apr 18 '19 22:04 pebdev

Sure thing: $ cat /etc/os-release PRETTY_NAME="Raspbian GNU/Linux 9 (stretch)" NAME="Raspbian GNU/Linux" VERSION_ID="9" VERSION="9 (stretch)" ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"

$ systemctl --version systemd 232 +PAM +AUDIT +SELINUX +IMA +APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ +LZ4 +SECCOMP +BLKID +ELFUTILS +KMOD +IDN

Your Hint for uninstalling the package did not cleanly remove the package: Failed to retrieve unit: No such method 'GetUnit' Failed to start ads-catcher.service: Unknown unit: ads-catcher.service See system logs and 'systemctl status ads-catcher.service' for details. ads-catcher.service couldn't start. dpkg: error while cleaning up: subprocess installed post-installation script returned error exit status 1 Errors were encountered while processing: ads-catcher

sholl avatar Apr 18 '19 23:04 sholl

It's strange, I have exactly the same setup.

If it's possible can you update your OS ?

sudo apt-get update
sudo apt-get upgrade
sudo apt-get dist-upgrade

If you have always this issue, maybe try to reinstall systemd :

sudo apt-get install --reinstall systemd

pebdev avatar Apr 20 '19 22:04 pebdev

Mhh, strange. I think I know what is up here. Systemd is not the default, I am (still) running sysvinit on this maschine.

It's strange, I have exactly the same setup.

If it's possible can you update your OS ?

sudo apt-get update
sudo apt-get upgrade
sudo apt-get dist-upgrade

This is all up to date.

If you have always this issue, maybe try to reinstall systemd :

sudo apt-get install --reinstall systemd

I don´t want to install systemd since the sysvinit on this pi is running stable though. Are you willing to support sysvinit as well as systemd?

sholl avatar Apr 23 '19 06:04 sholl

Any way to run it on docker pi-hole ?

ufo56 avatar Apr 23 '19 18:04 ufo56

Mhh, strange. I think I know what is up here. Systemd is not the default, I am (still) running sysvinit on this maschine.

It's strange, I have exactly the same setup. If it's possible can you update your OS ?

sudo apt-get update
sudo apt-get upgrade
sudo apt-get dist-upgrade

This is all up to date.

If you have always this issue, maybe try to reinstall systemd :

sudo apt-get install --reinstall systemd

I don´t want to install systemd since the sysvinit on this pi is running stable though. Are you willing to support sysvinit as well as systemd?

Ok, I understand :) I'll add sysvinit support in the next release.

pebdev avatar Apr 24 '19 18:04 pebdev

cool, thank you. Drop me a line if it is on github and I am willing to beta-test :-)

sholl avatar Apr 25 '19 11:04 sholl