Errors reinstalling Nagios

Hi, some months ago I’ve unistalled nagios.
Now I want to reinstall it, but univention-install nagios ----> few errors:

Not replacing deleted config file /etc/nagios/apache2.conf
enabling Apache2 config...
ERROR: Conf nagios3 does not exist!
apache2_invoke cgi: already enabled
dpkg: errore nell'elaborare il pacchetto nagios-cgi (--configure):
dpkg: errore nell'elaborare il pacchetto nagios (--configure):
 dependences problems
Traceback (most recent call last):
  File "/usr/sbin/univention-pkgdb-scan", line 37, in <module>
    univention.pkgdb.main()
  File "/usr/lib/python2.7/dist-packages/univention/pkgdb.py", line 579, in main
    connection = open_database_connection(config_registry, pkgdbu=False)
  File "/usr/lib/python2.7/dist-packages/univention/pkgdb.py", line 561, in open_database_connection
    connection = pgdb.connect(database=connectstring)
  File "/usr/lib/python2.7/dist-packages/pgdb.py", line 1615, in connect
    cnx = _connect(dbname, dbhost, dbport, dbopt, dbuser, dbpasswd)
pg.InternalError: FATALE:  authentication failed user "DChostname$"

How can I fix its?
Thank you
Regards

There isn’t “DChostname$” user (ucs-master)

I’ve add by: `univention-pkgdb-scan --db-server ‘ucs-master.domain.com’ --add 'ucs-master`` ?
My DC master version is 4.4.7, but Software monitor write: 4.4-3 errata456
Software monitor write slave are 4.4-3 errata456 but now are 4.4-7 errata873

andreaussi,

The issue is you never purged the old install, so you have legacy artifacts still around preventing the reinstall.

Try this:

apt-get remove nagios*
apt-get autoremove
dpkg -l | awk ‘/^rc/ { print $2 }’ | xargs -r dpkg --purge

Hope this helps.

Mastodon