Solaris Cluster in a Box

A VirtualBox Solaris Cluster complete with shared storage and quorum disk!

Host System

The host system is a Mac running 10.8:

Intel Core i7-3770K Ivy Bridge 3.5GHz
16Gb RAM
GeForce GTX 470 1280M
At the time of this article, I’m running Mac OSX 10.8.2 with VirtualBox 4.2.6. The Solaris Cluster is 3.3 running in a Solaris 10u10 virtual machine.
Read more ›

Posted in Solaris Cluster, Technology, Virtualization Tagged with: , , ,

VirtualBox Serial Port Console on Solaris 10

If you’re like me and prefer the command line to the GUI, here’s a trick and script to help you manage your Solaris VMs.

  1. Enable a serial port for the VM.
    1. Enable Port 1
    2. Port Number COM1
    3. Port Mode: Host Pipe
    4. Create Pipe
    5. Port/File Path: /tmp/vb-VM-NAME-console
  2. Perform a reconfiguration boot on the VM.
  3. Install socat on the host system

    sudo apt-get install socat
  4. Change the eeprom console device for the VM:

    eeprom console=ttya
  5. Change the /boot/grub/menu.lst for the VM:

    ...
    # To enable grub serial console to ttya uncomment the following lines
    # and comment out the splashimage line below
    # WARNING: don't enable grub serial console when BIOS console serial
    #       redirection is active!!!
    serial --unit=0 --speed=9600
    terminal serial
    #
    # Uncomment the following line to enable GRUB splashimage on console
    #splashimage /boot/grub/splash.xpm.gz
    #
    # To chainload another OS
    ...
  6. Bring down the VM:

    init 5
  7. Once this is done, we can now tell VirtualBox to boot the VM headless and connect with socat

    VBoxManage startvm node1 --type headless && socat -,raw,echo=0 /tmp/vb-node1-console

    I wrote a perl script to handle booting and connecting the console. Feel free to download: vb.pl


    $ vb.pl -h
    usage:

    vb.pl -l
    vb.pl -n VM -b
    vb.pl -n VM -p
    vb.pl -h

    -l : list VirtualBox machines
    -n : name of the VirtualBox machine
    -b : power on and boot machine
    -p : power off machine
    -h : this message.
Posted in Technology, Virtualization Tagged with: , ,

Clone a VirtualBox Disk

  1. Get a list of drives first

    VBoxManage list hdds
  2. Clone the desired drive using the UUID:

    VBoxManage clonehd 3ce7cfe9-845d-4358-9120-7a46390bcf8c ~/.VirtualBox/HardDisks/newname

     

Posted in Technology, Virtualization Tagged with: , , ,

pm_tick Panics

If your virtualized cluster panics with the following:


Sep  8 09:18:10 node1 genunix: [ID 898738 kern.notice] Aborting node because pm_tick delay of 5492 ms exceeds 5050 ms

This is common when using Solaris Cluster in a virtual machine. The following may help the issue:


root@node1 # scconf -cw heartbeat_timeout=60000
root@node1 # scconf -cw heartbeat_quantum=10000
Posted in Solaris Cluster, Technology Tagged with: , ,

scinstall Reboot Fails

If the first node fails a reboot after scinstall completes with the following errors, read on for the fix:


Jan 27 11:52:50 node1 genunix: WARNING: CCR: Invalid CCR table : rgm_rt_SUNW.LogicalHostname:4 cluster global.
Jan 27 11:52:50 node1 genunix: WARNING: CCR: Invalid CCR table : rgm_rt_SUNW.SharedAddress:2 cluster global.
...
Jan 27 11:53:55 node1 Cluster.RGM.global.rgmd: [ID 349049 daemon.alert] CCR reported invalid table rgm_rt_SUNW.LogicalHostname:4; halting node
Jan 27 11:53:55 node1 Cluster.RGM.global.rgmd: [ID 349049 daemon.alert] CCR reported invalid table rgm_rt_SUNW.SharedAddress:2; halting node

The fix is to boot the node outside of cluster and repair the directory table:


cd /etc/cluster/ccr/global
vi directory

You want to remove these two lines:


rgm_rt_SUNW.LogicalHostname:4
rgm_rt_SUNW.SharedAddress:2

Save the file and bless it:


ccradm recover -o directory

Reboot back into cluster and proceed. After both nodes have rebooted and are in cluster mode, register these two resource types:


clresourcetype register SUNW.LogicalHostname
clresourcetype register SUNW.SharedAddress
Posted in Solaris Cluster, Technology Tagged with: , ,

Using ZFS in OS X

I recently decided to try out the OpenZFS implementation of ZFS on my mac desktop and so far, I’m impressed. In this post, I’ll cover some of the issues encountered along the way. Let me start by describing my configuration. My desktop is a hack(intosh) with Mavericks installed on two internal 1TB drives. The primary boot drive is partitioned into one big slice and I use CarbonCopy to clone this disk to the second disk. My goal is to migrate my home directories, /Users, to a ZFS mirror and keep OSX on it’s own partition. This is pretty simple with two disks but I thought I would cover the steps here and hopefully help others down the ZFS path. Read more ›

Posted in Mac, Technology Tagged with: , ,

Creating a Bootable USB Stick

  1. Open Disk Utility and make sure any volumes on the USB stick (not the disk) are unmounted.
  2. Use dd select the target disk:
dd if=/path/to/your/downloaded.img of=/dev/disk5 bs=1024
Posted in Mac, Technology Tagged with: , ,

Burn ISO Image

My desktop system is a Mac and I use VMware Fusion to test operating systems and cluster configurations.  Oracle sometimes delivers the Oracle Solaris Cluster software in a tarball so here’s how to burn it to an ISO image which can then be mounted inside the virtual machine:

hdiutil makehybrid -iso -udf -joliet -o solaris-cluster-3_3u1-ga-x86.iso solaris-cluster-3_3u1-ga-x86
Posted in Mac, Technology Tagged with: , , , ,

Quick Chicken Gumbo

Ingredients

  • 1 package frozen gumbo-style vegetables, 16 oz, a mixture of okra, peppers and onions.
  • 29 oz canned diced tomatoes, with mild chiles.
  • 12 oz refrigerated grilled chicken breast fillet, cubed, about 3 cups.
  • 1 Tbsp all-purpose flour
  • 1 tsp Creole seasoning

Instructions

  • Coat a large skillet with nonstick cooking spray. Add vegetables and saute over high heat, stirring frequently, for 2 minutes. Stir in flour and cook 1 more minute. Stir in tomatoes, chicken, and Creole seasoning. Cook over medium heat, stirring frequently, until hot, about 6 minutes. Yields about 1 1/2 cups per serving.

Servings: 4

Notes

  • 4 points per serving
  • Cooking time around 20 minutes
Posted in Recipe

Peanut Brittle

  • Step One Ingredients
    • 2 Cups sugar
    • 1 Cup corn syrup
    • 1/2 Cup hot water
  • Step Two Ingredients
    • 2 Cups (10 oz) raw Spanish peanuts
  • Step Three Ingredients
    • 1 teaspoon salt
    • 2 teaspoon baking soda
    • 2 tablespoon butter
    • 2 teaspoon real vanilla

Preparation:

In a medium size saucepan, combine the “Step One” ingredients. Bring to a boil over a medium to medium-high heat.

In another container, such as a Pyrex measuring cup, combine the salt and butter. Microwave the mixture to melt the butter and dissolve the salt before adding the baking soda and vanilla.

Cook the sugar mixture around 20 minutes until it changes color slightly and the mixture will stream from your spoon around a foot when raised above the pan. The string should be as fine as a hair and will string a foot before breaking. Add peanuts and cook until peanuts are browned (around 3-8 min). Don’t over-cook the peanuts as they will brown a little more after the mixture is poured out to cool.

Get a long spoon! I like to use a long wooden spoon for this next step. You want a long spoon because you will burn your hand from the steam when the “Step Three” ingredients are added.

Stir the “Step Three” mixture well and pour into sugar mixture. STIR LIKE CRAZY (with long spoon) and remove from heat. Stir briskly for 30 to 60 seconds or so.

Pour out into 9×14 pan. I suggest a new “Bakers Secret” pan because I’ve never had any problems with the candy sticking. Cool as fast as possible! A snow bank works well for this.

Posted in Recipe