Hello,
I am trying to improve the performance of my LXD VM machines by using stateful snapshoting. I want to reset the VM after each task to handle a new request.
I tried to create a new LXD VM with stateful snapshoting using the following command:
lxc init vm-image worker-x --vm -c limits.memory=3GiB -c migration.stateful=true
// now set size.state:
lxc config device set worker-x root size.state 3GiB
However, when I try to set the size.state
configuration key for the root device, I get the error Device from profile(s) cannot be modified for individual instance. Override device or modify profile instead
. The default LXD profile has a root device defined. How can I modify the device to make stateful snapshoting work?
Here is the default profile generated during LXD installation:
config: {}
description: Default LXD profile
devices:
eth0:
name: eth0
network: lxdbr0
type: nic
root:
path: /
pool: default
type: disk
name: default
Any help or guidance on this issue would be appreciated. Thank you.
Update:
need size.state=3GiB
not size.state 3GiB