« Previous | Next » 

Revision 746f7476

ID746f7476f3f28da87dc757f686b64ebd3de4f87f
Parent cacfd1fd
Child e1bc0878

Added by Iustin Pop about 15 years ago

Change BlockDev.Shutdown() failure result

Currently, the Shutdown() methods of block devices return True/False.
This doesn't permit any error detail reporting.

This patch changes the return type to None for success, and raises
BlockDeviceError in case of failure. This permits the details to be
passed up the stack.

For LVM and file-backed devices, this is a simple change. For DRBD, we
first remove the shutdown of disks in case of network activation
failures (since with static minors the minor is used anyway, we don't
gain anything by clearing it), and the we simply change _ShutdownAll()
to raise an exception.

Reviewed-by: ultrotter

Files

  • added
  • modified
  • copied
  • renamed
  • deleted

View differences