Monday, April 15, 2013

OBIEE RPD password lost?

Is there a way around if password for OBIEE RPD is lost?

In the days of OBIEE 10g, we had an option in NQSCONFIG.ini file to bypass the authentication by changing authentication type, and setting it to bypass, using the following parameter:



When we save this file, after that RPD will open no matter what user ID / password is specified.

However, this security loophole was plugged in OBIEE 11g. If password for RPD is lost for 11g, starting from scratch might be the only option.

The above loophole can be especially dangerous, if someone can get a copy of production RPD, which points to production databases. It can be used (or misused) to build reports pointing directly to production databases (which does not require someone to know password for production database).


Monday, April 8, 2013

OBIEE 11g Scalling Vs High Availability

Scalling and High Availability go hand in hand, but they are different.

Scalling is used to achieve higher capacity of the system in terms of ability to handle more load, but it may or may not provide high availability.

High Availability on the other hand is achieved through a way of scalling out an installation.

More documentation on this topic available at following link:

http://docs.oracle.com/cd/E28280_01/bi.1111/e10541/part3.htm#BABBHIJB

OBIEE 11g with two RPD? Can we do that?

I get this question asked frequently, that can we deploy two RPDs to OBIEE servers?

Straight answer to that is no we cannot, however the workaround is to build two BI stacks if there is a need. For example, HR and Finance teams might have different RPD for security reasons. In most of these cases, there will also be a need to have separate development or maintenance teams. Thats why two BI stacks will make sense. In rest of the cases, a multi user development env (MUD) might be enough.

Saturday, April 6, 2013

OBIEE services 11g on windows does not start

So I installed OBIEE 11.1.1.6.0 on windows, everything worked well after installation was complete.

But first time I restarted windows machine, I entered incorrect weblogic password. Now it just remembers the incorrect password and does not prompt again for right password. I keep getting following error:



#### <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <> <1365250636463>  
#### <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <> <1365250636572>  
####
<> <> <> <1365250636572> weblogic.security.SecurityInitializationException: Authentication denied: Boot identity not valid; The user name and/or password from the boot identity file (boot.properties) is not valid. The boot identity may have been changed since the boot identity file was created. Please edit and update the boot identity file with the proper values of username and password. The first time the updated boot identity file is used to start the server, these new values are encrypted.
at weblogic.security.service.CommonSecurityServiceManagerDelegateImpl.doBootAuthorization(CommonSecurityServiceManagerDelegateImpl.java:959)
at weblogic.security.service.CommonSecurityServiceManagerDelegateImpl.initialize(CommonSecurityServiceManagerDelegateImpl.java:1050)
at weblogic.security.service.SecurityServiceManager.initialize(SecurityServiceManager.java:873)
at weblogic.security.SecurityService.start(SecurityService.java:141)
at weblogic.t3.srvr.SubsystemRequest.run(SubsystemRequest.java:64)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
Caused By: javax.security.auth.login.FailedLoginException: [Security:090304]Authentication Failed: User weblogic javax.security.auth.login.FailedLoginException: [Security:090302]Authentication Failed: User weblogic denied
at weblogic.security.providers.authentication.LDAPAtnLoginModuleImpl.login(LDAPAtnLoginModuleImpl.java:261)
at com.bea.common.security.internal.service.LoginModuleWrapper$1.run(LoginModuleWrapper.java:110)
at com.bea.common.security.internal.service.LoginModuleWrapper.login(LoginModuleWrapper.java:106)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at javax.security.auth.login.LoginContext.invoke(LoginContext.java:769)
at javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
at com.bea.common.security.internal.service.JAASLoginServiceImpl.login(JAASLoginServiceImpl.java:113)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.bea.common.security.internal.utils.Delegator$ProxyInvocationHandler.invoke(Delegator.java:57)
at $Proxy39.login(Unknown Source)
at weblogic.security.service.internal.WLSJAASLoginServiceImpl$ServiceImpl.login(WLSJAASLoginServiceImpl.java:89)
at com.bea.common.security.internal.service.JAASAuthenticationServiceImpl.authenticate(JAASAuthenticationServiceImpl.java:82)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.bea.common.security.internal.utils.Delegator$ProxyInvocationHandler.invoke(Delegator.java:57)
at $Proxy57.authenticate(Unknown Source)
at weblogic.security.service.WLSJAASAuthenticationServiceWrapper.authenticate(WLSJAASAuthenticationServiceWrapper.java:40)
at weblogic.security.service.PrincipalAuthenticator.authenticate(PrincipalAuthenticator.java:348)
at weblogic.security.service.CommonSecurityServiceManagerDelegateImpl.doBootAuthorization(CommonSecurityServiceManagerDelegateImpl.java:929)
at weblogic.security.service.CommonSecurityServiceManagerDelegateImpl.initialize(CommonSecurityServiceManagerDelegateImpl.java:1050)
at weblogic.security.service.SecurityServiceManager.initialize(SecurityServiceManager.java:873)
at weblogic.security.SecurityService.start(SecurityService.java:141)
at weblogic.t3.srvr.SubsystemRequest.run(SubsystemRequest.java:64)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
>
####
<> <> <> <1365250636635>  

####
<> <> <> <1365250636635>  

####
<> <> <> <1365250636635>  

####
<> <> <> <1365250636650>  




Solution: 

Edit the boot.properties file located at following path:

C:\MiddleWareHome\user_projects\domains\bifoundation_domain\servers\AdminServer\security

Update the password to right one, and you should be good to go.

Friday, April 5, 2013

How to apply case statements in where clause in OBIEE?

This could be a common reporting scenario and I just wanted to write this post, on how to create a case statement inside of a filter condition. This also works if dashboard has two or more prompts, and they should filter data using a combination of values. For example, consider the following requirement:

You have data for year 2009 and 2010. Per the requirement, you want to select quarter 1 if year is 2009, while you want to select quarter 2 if its year 2010. So, its two different sets of criteria for which data should be selected.

The case statement may be more complex than this example, the solution below will still work.

This is done per the steps below:

1. Add a filter on Year to report.


2. Edit filter > Advanced > convert this filter to SQL



3. In Advanced SQL Filter, type the filter per the expression below:


1 = case
when Date."Report Year" = 2009 and Date."Report Qtr" = 1 then 1
when Date."Report Year" = 2010 and Date."Report Qtr" = 2 then 1
else 0 end




Click results, and verify ..


Viola, it works. We are successfully able to apply a case statement in a filter criteria. This can be used in any further combinations per requirements.

Explanation:

What we are doing in the case statement is that we are bucketing records we want to select as 1, and everything else as 0. Next we have "1 = ". So for every records we bucket as 1, the condition becomes 1 = 1 which is true, while for rest it becomes 1 = 0, which is false, simple?

To demonstrate this, lets take the expression from filter, and add it as a column (remove "1 =" and add rest of the expression) as below:



Hit results:




Clearly you can see, our records are marked as 1, while things to be filtered out are 0.

Here is how BI fires the query for this:

select distinct T1161285.RPT_YEAR as c1,
     T1161285.RPT_MONTH as c2,
     T1161285.RPT_QTR as c3
from
     INVRDM.WC_CALENDAR_D T1161285 /* DIM_WC_CALENDAR_D */
where  ( case  when T1161285.RPT_QTR = 1 and T1161285.RPT_YEAR = 2009 then 1 when T1161285.RPT_QTR = 2 and T1161285.RPT_YEAR = 2010 then 1 else 0 end  = 1 )
order by c1, c3


This is a perfect way to add case statements inside the where clause.

To take is a step forward, now imagine user need to select month and quarter in the prompts. For example user wants to select year 2009 and quarters 1, 2 and 3.

In this case, we will add the year and month as filter and set them to is prompted. This is in addition to the case statement above as shown below: