Does instance snapshot saves network configuration?

101 Views Asked by At

So, I want the user to make some network configurations, like firewall, QoS and so on, inside the instance using the console. And I want to save the instance with those configurations. If I take a snapshot after the user make those configuration, does it saves them?

1

There are 1 best solutions below

0
On

Does instance snapshot saves network configuration?

No it doesn't1. Those things are all specified or (in the case of a static IP address) allocated when the instance is launched.

To see what is actually stored, take a look at the Openstack Glance Service APIs ... or more specifically the APIs that deal with image metadata and metadata schemas.


1 - The Glance APIs allow you to modify the image schemas, so in theory you should be able to record anything as part of the image (i.e. snapshot) metadata. However, it would be up to you write code to gather the relevant network config information, encode it as metadata, and add it to the image. And you would also need to write more code to turn the stored network config metadata into an actual configuration when launching from your snapshot. It is probably not practical.