derekmahar
(Derek Mahar)
January 28, 2024, 9:41pm
1
Why does Incus 0.5 fail to start an Ubuntu 22.04 container on a Proxmox 8.1 host? Can Incus and Proxmox coexist on the same host? Might I have configured Incus incorrectly?
derek@proxmox:~$ incus launch images:ubuntu/22.04
Launching the instance
Error: Failed instance creation: Failed to run: /opt/incus/bin/incusd forkstart fit-cat /var/lib/incus/containers /run/incus/fit-cat/lxc.conf: exit status 1
Note that user derek is a member of group incus-admin.
stgraber
(Stéphane Graber)
January 28, 2024, 10:15pm
2
Anything useful in incus info --show-log fit-cat
?
derekmahar
(Derek Mahar)
January 28, 2024, 11:08pm
3
I deleted instance fit-cat
and created instance causal-cub
.
derek@proxmox:~$ incus info --show-log causal-cub
Name: causal-cub
Status: STOPPED
Type: container
Architecture: x86_64
Created: 2024/01/28 18:05 EST
Last Used: 2024/01/28 18:05 EST
Log:
lxc causal-cub 20240128230524.675 ERROR conf - ../src/lxc/conf.c:lxc_map_ids:3701 - newuidmap failed to write mapping "newuidmap: write to uid_map failed: Invalid argument": newuidmap 567676 0 100000 65536 0 1000000 1000000000
lxc causal-cub 20240128230524.675 ERROR start - ../src/lxc/start.c:lxc_spawn:1788 - Failed to set up id mapping.
lxc causal-cub 20240128230524.675 ERROR lxccontainer - ../src/lxc/lxccontainer.c:wait_on_daemonized_start:878 - Received container state "ABORTING" instead of "RUNNING"
lxc causal-cub 20240128230524.676 ERROR start - ../src/lxc/start.c:__lxc_start:2107 - Failed to spawn container "causal-cub"
lxc causal-cub 20240128230524.676 WARN start - ../src/lxc/start.c:lxc_abort:1036 - No such process - Failed to send SIGKILL via pidfd 17 for process 567676
lxc 20240128230524.694 ERROR af_unix - ../src/lxc/af_unix.c:lxc_abstract_unix_recv_fds_iov:218 - Connection reset by peer - Failed to receive response
lxc 20240128230524.694 ERROR commands - ../src/lxc/commands.c:lxc_cmd_rsp_recv_fds:128 - Failed to receive file descriptors for command "get_init_pid"
Are the values for user derek in /etc/subuid
and /etc/subgid
relevant?
derek@proxmox:~$ cat /etc/subuid
archive:231072:65536
derek:165536:65536
proxmox:296608:65536
root:100000:65536
root:1000:2
root:1000000:1000000000
derek@proxmox:~$ cat /etc/subgid
archive:231072:65536
derek:165536:65536
proxmox:296608:65536
root:100000:65536
root:1100:1
root:1000000:100000000
stgraber
(Stéphane Graber)
January 28, 2024, 11:23pm
4
Hmm, can you try removing those root
entries and for now try with just the root:1000000:100000000
one and then restart incus?
derekmahar
(Derek Mahar)
January 28, 2024, 11:37pm
5
Is that the correct number of zeros in the root entry? How do I restart incus?
derekmahar
(Derek Mahar)
January 28, 2024, 11:39pm
6
Please ignore my previous question about the root entry to which you referred. I see that it is already in each file.
Does sudo systemctl restart incus
restart incus?
derekmahar
(Derek Mahar)
January 28, 2024, 11:54pm
7
Thank you. That solved the problem. Following the instructions in documents that I had found online, I had changed the original versions of /etc/subuid
and /etc/subgid
to map user IDs between the Proxmox host and a Proxmox container, but I don’t yet fully grasp how this works. I’ve learned that Linux containers are rather sensitive to changes to these files.
derek@proxmox:~$ sudo systemctl restart incus
derek@proxmox:~$ incus launch images:ubuntu/22.04
Launching the instance
Instance name is: faithful-colt
derek@proxmox:~$ incus list
+---------------+---------+----------------------+-----------------------------------------------+-----------+-----------+
| NAME | STATE | IPV4 | IPV6 | TYPE | SNAPSHOTS |
+---------------+---------+----------------------+-----------------------------------------------+-----------+-----------+
| causal-cub | STOPPED | | | CONTAINER | 0 |
+---------------+---------+----------------------+-----------------------------------------------+-----------+-----------+
| faithful-colt | RUNNING | 10.194.100.13 (eth0) | fd42:8d9d:bc16:cfee:216:3eff:feb4:c554 (eth0) | CONTAINER | 0 |
+---------------+---------+----------------------+-----------------------------------------------+-----------+-----------+
derek@proxmox:~$ cat /etc/subgid
archive:231072:65536
derek:165536:65536
proxmox:296608:65536
#root:100000:65536
#root:1100:1
root:1000000:1000000000
derek@proxmox:~$ cat /etc/subuid
archive:231072:65536
derek:165536:65536
proxmox:296608:65536
#root:100000:65536
#root:1000:2
root:1000000:1000000000