相关疑难解决方法(0)

有没有办法在 Docker 中运行 LXD?

有没有办法在 Docker 中运行 LXD?例如。

在 ubuntu 16.04 的主机上:

docker run --rm -it --net host --privileged ubuntu bash
Run Code Online (Sandbox Code Playgroud)

在容器中:

apt update && apt install -y lxd iproute2 btrfs-tools screen bash-completion curl wget apt-transport-https lxcfs lxd-tools lxd-client vim overlayroot libkmod2 libkmod-dev cgroup-tools cgroupfs-mount cgroup-bin

screen -S lxd
# in screen
lxd --debug --group lxd


lxd init
lxc list
lxc launch ubuntu:16.04 test
Run Code Online (Sandbox Code Playgroud)

LXD 守护进程可以工作,但由于 cgroup 错误,我无法启动 LXD 容器。

error: Error calling 'lxd forkstart test /var/lib/lxd/containers /var/log/lxd/test/lxc.conf': err='exit status 1'
  lxc 20170502151757.409 ERROR …
Run Code Online (Sandbox Code Playgroud)

docker lxd

6
推荐指数
1
解决办法
3788
查看次数

标签 统计

docker ×1

lxd ×1