Wednesday, January 22, 2014

Ops Center - Orphaned LDom after live migration

UPDATE: We recently upgraded to 12.2 and I can confirm this issue is still present in 12.2. The work-around listed below still works thankfully...

Recently I was charged with upgrading the system firmware across our T4-4 fleet. One of the provisos was that no LDom could be shutdown during the upgrade. This of course meant I needed to lean heavily on Oracle Enterprise Ops Center's "live migration" feature. Which at best, is more of a warm migration.

We are still running 12c Update 2 (not for long hopefully), so there were many issues encountered. One of the more annoying issues was after each migration, the LDom appeared to not be associated with a CDom anymore. It was still associated, and nothing actually was broken, just the view from the BUI showed it sitting at the top of the All Assets tree. And given it's aparent location, I was unable to migrate it again, until the hierarchy display was resolved.

An easy fix I discovered was restarting the proxy service on our colocated EC/Proxy server.

# /opt/SUNWxvmoc/bin/proxyadm stop -vw
# /opt/SUNWxvmoc/bin/proxyadm start -vw

Refresh the browser, and it's fixed. I logged an SR about this, and aparently it is resolved in Update 4 and/or the upcoming "Diamond" release. The engineer I spoke to did mention that a proxyadm restart fixed a lot of various BUI display issues...

Extending a Linux Virtual Disk

Something that popped up at work the other day, figured it was worth sharing given it's probably a fairly common task for a Sysadmin these days.
Check current disk size/free space
# df -h

Shut the machine down
# shutdown -h now

Using Microsoft Virtual Machine Manager (2008 R2):
- Right click the machine, and click on Properties
- Select the Hardware Configuration tab
- Select the disk from the left hand pane
- check Expand virtual hard disk, enter the new disk size and click OK

It will take a minute to rewrite the configuration and expand the current fixed vhd. Once complete, power the machine on again.

Delete current partition table for disk:
# fdisk device (eg. /dev/sda1)
d (delete partition)
n (create new partition)
p (primary)
1 (partition 1)
Enter (use default)
Enter (use default)
w (write new label)

Reboot machine:
# shutdown -r now

Resize filesystem:
# resize2fs (eg. /dev/sda1)

Confirm your changes have worked:
# df -h the happy dance