« Previous | Next » 

Revision b44b39ad

IDb44b39ad7209892a2c22dacfc48e2a3755e5f54c

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