I set up a BI server 4.8 on Linux. Every thing works great except this "Error Occurred While getting Resultset" An error occurred while rendering Pivot.jsp. Please see the log for details.
Typically I got this error if I didn't use it for a while. At beginning, I thought this may related to "MySQL connection death after 8 hours". So I used c3p0, but the issue remained.
I downloaded and copied two file under:
/opt/pentaho/biserver-ce/tomcat/webapps/pentaho/WEB-INF/lib/c3p0-0.9.2.1.jar
/opt/pentaho/biserver-ce/tomcat/webapps/pentaho/WEB-INF/lib/mchange-commons-java-0.2.3.4.jar
I edited /opt/pentaho/biserver-ce/pentaho-solutions/system/hibernate/mysql5.hibernate.cfg.xml
<!-- hibernate c3p0 settings -->
<property name="connection.provider_class">org.hibernate.connection.C3P0ConnectionProvider</property>
<property name="hibernate.c3p0.acquire_increment">3</property>
<property name="hibernate.c3p0.idle_test_period">10</property>
<property name="hibernate.c3p0.min_size">5</property>
<property name="hibernate.c3p0.max_size">75</property>
<property name="hibernate.c3p0.max_statements">0</property>
<property name="hibernate.c3p0.timeout">25200</property>
<property name="hibernate.c3p0.preferredTestQuery">select 1</property>
<property name="hibernate.c3p0.testConnectionOnCheckout">true</property>
<!-- end hibernate c3p0 settings -->
Also this only happened when I accessed my database connection. No problem if I use SampleData connection. Also it only happened once. If I tried it again, it worked as expected. And It occurred again next day. Also this seems related to Mondrian data analysis.
I really appreciate if anyone can give me some clue, since I have been struggling on this for long time.
The related log is attached.
Thanks.
09:22:34,388 WARN [ExplicitRules] The Cube 'LargeAccount' relation is not a MondrianDef.Table but rather 'mondrian.olap.MondrianDef$View'.
09:22:34,391 WARN [TemplateUtil] not found: [Measures].[cnt]
09:22:34,421 WARN [ExplicitRules] The Cube 'LargeAccount' relation is not a MondrianDef.Table but rather 'mondrian.olap.MondrianDef$View'.
Warning: Running an XSLT 1.0 stylesheet with an XSLT 2.0 processor
com.tonbeller.jpivot.olap.model.OlapException: mondrian.olap.MondrianException: Mondrian Error:Internal error: Error while executing query [select NON EMPTY {[Measures].[cnt]} ON COLUMNS,
NON EMPTY {([CLC].[All CLCs], [cnt].[All cnts], [MRC_group].[All MRC_groups], [year_month_number].[All year_month_numbers])} ON ROWS
from [LargeAccount]
]
at com.tonbeller.jpivot.mondrian.MondrianModel.getResult(MondrianModel.java:307)
at com.tonbeller.jpivot.olap.model.OlapModelDecorator.getResult(OlapModelDecorator.java:54)
at com.tonbeller.jpivot.olap.model.CachingOlapModel.getResult(CachingOlapModel.java:48)
...........................
at mondrian.rolap.agg.SegmentLoader.loadImpl(SegmentLoader.java:190)
at mondrian.rolap.agg.SegmentLoader.access$000(SegmentLoader.java:49)
at mondrian.rolap.agg.SegmentLoader$SegmentLoadCommand.call(SegmentLoader.java:158)
at mondrian.rolap.agg.SegmentLoader$SegmentLoadCommand.call(SegmentLoader.java:132)
... 5 more
Caused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: The last packet successfully received from the server was 71,258,137 milliseconds ago. The last packet sent successfully to the server was 71,258,720 milliseconds ago. is longer than the server configured value of 'wait_timeout'. You should consider either expiring and/or testing connection validity before use in your application, increasing the server configured values for client timeouts, or using the Connector/J connection property 'autoReconnect=true' to avoid this problem.
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:411)
.......................