在 debian Buster 上启动容器时 lxc(-net ?) 问题

在 debian Buster 上启动容器时 lxc(-net ?) 问题

我已经(尝试)进行设置,以允许自己拥有一些可以根据需要启动(然后使用)的非特权容器。

现在我可以使用 创建新容器lxc-create,但是当我尝试启动一个容器时,会发生这种情况

> lxc-start --name frisk-buster                                                                                                                                                                                                                                                                                 ~
lxc-start: frisk-buster: lxccontainer.c: wait_on_daemonized_start: 842 Received container state "ABORTING" instead of "RUNNING"
lxc-start: frisk-buster: tools/lxc_start.c: main: 330 The container failed to start
lxc-start: frisk-buster: tools/lxc_start.c: main: 333 To get more details, run the container in foreground mode
lxc-start: frisk-buster: tools/lxc_start.c: main: 336 Additional information can be obtained by setting the --logfile and --logpriority options
> lxc-start --name frisk-buster -F
lxc-start: frisk-buster: network.c: lxc_create_network_unpriv_exec: 2178 lxc-user-nic failed to configure requested network: cmd/lxc_user_nic.c: 1296: main: Quota reached
                                                                                                                                                                          lxc-start: frisk-buster: start.c: lxc_spawn: 1777 Failed to create the configured network
                                                                                                                                                                                                                                                                   lxc-start: frisk-buster: start.c: __lxc_start: 1951 Failed to spawn container "frisk-buster"
                                 lxc-start: frisk-buster: tools/lxc_start.c: main: 330 The container failed to start
lxc-start: frisk-buster: tools/lxc_start.c: main: 336 Additional information can be obtained by setting the --logfile and --logpriority options

(当我在前台模式下运行容器时,我不知道为什么换行符看起来像这样,但这并不重要)

在搜索该错误时,我在网上发现的唯一一件事是建议编辑/etc/lxc/lxc-usernet以包含“your-username veth lxcbr0 10”,但在我的系统上它已经这样做了(除了现在我已将限制设置为 25 来验证这不是问题。

有什么问题吗?

答案1

“配额已达到”消息实际上是正确的。由于某种原因(可能是从不同的来源复制粘贴,即使我没有看到,它的作用也不同),我的容器的配置文件说要创建一个名为维尔br0,而lxc-usernet配置允许我创建名为的接口长沙br。改变维尔长沙在容器的配置中修复了一些事情。

相关内容