Subprocess installed post-installation script returned errors for installing/removing Cacti

Ryahn picture Ryahn · Jan 4, 2014 · Viewed 7.7k times · Source

I have been trying to get cacti installed on my server. I have tried for some support at their forums and coming here due to little to no support. I am trying to install from scratch for cacti but keep running into errors, here are the following ones I get. I am asking what I may doing wrong or what have missed?

Removal

root@erebus:~# apt-get --purge remove cacti cacti-spine
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
  rrdtool libdbi1 librrd4 php5-snmp snmp libphp-adodb
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
  cacti* cacti-spine*
0 upgraded, 0 newly installed, 2 to remove and 88 not upgraded.
1 not fully installed or removed.
After this operation, 4,766 kB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 63908 files and directories currently installed.)
Removing cacti ...
dpkg: error processing cacti (--purge):
 subprocess installed pre-removal script returned error exit status 10
dbconfig-common: flushing administrative password
dpkg: error while cleaning up:
 subprocess installed post-installation script returned error exit status 10
Removing cacti-spine ...
Purging configuration files for cacti-spine ...
Errors were encountered while processing:
 cacti
E: Sub-process /usr/bin/dpkg returned an error code (1)

Install of prerequisites

root@erebus:~# apt-get install snmpd
Reading package lists... Done
Building dependency tree
Reading state information... Done
snmpd is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 88 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue [Y/n]? y
Setting up cacti (0.8.7i-2ubuntu1) ...
dbconfig-common: writing config to /etc/dbconfig-common/cacti.conf
Replacing config file /etc/cacti/debian.php with new version
dpkg: error processing cacti (--configure):
 subprocess installed post-installation script returned error exit status 10
Errors were encountered while processing:
 cacti
[master 4c76eb7] committing changes in /etc after apt run
 Author: ryahn <ryahn@erebus>
 2 files changed, 1 insertion(+), 3 deletions(-)
E: Sub-process /usr/bin/dpkg returned an error code (1)

Answer

bangolio picture bangolio · Jan 5, 2014

Doesn't seem like a Cacti issue, more like a case of a broken package or a bad install, try this: http://forums.debian.net/viewtopic.php?f=10&t=82861