Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fail to build wheezy box on archlinux #13

Closed
fbourigault opened this issue Jul 31, 2014 · 6 comments
Closed

Fail to build wheezy box on archlinux #13

fbourigault opened this issue Jul 31, 2014 · 6 comments

Comments

@fbourigault
Copy link

I'm trying to build the debian wheezy box on my archlinux host. It fails (see output and log for details). In the log we can see lxc_container: No such file or directory - failed to exec 'update-locale' seems that update-locale is missing from container.

Output:

[fabien@vtfabien vagrant-lxc-base-boxes]$ make wheezy
==> [wheezy] Building box to 'output/2014-07-31/vagrant-lxc-wheezy-amd64.box'...
==> [wheezy] The 'vagrant-base-wheezy-amd64' container already exists, do you want to continue building the box? [Y/n] y
==> [wheezy] Do you want to rebuild the 'vagrant-base-wheezy-amd64' container? [y/N] y
    [wheezy] Destroying container vagrant-base-wheezy-amd64...
    [wheezy] Creating container...
    [wheezy] Container created!
    [wheezy] Adding ipv6 allhosts entry to container's /etc/hosts
    [wheezy] Running [/usr/sbin/update-rc.d -f checkroot-bootclean.sh remove] inside 'vagrant-base-wheezy-amd64' container...
    [wheezy] Running [/usr/sbin/update-rc.d -f mountall-bootclean.sh remove] inside 'vagrant-base-wheezy-amd64' container...
    [wheezy] Running [/usr/sbin/update-rc.d -f mountnfs-bootclean.sh remove] inside 'vagrant-base-wheezy-amd64' container...
    [wheezy] Running [/usr/sbin/locale-gen fr_FR.utf8] inside 'vagrant-base-wheezy-amd64' container...
    [wheezy] Running [update-locale LANG=fr_FR.utf8] inside 'vagrant-base-wheezy-amd64' container...
Makefile:26: recipe for target 'wheezy' failed
make: *** [wheezy] Error 255

Log:

############################################
# Beginning build at jeu. juil. 31 11:23:05 CEST 2014
==> [wheezy] [INFO] Building box to 'output/2014-07-31/vagrant-lxc-wheezy-amd64.box'...
    [wheezy] Destroying container vagrant-base-wheezy-amd64...
    [wheezy] Creating container...
Using image from local cache
Unpacking the rootfs

---
You just created a Debian container (release=wheezy, arch=amd64, variant=default)
The default root password is: root

    [wheezy] Container created!
    [wheezy] Adding ipv6 allhosts entry to container's /etc/hosts
    [wheezy] Running [/usr/sbin/update-rc.d -f checkroot-bootclean.sh remove] inside 'vagrant-base-wheezy-amd64' container...
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
    LANGUAGE = (unset),
    LC_ALL = (unset),
    LANG = "fr_FR.utf8"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
update-rc.d: using dependency based boot sequencing
    [wheezy] Running [/usr/sbin/update-rc.d -f mountall-bootclean.sh remove] inside 'vagrant-base-wheezy-amd64' container...
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
    LANGUAGE = (unset),
    LC_ALL = (unset),
    LANG = "fr_FR.utf8"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
update-rc.d: using dependency based boot sequencing
    [wheezy] Running [/usr/sbin/update-rc.d -f mountnfs-bootclean.sh remove] inside 'vagrant-base-wheezy-amd64' container...
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
    LANGUAGE = (unset),
    LC_ALL = (unset),
    LANG = "fr_FR.utf8"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
update-rc.d: using dependency based boot sequencing
    [wheezy] Running [/usr/sbin/locale-gen fr_FR.utf8] inside 'vagrant-base-wheezy-amd64' container...
/usr/sbin/locale-gen: 24: /usr/sbin/locale-gen: rm: not found
Generating locales (this might take a while)...
Generation complete.
    [wheezy] Running [update-locale LANG=fr_FR.utf8] inside 'vagrant-base-wheezy-amd64' container...
lxc_container: No such file or directory - failed to exec 'update-locale'
@fgrehm
Copy link
Owner

fgrehm commented Aug 9, 2014

Weird, I'm not 100% sure how to set things up on archlinux so it might take me some time to understand what's going on =/

@tripledes
Copy link
Contributor

Hi, I did find what's wrong...when utils.lxc.attach is executed, $PATH is lost, modifying the function as follows solves the issue:

lxc-attach -n ${CONTAINER} -v PATH=/bin:/sbin:/usr/bin:/usr/sbin -- $cmd &>> ${LOG}

@fgrehm I could submit a PR, I don't think it would break other distros' support but cannot test.

@fgrehm
Copy link
Owner

fgrehm commented Sep 25, 2014

@tripledes thanks! please do send that PR and I'll give it a try down here :)

@svenXY
Copy link

svenXY commented Oct 21, 2014

I can confirm that @tripledes patch resolves that problem.

Unfortunately, I then stumble into problems with name resolution or networking:

Generating locales (this might take a while)...
  de_DE.UTF-8... done
Generation complete.
    [debian-wheezy] Running [update-locale LANG=de_DE.UTF-8] inside 'vagrant-base-wheezy-amd64' container...
==> [debian-wheezy] [INFO] Installing extra packages and upgrading
    [debian-wheezy] Sleeping for 10 seconds...
    [debian-wheezy] Running [apt-get update] inside 'vagrant-base-wheezy-amd64' container...
Fehl http://cdn.debian.net wheezy Release.gpg
  »cdn.debian.net« konnte nicht aufgelöst werden.
Paketlisten werden gelesen...
W: Fehlschlag beim Holen von http://cdn.debian.net/debian/dists/wheezy/Release.gpg  »cdn.debian.net« konnte nicht aufgelöst werden.
...

@sephii
Copy link

sephii commented May 9, 2015

I had the same neworking issue and had to change /etc/lxc/default.conf to get it working:

lxc.network.type = veth
lxc.network.flags = up
lxc.network.link = lxcbr0

@fgrehm
Copy link
Owner

fgrehm commented Dec 6, 2015

I've stepped down as a maintainer of the plugin and I'm no longer maintaining this repo. Feel free to use it as a starting point for your own boxes and if you need any help with that just LMK! 🍻

@fgrehm fgrehm closed this as completed Dec 6, 2015
DavBfr pushed a commit to DavBfr/vagrant-lxc-base-boxes that referenced this issue Dec 4, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants