Jump to: navigation, search

BlockDeviceConfig

Revision as of 18:17, 28 January 2013 by DanielBerrange (talk)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Block Device Configuration

Controls for block device configuration

There are a variety of independent attributes that it is desirable to control when configuring block devices for a virtual machine in OpenStack

Source type

  • Glance image
  • Cinder volume
  • Ephemeral file

Guest format

  • ext4 (or other FS formats)
  • ISO
  • Swap (different format per guest OS)
  • None

Device type

  • Disk
  • CDROM
  • Floppy
  • Flash (MMC)

Disk bus

  • USB
  • IDE
  • VirtIO
  • SCSI

Shutdown action

  • Delete
  • Preserve

Command line syntax for block config

The 'nova boot' command currently uses a combination of the '-image' and '-block-device-mapping' command line args to configure storage. The latter is mostly a clone of the same named arg from the EC2 commands, and is not a very well designed syntax from the POV of extensibility.

Given the extra features to be supported, it is desirable to introduce a new syntax for 'nova boot' and friends which is more expressive

Key off the device type:

  • -cdrom type=glance,id=XXXXXXXXX,bus=ide
  • -disk type=cinder,id=XXXXXXXXX,bus=ide
  • -mmc type=ephemeral,format=swap,size=50,dev=/dev/sda

Or a totally generic arg:

  • -block type=glance,id=XXXXXXX
  • -block type=cinder,id=XXXXXXX,bus=ide,device=cdrom
  • -block type=ephemeral,format=swap,size=50,bus=ide,device=floppy