## OWB 11.1 on an 10.2 database with ‘Split Repositories’

13 11 2009

I’m currently working for a customer that is using OWB 10.2.0.1 and a 10.2.0.4 database. All on Windows. Not the best environment in my humble opinion, but hey, it is a customer. They can decide that.

We were having some problems with OWB that have been solved in OWB 10.2.0.4 but also in 11.1.0.6. In other words, we had to do some migration. Because Oracle 11g is the way to go (there were more business-like terms used to persuade the business to accept this decision of course), we decided to skip OWB 10.2.0.4 and start using OWB 11.1.0.6. The DBA’s were not ready to start using database 11g so we also decided to stay on 10.2.0.4 with the database. This means you have to do some extra steps in your database to get OWB 11 running. Perfectly documented in this part of the administration guide for OWB. Worked like a charm.

The difficulties came later on. We have an architecture that looks very much like the Split Repositories Implementation in the same manual. In the said architecture there is only one control center service running, according to the manual. And it is running against the run-time environment. If I tried that I could not deploy from my design repository to my run-time environment and if I stopped the control center service against the run-time environment I could not run any mappings.

So why not start two control center services? One in the design environment and one in the run-time environment. I tried that, but I ran into some obscure java errors that said ‘a file could not be opened because it is in use by another program’. Just that: a file. Not a name, not a directory, just a file. Period. Time to go file hunting.

I imagined it to be a log file of OWB that was opened by the control center service. Both services were using the same OWB_HOME so I went looking there. In <OWB_HOME>/owb/admin/log where 2 files clearly related to the control center service. One was a log file (OWBSYS.LOG) that I traced to a setting in the run time parameters table of the repository owner. The table is owned by owbsys and is called wb_rt_platformproperties. Look for a property_path with value “property.RuntimePlatform.0.messages” and “property.RuntimePlatform.0.errors”. They both have the default property_value “%RTHOME%\owb\log\OWBSYS.log”. I changed these parameters so both control center services would use a different log file. Indeed they did if I started one service, stopped it, started the other service. But if I started both services I still got the ‘file already in use’ message. I left the setting for the parameter because I like to get different log files for different services and went hunting further.

The next log file is created when starting the service with <OWB_HOME>\owb\bin\win32\run_service.bat (or the shortcut to it in the programs menu -> Oracle -> Warehouse Builder -> Administration -> Start Control Center Service). In this bat-file the output of the bat-file itself is sent to a log file using redirection (the >run_service.log at the end of the command). I first started one control center service then changed the bat-file so it would log to a different file and then started the second control center service. And lo and behold, I got me two running control center services.

# Eureka!

I then had to do some fiddling to the bat-file because I did not want to change the log file every time I had to start the services. In Unix or Linux this is easy. You just add date “+%Y%d%m_%H%M%S” to the name of the file and you get an unique file name every time you start. On Windows this is not so easy. I googled around a bit and found some rather complex bat-files that seemed to work if I started them from the command line but worked differently when using the shortcut. It can probably be solved by someone more savvy than me in the wonders of cmd bat files but I decided to take the easy way out. I used the following bat file to find the number of log files that where already present. Add 1 to that count and append the file name with the resulting count. Now my control center services start every time! Even with split repositories.

This is how the bat file now looks (changed parts in bold and italic, you probably have to scroll a bit to see all changes):

@echo off
set STARTUP_TYPE=%1
shift
set NODEID=%1
shift
set RTHOME=%1
shift
set RTUSER=%1
shift
set HOST=%1
shift
set PORT=%1
shift
set SERVICE=%1
shift
pushd %RTHOME%\owb\bin\win32\
set JVM_OPTIONS=-Xmx768M
set JAVAPATH=%RTHOME%\jdk
set OWB_HOME=%RTHOME%
set JDK_HOME=%JAVAPATH%
set ORA_HOME=%RTHOME%
set OEM_HOME=%RTHOME%
set IAS_HOME=%RTHOME%
set ORACLE_HOME=%RTHOME%
set PATH=%RTHOME%\bin;%JAVAPATH%\jre\bin\client;%JAVAPATH%\jre\bin;%RTHOME%\owb\bin\adminrem if exist ..\..\..\owb\lib\int\rtpplatform.jar goto check_common
rem echo cannot find rtpplatform.jar, exiting
rem goto exitrem :check_common
rem if exist ..\..\..\owb\lib\int\rtpcommon.jar goto run_service
rem echo cannot find rtpcommon.jar, exiting
rem goto exit
rem :run_service
:: aanpassing om control center service voor 2 db's op dezelfde machine te laten lopen
set tel=0
for /f "tokens=*" %%a in ('dir %RTHOME%\owb\log\run_service*.log /B/A-D') do set /a tel+=1
set /a tel+=1
SET RUNSRVCLOG=%RTHOME%\owb\log\run_service_%tel%.log
%JAVAPATH%\jre\bin\javaw.exe %JVM_OPTIONS% -DORACLE_HOME="%RTHOME%" -DOCM_HOME="%RTHOME%" -DOCM_ORACLE_HOME="%RTHOME%" -classpath %RTHOME%\owb\bin\admin\;%RTHOME%\owb\bin\admin\launcher.jar -DOWB_HOME=%OWB_HOME% -DJDK_HOME=%JDK_HOME% -DORA_HOME=%ORA_HOME% -DOEM_HOME=%OEM_HOME% -DIAS_HOME=%IAS_HOME% Launcher %RTHOME%\owb\bin\admin\owb.classpath oracle.wh.runtime.platform.service.Service %STARTUP_TYPE% %NODEID% %RTUSER% %HOST% %PORT% %SERVICE%  &gt; %RUNSRVCLOG%
:exit
popd


This is how the bat file used to look:

@echo off
set STARTUP_TYPE=%1
shift
set NODEID=%1
shift
set RTHOME=%1
shift
set RTUSER=%1
shift
set HOST=%1
shift
set PORT=%1
shift
set SERVICE=%1
shift
pushd %RTHOME%\owb\bin\win32\
set JVM_OPTIONS=-Xmx768M
set JAVAPATH=%RTHOME%\jdk
set OWB_HOME=%RTHOME%
set JDK_HOME=%JAVAPATH%
set ORA_HOME=%RTHOME%
set OEM_HOME=%RTHOME%
set IAS_HOME=%RTHOME%
set ORACLE_HOME=%RTHOME%
set PATH=%RTHOME%\bin;%JAVAPATH%\jre\bin\client;%JAVAPATH%\jre\bin;%RTHOME%\owb\bin\adminrem if exist ..\..\..\owb\lib\int\rtpplatform.jar goto check_common
rem echo cannot find rtpplatform.jar, exiting
rem goto exitrem :check_common
rem if exist ..\..\..\owb\lib\int\rtpcommon.jar goto run_service
rem echo cannot find rtpcommon.jar, exiting
rem goto exit
rem :run_service
%JAVAPATH%\jre\bin\javaw.exe %JVM_OPTIONS% -DORACLE_HOME="%RTHOME%" -DOCM_HOME="%RTHOME%" -DOCM_ORACLE_HOME="%RTHOME%" -classpath %RTHOME%\owb\bin\admin\;%RTHOME%\owb\bin\admin\launcher.jar -DOWB_HOME=%OWB_HOME% -DJDK_HOME=%JDK_HOME% -DORA_HOME=%ORA_HOME% -DOEM_HOME=%OEM_HOME% -DIAS_HOME=%IAS_HOME% Launcher %RTHOME%\owb\bin\admin\owb.classpath oracle.wh.runtime.platform.service.Service %STARTUP_TYPE% %NODEID% %RTUSER% %HOST% %PORT% %SERVICE%  &gt; %RTHOME%\owb\log\run_service.log
:exit
popd


## Oracle VM

13 11 2007

Interesting and confusing, Oracle now has its own virtualisation software, Oracle VM. Completely free for download it says as of November 14. And free downloads of virtual machines. Oracle VM does not need a host operating system according to the FAQ. But windows runs considerably slower on OracleVM than native on the hardware, of course they are ‘working on it’. More questions than answers here. Let’s see where this is going.

## Installing Oracle 11g Database

23 09 2007

Oracle 11g has been out for a couple of months now and I found me some time to play around a bit.

One thing that immediately sprang out to me is the size of the download, 1,7GB zip file. That’s something different from the promise Oracle made when introducing 10g where you only needed one CD and 15 minutes to install an oracle database. That was key-note stuff, back then. Now not so important anymore, apparently.

I do not have that much hardware available to play around with so it had to be a virtual machine. I had created a CentOS 4.4 VM some months back, so that seemed a logical choice. Of course it is wise to upgrade the installed packages when you have not been using a CentOS recently. So Up2date was the first to start in the VM. I had no trouble in starting it, just that it took quite some time to finish downloading and installing all packages. Another evening of not doing very much, just a lot of waiting.

The time I had to wait however was eventually well spent because it gave others the time to finish the same action and blog about it. All I next had to do is follow in the footsteps of Howard to prepare linux and install oracle. Of course the installation failed when a starter database was to be created because there was not enough disk space in the VM. I am not a unix or linux administrator so that was another evening puzzling and googling about. But I succeeded eventually.

The next install (after removing the original one the’hard’ way) went smoothly, so now I have a virtual machine with a DWH11 and a REPO11 Oracele 11g database. Next up; installing Warehouse builder environment in the Kadenza style.

(tip of the veil; it is installed, but the description will have to wait till after preparing and savouring dinner and watching a ‘supersunday’ of Dutch soccer (AZ-Ajax and PSV-Feijenoord, no 1-4 currently))

## Nothing like a good news aggregator

21 08 2007

If you wait long enough there is always someone somewhere that does exactly what you have planned to do. Eddie Awad did it for me concerning the What’s-new-in-the-latest-and-greatest Oracle release. Now for some time to read it all and finally install Oracle 11g, that I have downloaded too soon to be sure I will install it before the first patches arrive.

10 08 2007

Yesterday over at Eddie Awad’s blog was the first time I read that oracle 11g on Linux is available for download. And the documentation is there as well. I Shamelessly copied the links from Eddie, mainly so I won’t have to find them myself when I find the time to download and install.

Someone has got to do the dirty job :-).

## Everybody knows of course, but Oracle 11g is out

30 07 2007

I have been away on vacation, trying to complete la Marmotte on bicycle and after that, hiking through the alps in the same area. So I missed most of the introduction hype of 11g. Starting to catch up with all of the latest-and-greatest stuff around the blogs I read. I still have to read it myself, but I thought a link to the What’s New in Oracle 11g would be all right for starters.

I have already seen some blogging from people trying the new goodies. Up to now most of it seems to work as advertised. Curious to see if that holds up.

## Always a pleasure to see a light-weight database

19 06 2007

Eddie Awad posted about a new feature provided by Google called Google gears. I don’t know yet what it is about and will look into it later, but Eddie seems to think along the same lines as I do. Somebody has a new feature, Google gears in this case, and says it contains a database. So I (and Eddie) want to know what kind of database that is. Eddie investigated and found enough interesting details that I wanted to make a note of to look into it myself. I don’t know yet where I will be using it, but it’s always useful to have it in your back-pocket, so to speak. And a database where the executable is 359KB is rare these days, to say the least.