cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2189
Views
0
Helpful
1
Replies

Installing UCSPE 2.2.3a on Red Hat KVM

malarivi
Cisco Employee
Cisco Employee

Purpose:
Provide a known method of installing the UCSM Emulator on KVM.

Scope:
Cisco UCS and Red Hat System Administrators

Requirements:
- An available LVM-VG with aproximately 20Gb free
- Packages libvirt and virt-manager installed on the host
- Provided TechZone virt-manager XML file

Download Links:
- UCSM Emulator 2.2.3a alternate zip download
- UCSM Emulator 2.2.3a firmware metapackage

1. Convert vmdk files to raw
for i in `ls *.vmdk` ; do qemu-img convert $i -O raw $i.raw ; done

2. Create logical volumes for kvm

Locate a volume group with free space:
[root@itxfiler qemu]# vgs

VG #PV #LV #SN Attr VSize VFree

vg_itxfiler 1 9 0 wz--n- 595.68g 165.23g

Identify the size and create new logical volumes:
# ls -l *.raw | awk '{print $5 " " $9}'
1073741824 ucspe.vmdk.raw
1073741824 ucspe-0.vmdk.raw
4294967296 ucspe-1.vmdk.raw
1073741824 ucspe-2.vmdk.raw

Create the partitions:
lvcreate -L 1073741824b -n ucsemu vg_itxfiler
lvcreate -L 1073741824b -n ucsemu0 vg_itxfiler
lvcreate -L 1073741824b -n ucsemu1 vg_itxfiler
lvcreate -L 1073741824b -n ucsemu2 vg_itxfiler
3. Migrate raw partition data to volumes
dd if=ucspe.vmdk.raw of=/dev/vg_itxfiler/ucsemu
dd if=ucspe-0.vmdk.raw of=/dev/vg_itxfiler/ucsemu0
dd if=ucspe-1.vmdk.raw of=/dev/vg_itxfiler/ucsemu1
dd if=ucspe-2.vmdk.raw of=/dev/vg_itxfiler/ucsemu2

4. Import the UCSM Emulator Domain Profile XML
[root@itxfiler qemu]# cat ucsEmu.xml

<!-- UCSM Emulator Working-Minimal noSE -->
<domain type='kvm'>
  <name>UCS Emulator</name>
  <uuid>87f8f4a3-3687-4a33-8f7f-7928523d1bf3</uuid>
  <description>Cisco UCS Manager 2.2.3a Emulator</description>
  <memory unit='KiB'>2097152</memory>
  <currentMemory unit='KiB'>2097152</currentMemory>
  <vcpu placement='static'>1</vcpu>
  <os>
    <type arch='x86_64' machine='rhel6.5.0'>hvm</type>
    <boot dev='hd'/>
  </os>
  <features>
    <acpi/>
    <apic/>
    <pae/>
  </features>
  <clock offset='utc'>
    <timer name='rtc' tickpolicy='catchup'/>
    <timer name='pit' tickpolicy='delay'/>
    <timer name='hpet' present='no'/>
  </clock>
  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>restart</on_crash>
  <devices>
    <emulator>/usr/bin/qemu-kvm</emulator>
    <disk type='block' device='disk'>
      <driver name='qemu' type='raw' cache='none' io='native'/>
      <source dev='/dev/vg_itxfiler/ucsemu'/>
      <target dev='hda' bus='ide'/>
      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
    </disk>
    <disk type='block' device='disk'>
      <driver name='qemu' type='raw' cache='none' io='native'/>
      <source dev='/dev/vg_itxfiler/ucsemu0'/>
      <target dev='hdb' bus='ide'/>
      <address type='drive' controller='0' bus='0' target='0' unit='1'/>
    </disk>
    <disk type='block' device='disk'>
      <driver name='qemu' type='raw' cache='none' io='native'/>
      <source dev='/dev/vg_itxfiler/ucsemu1'/>
      <target dev='hdc' bus='ide'/>
      <address type='drive' controller='0' bus='1' target='0' unit='0'/>
    </disk>
    <disk type='block' device='disk'>
      <driver name='qemu' type='raw' cache='none' io='native'/>
      <source dev='/dev/vg_itxfiler/ucsemu2'/>
      <target dev='hdd' bus='ide'/>
      <address type='drive' controller='0' bus='1' target='0' unit='1'/>
    </disk>
    <controller type='ide' index='0'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
    </controller>
    <controller type='virtio-serial' index='0'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x08' function='0x0'/>
    </controller>
    <controller type='usb' index='0'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
    </controller>
    <interface type='bridge'>
      <mac address='00:0c:29:08:a6:a0'/>
      <source bridge='br0'/>
      <model type='e1000'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
    </interface>
    <interface type='bridge'>
      <mac address='00:0c:29:08:a6:aa'/>
      <source bridge='br0'/>
      <model type='e1000'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
    </interface>
    <interface type='bridge'>
      <mac address='00:0c:29:08:a6:b4'/>
      <source bridge='br0'/>
      <model type='e1000'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
    </interface>
    <serial type='pty'>
      <target port='0'/>
    </serial>
    <console type='pty'>
      <target type='serial' port='0'/>
    </console>
    <channel type='spicevmc'>
      <target type='virtio' name='com.redhat.spice.0'/>
      <address type='virtio-serial' controller='0' bus='0' port='1'/>
    </channel>
    <input type='mouse' bus='ps2'/>
    <graphics type='spice' autoport='yes' listen='127.0.0.1' keymap='en-us'>
      <listen type='address' address='127.0.0.1'/>
    </graphics>
    <video>
      <model type='qxl' ram='65536' vram='65536' heads='1'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
    </video>
    <memballoon model='virtio'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x09' function='0x0'/>
    </memballoon>
  </devices>
</domain>

Now import it into virt-manager with virsh:

#  virsh define /etc/libvirt/qemu/ucsEmu.xml

*You may need to configure a static keymap of en-us in virt-manager to use the console.

Launch CLI GUI w/o Browser: (survives upgrades)

# javaws http://yourIpAddr/ucsm/ucsm.jnlp !

First-login:

admin / password

  

! !

1 Reply 1

ranumala
Cisco Employee
Cisco Employee

Can you please post Download Links:I dont see them added above.

Review Cisco Networking products for a $25 gift card