Upgrade from Lucid Server to Precise: resolvconf 1.63ubuntu3 failed to install with "cp: cannot create regular file `/run/resolvconf/resolv.conf': No such file or directory"

Bug #922491 reported by Jean-Baptiste Lallement
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
resolvconf (Ubuntu)
Fix Released
High
Steve Langasek
Precise
Fix Released
High
Steve Langasek

Bug Description

Automated Lucid Server upgrade to Precise
https://jenkins.qa.ubuntu.com/view/Precise%20Upgrade%20Testing%20Dashboard/job/precise-upgrade-lucid-server/

From apt-term.log, resolvconf failed to upgrade:
Setting up resolvconf (1.63ubuntu3) ...
cp: cannot create regular file `/run/resolvconf/resolv.conf': No such file or directory
dpkg: error processing resolvconf (--configure):
 subprocess installed post-installation script returned error exit status 1

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: resolvconf (not installed)
ProcVersionSignature: Ubuntu 3.2.0-10.18-generic 3.2.1
Uname: Linux 3.2.0-10-generic x86_64
ApportVersion: 1.91-0ubuntu1
Architecture: amd64
Date: Fri Jan 27 10:38:48 2012
EcryptfsInUse: Yes
InstallationMedia: Ubuntu 11.10 "Oneiric Ocelot" - Release amd64 (20111012)
ProcEnviron:
 PATH=(custom, user)
 LANG=en_US.utf8
 SHELL=/bin/bash
SourcePackage: resolvconf
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :
tags: added: dist-upgrade lucid2precise qa-daily-testing
Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :
Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :
Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :
Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :
tags: added: rls-mgr-p-tracking
Changed in resolvconf (Ubuntu Precise):
importance: Undecided → High
Colin Watson (cjwatson)
Changed in resolvconf (Ubuntu Precise):
assignee: nobody → Steve Langasek (vorlon)
summary: - lucid to precise server upgrade: resolvconf failed to upgradecp: cannot
+ lucid to precise server upgrade: resolvconf failed to upgrade: cp cannot
create regular file `/run/resolvconf/resolv.conf': No such file or
- directory:
+ directory
Revision history for this message
Launchpad Janitor (janitor) wrote : Re: lucid to precise server upgrade: resolvconf failed to upgrade: cp cannot create regular file `/run/resolvconf/resolv.conf': No such file or directory

This bug was fixed in the package resolvconf - 1.63ubuntu6

---------------
resolvconf (1.63ubuntu6) precise; urgency=low

  * Pre-Depend on the /run-providing version of initscripts instead of
    depending, so that the preinst does the right thing when creating
    /run/resolvconf/interfaces instead of getting clobbered later by a bind
    mount on initscripts upgrade. LP: #922491.
  * Completely drop the standard_run_subdirs_created helper function from
    debian/postinst, since it serves no purpose here.
 -- Steve Langasek <email address hidden> Fri, 27 Jan 2012 14:14:53 -0800

Changed in resolvconf (Ubuntu Precise):
status: New → Fix Released
Revision history for this message
Sebastian Unger (sebunger44) wrote :

I'm not sure whether this is related to this or not. I was about to raise a bug for it, but thought I'd comment here in case it is related to something someone did recently in regards to this bug. Here's my scenario:

I'm using oneiric-mini.iso to install from a local ubuntu mirror (more like a cache) that is constructed using reprepro. In essence it's a mirror of only the important bits of oneiric to set up an ubuntu-standard server + resolvconf from precise since the one in oneiric is totally broken.

Until very recently (1.63ubuntu3) this installed just fine (using DHCP for the single interface and getting the DNS info from that). Now I've just updated my "mirror" to the latest packages which pulled in resolvconf 1.63ubuntu6 from precise and now this no longer installs properly. In particular /etc/resolv.conf is still a file and not a sym-link after a clean expert install.

If I subsequently try to fix thinks by running dpkg-reconfigure resolvconf, it goes through a couple questions (Yes, I want to prepare /etc/resolv.conf and no I don't want to append the original contents) it fails saying (in effect) that /run/resolvconf does not exist. If I create /run/resolvconf and /run/resolvconf/interface manually and then run through dpkg-reconfigure it appears to start coming right.

I don't have the means to try this on a plain precise install at the moment.

Anybody any comments?

Seb

Revision history for this message
Thomas Hood (jdthood) wrote :

Seb: I think that you've hit #929552. I have copied your comment over there.

Thomas Hood (jdthood)
summary: - lucid to precise server upgrade: resolvconf failed to upgrade: cp cannot
- create regular file `/run/resolvconf/resolv.conf': No such file or
- directory
+ Upgrade from Lucid Server to Precise: resolvconf 1.63ubuntu3 failed to
+ install with "cp: cannot create regular file
+ `/run/resolvconf/resolv.conf': No such file or directory"
Revision history for this message
Thomas Hood (jdthood) wrote :

(Just checking that the bug reported here was really closed by the addition of the Pre-Depends on the new initscripts.

The answer is Yes. In apt-term.log we find the following order of events.

Unpacking resolvconf (from .../resolvconf_1.63ubuntu3_all.deb) ...
[...]
Setting up initscripts (2.88dsf-13.10ubuntu8) ...
)

Revision history for this message
Thomas Hood (jdthood) wrote :

Sebastian Unger: Am I correct in assuming that in addition to the Precise version of resolvconf you also install the Precise version of the initscripts package, that this gets configured before resolvconf is unpackaged, and that the resulting system has a /run tmpfs?
--
Thomas

Revision history for this message
Thomas Hood (jdthood) wrote :

Sebastian Unger: Update your mirror to resolvconf 1.63ubuntu7 and try again. And report your results! Versions 1.63ubuntu5 and 1.63ubuntu6 installed the /etc/resolv.conf symlink differently from other versions of the package. That could explain why, when you install Oneiric + resolvconf 1.63ubuntu6 + its dependencies, your /etc/resolv.conf is not symlinked to /run/resolvconf/resolv.conf.

A second problem is that /run/resolvconf does not get created on your system. This surprising phenomenon has already been reported at #927300.

A third problem is that dpkg-reconfigure doesn't fix the second problem. Dpkg-reconfigure does not re-run the preinst but it does re-run the postinst which runs an Upstart job which should create /run/resolvconf. So if you run dpkg-reconfigure *twice* it should succeed the second time. If it does not do so in your case then that is either a bug in 1.63ubuntu6 or bug #929552 which I mentioned above.

Revision history for this message
Sebastian Unger (sebunger44) wrote :

Re #10: No. The only package I pulled from precise was resolvconf as the dependencies indicated that nothing else was needed.
Re #11: 1.63ubuntu7 appears to work fine. Thanks a lot!

Revision history for this message
Thomas Hood (jdthood) wrote :

> Re #10: No. The only package I pulled from precise was resolvconf as the dependencies indicated that nothing else was needed.

Ah, sorry, I was confused again: Oneiric's initscripts package already meets resolvconf 1.63ubuntu[67]'s dependency requirements. Oneiric already has /run on a tmpfs.

> Re #11: 1.63ubuntu7 appears to work fine.

Good to hear!
--
Thomas

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.