no swap if block-device-mapping of /dev/vdb=swap

Bug #851218 reported by Scott Moser
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
High
Isaku Yamahata

Bug Description

Assuming:
  nova-manage instance_type create --flavor=0 --memory=512 --local_gb=2 --swap=512 --cpu=1 --name "m1.xsmall"

Running m1.xsmall instances like the following yeilds the given output:
A. <no block device mappings>
   md: { ami: vda, root: /dev/vda, ephemeral0: /dev/vdb, swap: /dev/vdc }
   disks: vda, vdb(ephemeral0), vdc(swap)
B. /dev/vdb=swap /dev/vdc=ephemeral0
   md: { ami: vda, root: /dev/vda, ephemeral0: /dev/vdc }
   disks: vdb(ephemeral0)
C. /dev/vdc=ephemeral0
   md: { ami: vda, root: /dev/vda, ephemeral0: /dev/vdc }
   disks: vda, vdb(ephemeral0)
D. /dev/vdb=ephemeral0
   md: { ami: vda, root: /dev/vda, swap: /dev/vdc, ephemeral0: /dev/vdb }
   disks: vda, vdb(ephemeral0), vdc(swap)
E. /dev/vdb=ephemeral0 /dev/vdc=swap
   md: { ami: vda, root: /dev/vda, ephemeral0: /dev/vdb, swap: /dev/vdc }
   disks: vda, vdb(ephemeral0), vdc(swap)

Above 'md' means data pulled from the instance's metadata service, 'disks' are disks actually seen to the instance.

Basically, above, if you specify swap "wrong", then you just lose it.

This is a low priority issue really. The user just needs to know that if the instance-type has swap, and they want to use it, they have to specify block device mappings correctly or not at all.

Related branches

Revision history for this message
Isaku Yamahata (yamahata) wrote :

Case B seems a bug. However other case seem correct according as the device is overriden.

Changed in nova:
assignee: nobody → Isaku Yamahata (yamahata)
status: New → In Progress
Thierry Carrez (ttx)
Changed in nova:
importance: Undecided → High
milestone: none → 2011.3
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.