Results 1 to 5 of 5

Thread: Systemd Container Problems

  1. #1
    Join Date
    Feb 2020
    Beans
    4

    Angry Systemd Container Problems

    I used the command:
    Code:
    machinectl pull-tar https://cloud-images.ubuntu.com/trusty/current/trusty-server-cloudimg-amd64-root.tar.gz  ubuntuTest
    Expecting to pull an image and have the OS Tree setup so that my next command would be
    Code:
    systemd-nspawn -M ubuntuTest
    But I keep getting an error that I am running out of space. This is what it looks like:
    Code:
    tar: var/lib/dpkg/alternatives/telnet: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/awk: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/lzma: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/vtrgb: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/mt: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/jsondiff: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/newt-palette: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/www-browser: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/rename: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/vim: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/vi: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/locate: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/vimdiff: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/pico: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/ftp: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/pager: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/w: Cannot write: No space left on devicetar: var/lib/dpkg/alternatives/rview: Cannot write: No space left on device
    I have a lot of space and this looks very similar to what is being described on github here:
    https://github.com/systemd/systemd/issues/5859
    From the link above this is what I think I am also experiencing:
    Code:
    Apparently, machinectl creates a filesystem which is too small andthen fails with a rather vague error message. My / filesystem has plenty of space free. I had to fiddle with qemu-img resize to resize /var/lib/machines.raw, btrfs filesystem resize to grow the file system and machinectl set-limit.
    What can I do to install a systemd container?

  2. #2
    Join Date
    Mar 2007
    Location
    Denver, CO
    Beans
    7,835
    Distro
    Ubuntu Mate 16.04 Xenial Xerus

    Re: Systemd Container Problems

    Hi - I don't have a lot of knowledge of what you are trying to do. Are you trying to containerize the trusty-server? Could you not just use a docker image for a container?

  3. #3
    Join Date
    Feb 2020
    Beans
    4

    Re: Systemd Container Problems

    Yes docker is most popular but I am familiarizing myself with systemd-containers as this offers a very quick way of setting up a virtual OS that is packaged with the excellent features of Systemd. Machinectl and systemd-nspawn commands are easy to use. I wish to learn more about systemd-containers. It works well with CenotOS but debian based architectures are giving me some trouble. I can't install a container on ubuntu nor mint. I can't even pull the image. Looking for help.

  4. #4
    Join Date
    Feb 2020
    Beans
    4

    Re: Systemd Container Problems

    When you run the machinectl pull-tar command it appears to create several squashfs that run out of space and a btrfs as well. I found this out having ran "df -Th" after running the machinectl pull-tar command:
    Code:
    machinectl pull-tar https://cloud-images.ubuntu.com/trusty/current/trusty-server-cloudimg-amd64-root.tar.gz ubuntuTest
    This is where I am stuck. Help wanted

    filesystems.png

  5. #5
    Join Date
    Feb 2020
    Beans
    4

    Re: Systemd Container Problems

    Just wanted to let the forum know, this issue was solved. Taken from this link:
    https://askubuntu.com/questions/1094...ting-diskimage

    The file system that machinectl creates has to be resized:
    Code:
    • Unmount /var/lib/machines & resize /var/lib/machines.raw: $ umount /var/lib/machines ; qemu-img resize -f raw /var/lib/machines.raw +16G
    • Restart machinectl Service: $ systemctl restart /var/lib/machines
    • Resize btrfs Volume: $ btrfs filesystem resize max /var/lib/machines
    SOLVED

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •