package dovecot-imapd 1:1.2.9-1ubuntu6.1 failed to install/upgrade: `hostname` not defined

Bug #640121 reported by Thecas
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
dovecot (Ubuntu)
Invalid
Medium
Unassigned

Bug Description

Also failed on dovecot pop3d 1:1.29-1ubuntu6.1 during upgrade from 8.04LTS to 10.04LTS

Dovecot was not in use on server - never configured or activated.

ProblemType: Package
DistroRelease: Ubuntu 10.04
Package: dovecot-imapd 1:1.2.9-1ubuntu6.1
ProcVersionSignature: Ubuntu 2.6.24-28.77-server
Uname: Linux 2.6.24-28-server i686
Architecture: i386
Date: Wed Sep 15 20:28:08 2010
ErrorMessage: dependency problems - leaving unconfigured
SourcePackage: dovecot
Title: package dovecot-imapd 1:1.2.9-1ubuntu6.1 failed to install/upgrade: dependency problems - leaving unconfigured

Revision history for this message
Thecas (dlowland) wrote :
Revision history for this message
Scott Moser (smoser) wrote :

I'm fairly sure that dpkgTerminalLog.txt shows that this is not a dependency issue, but rather failure of dovecot-common post-install script:

Setting up dovecot-common (1:1.2.9-1ubuntu6.1) ...
Installing new version of config file /etc/init.d/dovecot ...
Replacing config file /etc/dovecot/dovecot.conf with new version
Replacing config file /etc/dovecot/dovecot-ldap.conf with new version
Replacing config file /etc/dovecot/dovecot-sql.conf with new version
Creating generic self-signed certificate: /etc/ssl/certs/dovecot.pem
(replace with hand-crafted or authorized one if needed).
hostname: Name or service not known
dpkg: error processing dovecot-common (--configure):
 subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of dovecot-imapd:
 dovecot-imapd depends on dovecot-common (= 1:1.2.9-1ubuntu6.1); however:
  Package dovecot-common is not configured yet.

Revision history for this message
Scott Moser (smoser) wrote :

Its my guess that this install failed because of the following line in dovecot's post install:
    MAILNAME=`cat /etc/mailname 2> /dev/null || hostname -f`

as seen in the dpkg log, 'hostname` failed. Do you have any idea why that would have occurred ?

does running 'hostname' succeed for you now?

Changed in dovecot (Ubuntu):
importance: Undecided → Medium
status: New → Incomplete
Revision history for this message
Christopher (soft-kristal) wrote :

Having recurring problems with dovecot in 10.10. Here's the latest terminal output:

dpkg: error processing dovecot-common (--configure):
 Package is in a very bad inconsistent state - you should
 reinstall it before attempting configuration.
dpkg: dependency problems prevent configuration of dovecot-pop3d:
 dovecot-pop3d depends on dovecot-common (= 1:1.2.12-1ubuntu5); however:
  Version of dovecot-common on system is 1:1.2.12-1ubuntu4.
dpkg: error processing dovecot-pop3d (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of dovecot-imapd:
 dovecot-imapd depends on dovecot-common (= 1:1.2.12-1ubuntu5); however:
  Version of dovecot-common on system is 1:1.2.12-1ubuntu4.
dpkg: error processing dovecot-imapd (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 dovecot-common
 dovecot-pop3d
 dovecot-imapd

I've tried to re-install with update-manager, synaptics (also with fix broken packages) and the terminal. All attempts end with nothing happening, necessitating a reboot to clear dpkg.

Changed in dovecot (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
RevEggplant (rrclark) wrote :

I'm encountering this problem when running apt-get upgrade.

After the package dovecot-common 1:1.2.12-1ubuntu4 has its files replaced, I get a message stating that the ssl keys are already in place, and then the install freezes. I have to open another term, kill the running dpkg processes, run dpkg --configure -a to finish configuring the packages that managed to partially install, then invoke a separate apt-get install dovecot-imapd dovecot-common to get those to install properly, and then rerun apt-get upgrade to finish upgrading the remaining packages in the lot.

Running a separate apt-get install on specifically on the dovecot packages does not duplicate the error, only running apt-get upgrade seems to duplicate the problem.

Revision history for this message
C de-Avillez (hggdh2) wrote :

@(Christopher, RevEggplant): yours are not the same issue as in this bug.

Revision history for this message
RevEggplant (rrclark) wrote :

I'm betting it is as it seems to be the same point in the post install script for that package that I get the hang.

Revision history for this message
C de-Avillez (hggdh2) wrote :

@RevEggplant: please open a new bug using apport -- we need to see the apt's term.log to verify.

Bryce Harrington (bryce)
summary: package dovecot-imapd 1:1.2.9-1ubuntu6.1 failed to install/upgrade:
- dependency problems - leaving unconfigured
+ `hostname` not defined
Revision history for this message
Bryce Harrington (bryce) wrote :

It looks like when this bug was originally reported ten years ago, it was not diagnosed down to a cause, which makes it challenging to identify if this is fixed or still an issue. I'm going to close the bug report out as expired. If anyone is still seeing this issue, or a similar one, please file a new bug report (with current logs and config), and we'll re-investigate from there.

Changed in dovecot (Ubuntu):
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.