Friday Jan 04, 2013

Deploying the OBI Sample Virtual Machine

Cliff Notes:  step-by-step instructions to deploy the virtual machine

Announcement:  A new virtual machine image is being prepared.
Version 303 is in preparation, and will be publicly available soon as version 304.
Enjoy the Version 303 videos prepared by the development staff.

The documentation for the OBI sample application machine is very through and well written.  
It's just a lot of reading if you just want to get started.  
 Here is the short recipe for success.  
 I deployed this on Windows 8.   The VM guest environment includes:

  • Oracle Linux 5 (el5PAE )
  • OBIEE 11.1.6.2 
  • Oracle Database 11g Release 2
  • Oracle Times Ten
  • Essbase Server
  • Access Provisioning Services
  • Oracle JDev
  • Oracle SQL Developer
  • Oracle Internet Directory

Step by step.

  1. Prepare your host system.
    Minimum 4GB of real memory;  more is better.
    Turn on Virtual Assist features in the BIOS.
    73GB disk space needed to install/deploy 
    50GB of free disk space to run

    Download and install Free Download Manager.
    Download and install 7Zip.
    Download and install md5sum

  2. Download and install Oracle VirtualBox ( I used VirtualBox-4.2.6.82870-Win.exe )
    I save the download images to an external USB 3.0 disk

  3. Sign in to the Oracle Tech Network
    click on Oracle Business Intelligence SampleAppV207

  4. click on Downloads and Instructions
    click to accept the OTN license
    Select the V207 version and download:
    - VB Image-Deployment Guide ( where VB means VirtualBox)
    - What's new in V207
    - V207 known issues

  5. Download the virtual image components, one-by-one
    This is where Free Download Manager is useful.  These images are huge.
    While fdm will maintain a queue of downloads, the Oracle Network will start the first download and reject subsquent ones.  
    It took me about 25 minutes per zip file.
    iPhone Clock/Timer kept me focused. I hate it when machines program me.
    VB Image Key File (.ovf) is used to import the VM into VirtualBox
    SampleApp207GA_OBI_BP1.zip.###  ( 001 to 011 )
    Those filenames are correct;  do not rename them. They are part of a "split" archive ... 2GB per segment.

  6. When all zip files are downloaded, unpack them with 7zip.   In a command window:
    7z x SampleApp207GA_OBI_BP1.zip.001
    Result:
    SampleApp207GA_OBI_BP1-disk1.vmdk ( 22GB)
    SampleApp207GA_OBI_BP1-disk2.vmdk ( 1.5MB)

    You can discard the zip files.   I retained them on the USB drive to avoid downloading again.

  7. Start Oracle VMVirtualBox Manager
    Click File / Import Appliance ( Ctrl-I )
    Click Open appliance...
    Select SampleApp207GA_OBI_BP1.ovf  machine definition file
    Check [x] Reinitialize the MAC address of all network cards
    Wait for it to complete.  Your virtual machine is ready.

    Now you can discard the original .vmdk image.  It has been cloned to the new VB location you chose.

  8. Before you start the VM, click on Settings
    System: Motherboard tab
    Select memory size ( I used 4000 MB )
    [x] Enable IO APIC
    [x] Enable absolute pointing device
    System: Processor
    I selected 2 processors
    [x] Enable PAE/NX
    System: Acceleration
    [x] Enable VT-x/AMD-V
    [x] Enable Nested Paging

    Network: Adapter 1
    [x] Enable Network Adapter
      [ Bridged Adapter ]
      Name:   You will likely have to change this if using Wireless. Use the dropdown box to select
      [ Intel(R) Centrino(R) Wireless N-2230 ]
    Network Adapter 2
    [ ] Not enabled

    USB:
    [x] Enable USB Controller
    [x] Enable USB 2.0 Controller
    Click [OK]

  9. Ladies and Germs, Start your VM
    Username [ oracle ]
    Password [ oracle ]

  10. You'll soon discover the mouse doesn't seem to work correctly.
    The reason is that this virtual machine was built on an earlier VB version, and the "Guest Additions for Linux" need to be updated ( See section 4.2.2 in VB User Guide )

    In the top menu, Click "Machine", then "Settings" ( Host+S, where Host means Right-CTRL key)
    Select Storage
    (O) Empty means no CD installed.   We will put a virtual CD ( .iso) here.
    Click Disc icon on the right, Click "VboxGuestAddtions.iso"
    Click [ OK ]  
    You can't correctly launch VBoxLinuxAdditions.run from the file menu; it requires root privilege.
    Minimize the files folder window.
    R-Click an empty spot on the Desktop
    Open Terminal
    $ su     # switch to root user; Password: oracle.
       " #" is the terminal prompt for root ## are my comments
    # cd /media
    # cd VBOX<tab> ## to complete the pathname "VBOXADDITIONS_4.2.6_82870"
    # sh V*.run<tab> ## to complete the file "VBoxLinuxAdditions.run"
    <enter>

    " Removing installed 4.1.2 of VB Guest Additions"

  11. The mouse is much smoother now.
    Click "Applications" / "System Tools" / "Software Updater"

    enter Password for root"  password [ oracle ]
    Click [ Apply updates ]
    Click [ Reboot Now ]

  12. Congratulations.  You just passed your first Linux Administration Certification Exam.
    You are now free to explore the image on your own, while I construct the next section.

  13. Reading Homework.  Explore according to your interests.
    sampleapp207-deploymentguide-1719589.pdf
    VirtualBoxUserManual.pdf
    Linux Blog  See:  Oracle Linux Hands-on Lab from your Home? Yes You Can Do That!

Postscript:  

I just ran through the steps above, and after rebooting the virtual machine, the mouse was jumpy again.

I don't know why this happened, but some VM Settings were changed and I had  the settings ( step 8 above).
System: Motherboard
[x]
Enable IO APIC
[x] Enable absolute pointing device

Storage: CD Controller Change back to Host Drive.  We don't need the Guest Images iso.

3.2 Configuring Hosts File

The description in this section is incorrect.  Order is important in the /etc/hosts file.
The original file used for testing this VM is very likely:  /etc/hosts_orig
It contains the machine name at the bottom, leaving the original local host name in place ( 127.0.0.1)
To provide a real IP, the entry must come before localhosts.
Here is a short script that could be part of machine bootup, that will repair /etc/hosts, depending on the VirtualBox host machine.

#!/bin/bash
# Find my IP address, my ID.
myHost=$(uname -n)
myID=$(whoami)
myIP=$(ifconfig -a | grep 'inet addr:'| grep -v 'addr:127'| tr ':' ' ' | awk '{print $3}')
hostIP=$(grep "^[$myIP]" /etc/hosts )
[ 'root' == $myID ] || SUDO=sudo
if [ -z "$hostIP" ]; then
   [ -e /etc/hosts.orig ] || $SUDO cp -p /etc/hosts /etc/hosts.orig
   $SUDO echo $myIP $myHost   > /etc/hosts.$$
   $SUDO cat /etc/hosts.orig >> /etc/hosts.$$
   $SUDO ln -fs /etc/hosts.$$ /etc/hosts
   ls -l /etc/hosts /etc/hosts.orig
   fi

Other useful Linux tools missing from the VM

# yum install yum-utils   ## Note dash (-), not dot (.) 

Useful aliases in the works

I wrote a "dirstats" script for Solaris to get an overview of a directory I'm unfamilar with.;  
Chris Garber improved the performance.  Here's the results in /home/oracle:

[oracle-AT-obieesampleapp ~]$ dirstats 

      Size    Dirs   Links   Files Path
       59M       1       0       5 apex 
       12M      15       0     110 apex_listener 
       18G    3779      96   41287 app 
      8.0K       0       0       1 bea 
      5.9M       1       0       1 catalogmanager 
      4.0K       0       0       0 data 
      312K      19      16      24 Desktop 
      4.0K       0       0       0 Downloads 
      5.5G    8831      15   81441 epm 
       32M      16       0      96 firefox 
      4.0K       0       0       0 hostshare 
       28K       6       0       1 http: 
       12G   15697      11  176930 obiee 
      2.4G    2582      10   21889 oid 
      1.6M      32       0      52 oradiag_oracle 
       16K       0       0       1 ore 
      4.0K       0       0       0 RCS 
      155M      39       6     118 scripts 
      2.0M       5       0       4 workspace 

 An automated startup script to make this a service appliance.
Mar 4, 2013.

Each of the components in this software stack has a separate startup script, with a numbered entry on the desktop to start in the proper order by clicking the Desktop entry. The shell script launches a terminal shell that observes the launch and pauses to review success or error messages.  

2-StartWLS.sh is different;  you are expected to watch the output of this script run in a terminal session until a message is displayed showing successful launch  and manually place this script in the background so that Web Logic Services stays running.

I needed to automate this step and avoid human interaction so  I used awk to watch for the key line in the output like this, and  then exit the invocation script to proceed to to the next component.   

echo "#--- 2-StartWLS.sh "
set +o noclobber
nohup /home/oracle/obiee/user_projects/domains/bifoundation_domain/startWebLogic.sh >/tmp/wls.out &

tail -f /tmp/wls.out \
| awk '/<Server started in RUNNING mode>/ \
{ echo "\n\n$*\n\n" >/dev/stderr;fflush; exit; }'

The complete script is available here:   start.sh
The companion script to bring services down in the proper order:   stop.sh

Comments are turned off on this blog.   If you have feedback, contact me via email.
dick.dunbar@oracle.com
I promise to simplify and clean this item.

About

Dick Dunbar
is an escalation engineer working in the Customer Engineering & Advocacy Lab (CEAL team)
for Oracle Analytics and Performance Management.
I live and work in Santa Cruz, California.
I'll share the techniques I use to detect, avoid and repair problems.

Search

Categories
Archives
« January 2013 »
SunMonTueWedThuFriSat
  
1
2
3
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
  
       
Today