Merge lp:~soren/nova/uml into lp:~hudson-openstack/nova/trunk

Proposed by Soren Hansen
Status: Merged
Approved by: Vish Ishaya
Approved revision: 260
Merged at revision: 269
Proposed branch: lp:~soren/nova/uml
Merge into: lp:~hudson-openstack/nova/trunk
Diff against target: 30 lines (+5/-4)
2 files modified
nova/virt/libvirt.uml.xml.template (+2/-4)
nova/virt/libvirt_conn.py (+3/-0)
To merge this branch: bzr merge lp:~soren/nova/uml
Reviewer Review Type Date Requested Status
Vish Ishaya (community) Approve
Devin Carlen (community) Approve
Eric Day (community) Approve
Review via email: mp+33943@code.launchpad.net

Description of the change

Just a couple of UML-only fixes:
 * Due to an issue with libvirt, we need to chown the disk image to root.
 * Just point UML's console directly at a file, and don't bother with the pty. It was only used for debugging.

To post a comment you must log in.
Revision history for this message
Eric Day (eday) wrote :

Did you mean to edit the UML libvirt template instead of the qemu template? Commit messages say UML template change.

review: Needs Information
Revision history for this message
Soren Hansen (soren) wrote :

Blimey! You're right.

Revision history for this message
Soren Hansen (soren) wrote :

Please re-review. Thanks.

Revision history for this message
Eric Day (eday) wrote :

looks better :)

review: Approve
Revision history for this message
Devin Carlen (devcamcar) wrote :

lgtm

review: Approve
Revision history for this message
Vish Ishaya (vishvananda) wrote :

lgtm as well

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'nova/virt/libvirt.uml.xml.template'
2--- nova/virt/libvirt.uml.xml.template 2010-08-13 21:44:14 +0000
3+++ nova/virt/libvirt.uml.xml.template 2010-09-01 19:01:56 +0000
4@@ -15,11 +15,9 @@
5 <source bridge='%(bridge_name)s'/>
6 <mac address='%(mac_address)s'/>
7 </interface>
8- <console type="pty" />
9- <serial type="file">
10+ <console type="file">
11 <source path='%(basepath)s/console.log'/>
12- <target port='1'/>
13- </serial>
14+ </console>
15 </devices>
16 <nova>%(nova)s</nova>
17 </domain>
18
19=== modified file 'nova/virt/libvirt_conn.py'
20--- nova/virt/libvirt_conn.py 2010-09-01 18:15:14 +0000
21+++ nova/virt/libvirt_conn.py 2010-09-01 19:01:56 +0000
22@@ -268,6 +268,9 @@
23 yield disk.partition(
24 basepath('disk-raw'), basepath('disk'), bytes, execute=execute)
25
26+ if FLAGS.libvirt_type == 'uml':
27+ execute('sudo chown root %s' % (basepath('disk'),))
28+
29 def basepath(self, instance, path=''):
30 return os.path.abspath(os.path.join(instance.datamodel['basepath'], path))
31