Perform some Ganeti administration tasks.
In this exercise, you will not be given all the commands you need. Use the presentation materials, the ganeti online documentation - especially the administrator's guide - and the command man gnt-instance
Find the current values of the backend settings "minmem" and "maxmem" on the instance you have created. What are they? (Hint: gnt-instance info
)
Make sure the instance is running, and then see how much memory it is actually using. (Hint: gnt-instance list
)
Increase the maxmem
setting on just this one instance to 1200MB. Can you change this while the instance is running?
When the instance is restarted, how much memory has ganeti allocated to it - the minimum or the maximum?
Login to the instance, and use the command free
to confirm that the amount of memory the VM sees is what you expect.
While the instance is running, use ganeti to change the runtime memory to 768MB.
How can you confirm that this setting has taken effect:
Add a second disk, size 2GB, to your existing instance.
Login to the instance. Inside the instance, how does it appear? (For example /dev/sdb or /dev/vdb?) Did you have to restart for it to become available?
Inside the instance, format the filesystem (mkfs -t ext4 /dev/xxx
) and mount it on /opt.
Add a second network card to the instance. Connect it to the br-lan instance and configure it so that it picks up an IP address using dhcp.
Create or edit a file in the instance. Then de-activate the disk, restart the instance, login and check that you can see the changed files.