Sunday, 28 August 2016

Configuring OBIEE 11g as Services under Windows Server 2012



1. Check if the MW_HOME environment variable is set.







  • Check Environment variables for MW_HOME  Control Panel -> System -> Advanced System Settings -> Advanced  tab -> Environment Variables -> System variables.
  • Add it to both variables.
2. Restart the machine.

Node Manager

Note: For Node Manager, if you want the component to start automatically on boot up, your best option is to create a Windows Service. You may have selected the option to create a service for Node Manager during the WebLogic Server installation.This service is automatically created with the OBIEE 11g installation on Windows and can be skipped. However please find the below steps if it needs to be configured.

Use Start -> Run -> services.msc from the Start menu to load the Windows Services Manager. If there is no service for Node Manager, use the following steps to create one.
  • ·         WL_HOME\server\bin\installNodeMgrSvc.cmd
  • ·         Verify in Windows Services that a service was created.






Admin Server

For the Admin Server, we have to create a Windows Service. Follow below steps:

  • Browse in to the location and check boot.properties file is present there or not. (D:\MW_HOME\user_projects\domains\bifoundation_domain\servers\AdminServer\security)



This file is already present and has the username and password of the weblogic user in encrypted format. If it is not present, create one. Create a text file named %MIDDLEWARE_HOME%\user_projects\domains\<domainname>\servers\AdminServer\security\boot.properties. Add the following lines:

username=weblogic
password=<the weblogic username password>


2. Create a command script called installAdmServer_Service.cmd which you will want to make sure has lines like:

SETLOCAL
set DOMAIN_NAME=<your wls domain>
set USERDOMAIN_HOME=<path to domain> # e.g., C:\middleware\FMW11g\user_projects\domains\ClassicDomain
set SERVER_NAME=AdminServer
set PRODUCTION_MODE=true
cd %USERDOMAIN_HOME%
call %USERDOMAIN_HOME%\bin\setDomainEnv.cmd
call "<your middleware home>\wlserver_10.3\server\bin\installSvc.cmd"
ENDLOCAL





3. Calling setDomainEnv.cmd sets some environment variables for your domain and also calls the WebLogic common environment script commEnv.cmd.

(Note: If you do customize these scripts in this way, you also need to make a change to the installSvc.cmd script because it also calls commEnv.cmd, so it could overwrite any customizations you may have made to setDomainEnv.cmd. If so comment the below statement.)

Note: Skip this step if no customization is done at your end.
Else navigate to MW_HOME\wlserver_10.3\server\bin\installSvc.cmd, check whether the below line is present:

call "%WL_HOME%\common\bin\commEnv.cmd"

Modify the above line as follows:
@rem call "%WL_HOME%\common\bin\commEnv.cmd"

4. Create a standard out log file for AdminServer and bi_server1.

( Note: For troubleshooting/debugging purposes it is helpful to redirect standard out and error to a text file. Although most information is captured in the AdminServer server log files, you will not see all standard out and error when the server is started via a MS Windows Service (unlike when you start an AdminServer from the command prompt using startWebLogic.cmd)).

To redirect standard out to a text file, backup and edit installSvc.cmd and change the line at the bottom of the file so it includes the -log parameter, e.g.

"%WL_HOME%\server\bin\beasvc" -install -svcname:"%DOMAIN_NAME%_%SERVER_NAME%" -javahome:"%JAVA_HOME%" -execdir:"%USERDOMAIN_HOME%" -extrapath:"%WL_HOME%\server\bin" -password:"%WLS_PW%" -cmdline:%CMDLINE% -log:"<your middleware home>\user_projects\domains\<your wls domain name>\servers\AdminServer\logs\AdminServer-stdout.txt"



5. Install the service. For this select the installAdmServer_Service.cmd, run it as in administrator mode.Once the service is installed, go to services.msc and look of the service name beasvc bifoundation_domain_AdminServer.

6. Go to RUN type "regedit" and you get the Registry Editor. Find
HKEY_LOCAL_MACHINE\SYSTEM\ CurrentControlSet\Services\beasvc bifoundation_domain_AdminServer \ Parameters. Modify the cmdLine parameters values from default values (32,200,128) to (1024,1024,512). (Note: This step is the solution for the error : java.lang.OutOfMemoryError)


 

7. Right click and start the service.
Check the log file in the location
D:\MW_HOME\user_projects\domains\bifoundation_domain\servers\AdminServer\logs
The log file “AdminServer-stdout.txt” would say AdminServer started in "Running mode" in a while (2-3 minutes).

BI Server

1. Browse in to the location and check boot.properties file is present there or not.
D:\MW_HOME\user_projects\domains\bifoundation_domain\servers\bi_server1\security
Create a command script called installbi_server1_Service.cmd which has lines like

username=weblogic
password=<the weblogic username password e.g manager11g>


2. Create a command script called installbi_server1_Service.cmd which has lines like:

SETLOCAL
set DOMAIN_NAME=<your wls domain>
set USERDOMAIN_HOME=<path to domain> # e.g. C:\middleware\FMW11g\user_projects\domains\ClassicDomain
set SERVER_NAME=WLS_FORMS
set PRODUCTION_MODE=true
set ADMIN_URL=http://mymachine.mycompany.com:7001
cd %USERDOMAIN_HOME%
call %USERDOMAIN_HOME%\bin\setDomainEnv.cmd
call "<your middleware home>\wlserver_10.3\server\bin\installSvc.cmd"
ENDLOCAL


3. Calling setDomainEnv.cmd sets some environment variables for your domain and also calls the WebLogic common environment script commEnv.cmd.

(Note: If you do customize these scripts in this way, you also need to make a change to the installSvc.cmd script because it also calls commEnv.cmd, so it could overwrite any customizations you may have made to setDomainEnv.cmd. If so comment the below statement.)

Note: Skip this step if no customization is done at your end.
Else navigate to MW_HOME\wlserver_10.3\server\bin\installSvc.cmd, check whether the below line is present:

call "%WL_HOME%\common\bin\commEnv.cmd"

Modify the above line as follows:

@rem call "%WL_HOME%\common\bin\commEnv.cmd"

4. Install the service. For this select the installbi_server1_Service.cmd, run it as in administrator mode.
Once the service is installed, go to services.msc and look of the service name beasvc bifoundation _domain_bi_server1.

5. Go to beasvc bifoundation_domain_AdminServer à Parameters

Edit the CmdLine parameters values from default values (32,200,128) to (1024,1024,512).

 (Note: This step is the solution for the error : java.lang.OutOfMemoryError)

 

6. Right click and start the service.
Check the log file in the location
D:\MW_HOME\user_projects\domains\bifoundation_domain\servers\AdminServer\logs
The log file “AdminServer-stdout.txt” would say bi_server1 started in Running mode in a while (2-3 minutes).

7. When it is  started as "Running mode" start the Oracle Process Manager (OPMN) either manually or from services.msc.

8. After the starting up of OPMN Services, log in to EM, Console and Analytics and verify the reports and services.

Note: Below steps are to configure the above created services in such a way that if the server machine is restarted for any probable reason in future, the OBIEE services start automatically as system startup services.

Create Groups & Dependencies in the Registry

To ensure the OBIEE service start in the correct order we need to create a group in the windows registry for each service. We then assign each of the four services to these groups and place dependencies on the start order.

1. Open the Registry Editor from ‘Run’ (regedit)





2. Expand and locate HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\ServiceGroupOrder:








3. Double click on the ‘List’ entry and add the following four groups to the end of the value:
  • ·         OBI Node Manager
  • ·         OBI Admin Server
  • ·         OBI Managed Server
  • ·         OBI OPMN









4. Click ‘OK’ to Save.


5. Now locate the Weblogic Node Manager entry under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services  -> Oracle WebLogic Node Manager (D_MW_HOME_wlserver_10.3)

6. Right click on the entry and select New -> String Value





7. Enter the name ‘Group’. Double click on Group and enter the value data as OBI Node Manager.









8. Now repeat this for the other three entries:
  • ·         beasvc bifoundation_domain_AdminServer  with the Group value “OBI Admin Server”.
  • ·         beasvc bifoundation _domain_bi_server1  with the Group value “OBI Managed Server”.
  • ·         OracleProcessManager_instance1 with the Group value “OBI OPMN”.




9. Now we need to setup the dependences to ensure each service wait’s until the previous services have started before starting.

Right click on the beasvc bifoundation_domain_AdminServer entry and select New à Multi-String value. Give it the name DependOnService. Edit the value and enter the name of the node manager service.



10. Now create a DependOnService value for the beasvc bifoundation_domain_bi_server1 and give it the two values:
·         Oracle WebLogic Node Manager (D_MW_HOME_wlserver_10.3)
·         beasvc bifoundation_domain_AdminServer






11. Finally create the DependOnService value for the OracleProcessManager_instance1 with the three values:
·         Oracle WebLogic NodeManager (D_MW_HOME_wlserver_10.3)
·         beasvc bifoundation_domain_AdminServer
·         beasvc bifoundation_domain_bi_server1



Check the Services.

Open up the Services window and scroll down to find the four OBIEE services. You need to make sure all four are set to Automatic startup.  


Restart the Server.

Now shutdown and restart the Server.

(Note: When the server boots all four services should start in the correct order, however be warned that they will take just as long to start as they do when using the standard ‘Start BI Services’ command, however being services there will be no command windows and the services will stay up when you log off. The Services screen is a little confusing because all four services will report a status of ‘Started’ even though they are still loading in the back ground.)

By this restart, the bi services should start as windows services in the order
  • ·         Oracle Node Manager
  • ·         Admin Server
  • ·         BI Server
  • ·         OPMN



 Log in to EM, Console and Analytics and verify the reports and services. We can see that there are no command prompts open related to OBIEE in that active user session. Below Task Manager screen shot indicates OBIEE services are running under System Account.




Reference

No comments:

Post a Comment