** Description changed: - When running - lxc-create -t ubuntu -n u1-server -f /etc/lxc/local.conf -- -r lucid -a i386 -b matiasb + == Rationale == + On apt failure, LXC simply fails without telling the user that they may have an old cache and should just rebuild it. + This confuses some users who had some pretty old lucid cache on their system with out of date apt lists. + + The fix includes a better error message on failure and calls apt-get + update before trying to install anything. + + == Test case == + 1) Use a machine with a very old lucid cache (or manually break the apt lists) + 2) lxc-create -t ubuntu -n p1 -- --release lucid + 3) Check that it a) works or b) shows an error message telling you to wipe the cache + + == Regression potential == + It's just an extra apt-get update and a better error message so I don't expect any regression here. Worst case scenario, the user will just get the error message and have to wipe the cache. + + + When running + lxc-create -t ubuntu -n u1-server -f /etc/lxc/local.conf -- -r lucid -a i386 -b matiasb It downloads lucid packages, extracts packages, and then fails while installing: ... I: Installing core packages... W: Failure trying to run: chroot /var/cache/lxc/lucid/partial-i386 dpkg --force-depends --install /var/cache/apt/archives/libc6_2.11.1-0ubuntu7_i386.deb failed to execute template 'ubuntu' aborted ProblemType: Bug DistroRelease: Ubuntu 12.04 Package: lxc 0.7.5-3ubuntu30 ProcVersionSignature: Ubuntu 3.2.0-17.27-generic 3.2.6 Uname: Linux 3.2.0-17-generic i686 ApportVersion: 1.93-0ubuntu2 Architecture: i386 Date: Tue Feb 28 16:51:54 2012 InstallationMedia: Ubuntu 12.04 LTS "Precise Pangolin" - Alpha i386 (20111129.1) ProcEnviron: - TERM=xterm - PATH=(custom, no user) - LANG=en_US.UTF-8 - SHELL=/bin/bash + TERM=xterm + PATH=(custom, no user) + LANG=en_US.UTF-8 + SHELL=/bin/bash SourcePackage: lxc UpgradeStatus: No upgrade log present (probably fresh install)
** Changed in: lxc (Ubuntu Precise) Assignee: (unassigned) => Stéphane Graber (stgraber) ** Changed in: lxc (Ubuntu Precise) Status: New => In Progress -- You received this bug notification because you are a member of Ubuntu Server Team, which is subscribed to lxc in Ubuntu. https://bugs.launchpad.net/bugs/942862 Title: lxc-create failure creating a lucid container in a precise host with old cache To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/lxc/+bug/942862/+subscriptions -- Ubuntu-server-bugs mailing list Ubuntu-server-bugs@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs