« Previous | Next » 

Revision f30eb81a

IDf30eb81ab588beb164867e09fe085479290979b0

Added by Dimitris Aragiorgis over 10 years ago

Hotplug: cmdlib support

Hotpluging is done by functions invoked by ApplyContainerMods(). In
order hotpluging to take place the --hotplug option must be passed
otherwise the modifications will take place after reboot.

NIC hotplug supports add, remove and modify. The modify is done by removing
the existing NIC and adding a new one in the same pci slot.

Disk hotplug support add and remove. Before hotpluging a Disk it
must be assembled. During LUInstanceSetParams() newly created disks
are not added to the instance so ExpandCheckDisks() in
AssembleInstanceDisks() will fail. So we make this check optional
only for this case.

In order to remove a disk (with blockdev_remove) it must be shutdown. So
after unpluging the disk ShutdownDiskInstanceDisks() must be invoked.

For both device types we use the generic RPC call_hotplug_device.

Signed-off-by: Dimitris Aragiorgis <>

Files

  • added
  • modified
  • copied
  • renamed
  • deleted

View differences