When creating a new container in a new project without inherits the default profile it creates a empty
profile that stops the launch of a new container until the root and eth0 information be defined.
1- lxc project create demo
Project demo created
2- lxc project switch demo
3- lxc ls
| NAME | STATE | IPV4 | IPV6 | TYPE | SNAPSHOTS |
+------+-------+------+------+------+-----------+
4- lxc storage ls
| NAME | DESCRIPTION | DRIVER | SOURCE | USED BY |
+---------+-------------+--------+--------------------------------+---------+
| default | | zfs | /var/lib/lxd/disks/default.img | 14 |
+---------+-------------+--------+--------------------------------+---------+
5- lxc launch ubuntu:16.04 c1
Creating c1
Error: Failed container creation: Create container: Create LXC container: Invalid devices: Detect root disk device: No root device could be found
dmesg)lxc info NAME --show-log)lxc config show NAME --expanded)lxc monitor while reproducing the issue)Its not a problem at all ! Sorry about that
In my understanding if not inherited from the default project then the images and profiles must be different or customized and set individually:
1-Listing the actual profile
lxc profile show default
lxc profile show default
config: {}
description: Default LXD profile for project demo
devices: {}
name: default
used_by: []
2- Defining a disk
lxc profile device add default root disk path=/ pool=default
Device root added to default
3- Defining a network
lxc profile device add default eth0 nic name=eth0 nictype=bridged parent=lxdbr0
Device eth0 added to default
4- Launching
lxc launch ubuntu:16.04 c1
Creating c1
Starting c1
5- Listing
lxc ls
| NAME | STATE | IPV4 | IPV6 | TYPE | SNAPSHOTS |
+------+---------+---------------------+------+------------+-----------+
| c1 | RUNNING | 10.75.88.168 (eth0) | | PERSISTENT | |
+------+---------+---------------------+------+------------+-----------+
Most helpful comment
Its not a problem at all ! Sorry about that
In my understanding if not inherited from the default project then the images and profiles must be different or customized and set individually:
1-Listing the actual profile
lxc profile show default
2- Defining a disk
lxc profile device add default root disk path=/ pool=default
3- Defining a network
lxc profile device add default eth0 nic name=eth0 nictype=bridged parent=lxdbr0
4- Launching
lxc launch ubuntu:16.04 c1
5- Listing
lxc ls