Changeset 65 for trunk/packages/sipb-xen-database
- Timestamp:
- Aug 7, 2007, 11:08:38 PM (17 years ago)
- svk:copy_cache_prev:
- 62
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/packages/sipb-xen-database/sipb-xen-database/conf.py
r24 r65 4 4 5 5 machine = models.Machine.get_by(name=name) 6 6 machine_type = models.Type.get_by(type_id=machine.type_id) 7 7 8 8 memory = machine.memory … … 13 13 vcpus = machine.cpus 14 14 15 # XXX TODO deal with vifs 15 diskioemu = "" 16 viftype = "" 17 18 if machine_type.hvm: 19 ioemu = "ioemu:" 20 viftype = "type=ioemu" 21 22 kernel = 'hvmloader' 23 builder = 'hvm' 24 vnc = 1 25 device_model = 'qemu-dm' 26 else: 27 kernel = '/boot/vmlinuz-2.6.18-4-xen-amd64' 28 ramdisk = '/boot/initrd.img-2.6.18-4-xen-amd64' 29 builder = 'linux' 30 31 pae = machine_type.pae 32 acpi = machine_type.acpi 33 apic = machine_type.apic 34 35 vif = [] 36 37 for n in machine.nics: 38 d = '%s, mac=%s, ip=%s, bridge=xenbr0' % (viftype, n.mac_addr, n.ip) 39 vif.append(disk) 16 40 17 41 disk = [] 18 42 19 43 for d in machine.disks: 20 dspec = 'phy:xenvg/%s,%s,w' % (???, d.guest_device_name) 44 device = 'xenvg/' + machine.name + '_' + d.guest_device_name 45 dspec = 'phy:%s,%s%s,w' % (device, diskioemu, d.guest_device_name) 21 46 disk.append(dspec) 22 47
Note: See TracChangeset
for help on using the changeset viewer.