Wednesday, March 27, 2013

OBIEE 11g Starting and Stopping  Services on LINUX

I mostly get to play around with OBIEE on Linux at home. Clients are only running it on Windows now. 

I suppose that's due, partially, to the Admin tool running on Windows only and for some, it might just be the comfort level. I've been running on Ubuntu for the last couple of years and I'm definitely more comfortable in that environment. I guess I'm no long scared of it, that's the biggest thing.

Since I don't run it all that often, I tend to forget the scripts to run (and the order) to start up the services.

On the Windows side, there's one "script" to run which can be done from the Start --> Programs bar. Easy.

Here's how you do it on Linux (Oracle Enterprise Linux in my case).

cd into your FMW_HOME:
[oracle@demo ~]$ cd /bishiphome/Middleware
Then cd into user_projects/domains/bifoundation_domain/bin
[oracle@demo Middleware]$ cd user_projects/domains/bifoundation_domain/bin
There you'll find the following:
[oracle@demo bin]$ ls -la
total 68
drwxr-x---  5 oracle oracle  4096 May 11 10:30 .
drwxr-x--- 17 oracle oracle  4096 May 18 23:52 ..
drwxr-x---  2 oracle oracle  4096 May 11 10:29 nodemanager
-rwxr-x---  1 oracle oracle  2003 May 11 10:30 secureWebLogic.sh
drwxr-x---  2 oracle oracle  4096 May 11 10:29 server_migration
drwxr-x---  2 oracle oracle  4096 May 11 10:29 service_migration
-rwxr-x---  1 oracle oracle 19359 May 11 10:55 setDomainEnv.sh
-rwxr-x---  1 oracle oracle  3165 May 11 10:55 setOBIDomainEnv.sh
-rwxr-x---  1 oracle oracle  3219 May 11 10:55 startManagedWebLogic.sh
-rwxr-x---  1 oracle oracle  5697 May 11 10:55 startWebLogic.sh
-rwxr-x---  1 oracle oracle  2439 May 11 10:55 stopManagedWebLogic.sh
-rwxr-x---  1 oracle oracle  2125 May 11 10:55 stopWebLogic.sh
First up, startWebLogic.sh
[oracle@demo bin]$ ./startWebLogic.sh 
SVR_GRP = 
using default 32-bit Oracle JVM memory args
.
.
JAVA Memory arguments: -Xms256m -Xmx512m
.
WLS Start Mode=Production
.
classpath and path being set
***************************************************
*  To start WebLogic Server, use a username and   *
*  password assigned to an admin-level user.  For *
*  server administration, use the WebLogic Server *
*  console at http://hostname:port/console        *
***************************************************
starting weblogic with Java version:
java version "1.6.0_24"
Java(TM) SE Runtime Environment (build 1.6.0_24-b07)
Oracle JRockit(R) (build R28.1.3-11-141760-1.6.0_24-20110301-1430-linux-ia32, compiled mode)
Starting WLS with line:
...
more stuff here...
...
You'll be prompted for the username and password you entered upon installation
...
...
Lots more stuff here and finally you'll see these lines
<Jul 31, 2011 11:07:18 AM PDT> <Notice> <WebLogicServer> <BEA-000329> <Started WebLogic Admin Server 
"AdminServer" for domain "bifoundation_domain" running in Production Mode> 
<Jul 31, 2011 11:07:18 AM PDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to RUNNING> 
<Jul 31, 2011 11:07:18 AM PDT> <Notice> <WebLogicServer> <BEA-000360> <Server started in RUNNING mode>
I'll usually set the title for this terminal so I can tell which window is doing what. 



Now I open up a new terminal window and navigate to the same directory, this time, I'm running startManagedWebLogic.sh also known as the node manager.
[oracle@demo bin]$ ./startManagedWebLogic.sh 
Need to set SERVER_NAME and ADMIN_URL environment variables or specify
them in command line:
Usage: ./startManagedWebLogic.sh SERVER_NAME {ADMIN_URL}
for example:
./startManagedWebLogic.sh managedserver1 http://demo.us.oracle.com:7001
Oops, forgot those. Try again:
[oracle@demo bin]$ ./startManagedWebLogic.sh bi_server1 http://localhost:7001
SVR_GRP = 
using default 32-bit Oracle JVM memory args
.
.
JAVA Memory arguments: -Xms256m -Xmx512m
.
WLS Start Mode=Production
.
...blah blah blahweblog
Again prompted to enter the weblogic username and password.

Set the Title of the Window to "Node Manager" like I did for the WebLogic Server.

Open up a 3rd window and I need to navigate to a different directory.
[oracle@demo ~]$ cd /bishiphome/Middleware/instances/instance1/bin
[oracle@demo bin]$ ls -la
total 56
drwx------  3 oracle oracle  4096 May 11 10:33 .
drwx------ 13 oracle oracle  4096 May 11 10:34 ..
drwxr-x---  2 oracle oracle  4096 May 11 10:33 essbase_ha
-rwx------  1 oracle oracle 44593 May 11 10:33 opmnctl
Now I run the opmnctl
[oracle@demo bin]$ ./opmnctl startall
opmnctl startall: starting opmn and all managed processes...
[oracle@demo bin]$ ./opmnctl status

Processes in Instance: instance1
---------------------------------+--------------------+---------+---------
ias-component                    | process-type       |     pid | status  
---------------------------------+--------------------+---------+---------
coreapplication_obiccs1          | OracleBIClusterCo~ |    4627 | Alive   
coreapplication_obisch1          | OracleBIScheduler~ |    4625 | Alive   
coreapplication_obijh1           | OracleBIJavaHostC~ |    4626 | Alive   
coreapplication_obips1           | OracleBIPresentat~ |    4800 | Init    
coreapplication_obis1            | OracleBIServerCom~ |    4624 | Alive
Not everything has started yet, try again.
[oracle@demo bin]$ ./opmnctl status

Processes in Instance: instance1
---------------------------------+--------------------+---------+---------
ias-component                    | process-type       |     pid | status  
---------------------------------+--------------------+---------+---------
coreapplication_obiccs1          | OracleBIClusterCo~ |    6505 | Alive   
coreapplication_obisch1          | OracleBIScheduler~ |    6511 | Alive   
coreapplication_obijh1           | OracleBIJavaHostC~ |    6504 | Alive   
coreapplication_obips1           | OracleBIPresentat~ |    6503 | Alive   
coreapplication_obis1            | OracleBIServerCom~ |    6502 | Alive 
Yeah.

One thing to note here, you have to wait until the WebLogic Server is in the RUNNING mode before you start the opmnctl components.

Unlike Windows, the Linux version doesn't have a one-stop-shop startup script. I found one in the OTN Forums here. If you can write shell/bash (whatever) scripts, I don't think it would be terribly difficult to do on your own either.

Update
Mark Rittman left a comment (which seems to have disappeared) and hopefully it will show up eventually.

Anyway, his comment forced me to look more closely at what each of the above scripts actually do.

FYI, I stole the instructions for starting up OBIEE from the SampleApp Lite guide that was recently released. Here's a snapshot of the instructions:

1

Looking at startManagedWebLogic.sh, it actually calls startWebLogic.sh.

The NodeManager script is located in the <FMW_HOME>/wlserver_10.3/server/bin directory.




Thanks,
Satya Ranki Reddy

No comments:

Post a Comment