Category:
JasperServer (JS) builds on JasperReports (JR) as a comprehensive family of Business Intelligence (BI) products, providing robust static and interactive reporting, report server, and data analysis capabilities. For business intelligence users, Jaspersoft offers JasperAnalysis, which runs seamlessly on JasperServer.
Note: This blog is updated based on JS-3.5 GA release
Last updated: 2009-05-08 16.00 GMT+8
What's New in JasperServer 3.5
JasperServer now includes these features:
- Upgrade Mondrian to 3.0
- Dimension sharing within a cube
- Support for dozens of new scalar functions in MDX
- New JasperAnalysis UI
- Improved look and feel as well as an improved tool bar within analysis views.
- Encrypt JDBC password
- Export/Import now supports encryption of JDBC passwords
- Configurable Scheduler Intervals
- The admin can decide which recurrence options are displayed to users by editing the recurrenceIntervalUnits bean in the WEB-INF/flows/reportJobBeans.xml.
- Support for Gantt Charts in JasperReports
- JasperReports, the Java reporting library at the heart of JasperServer now supports Gantt charts.
- Revamped user and role pages
- Includes support for large numbers of users, including search.
- XML-based Chart Themes
- iReport includes the ability to create and edit chart theme in a visual editor.
- Font Extensions
- JasperReports leverages its existing extension support to allow the use of TTF files in report templates without installing them into the system; the same logical font name can be resolved into different TTF files depending on the locale, covering multiple languages.
- Multiple Scriplets per Report and Report Governors
- JasperReports now allows multiple scriplet instances per report template. Some such scriptlets can be declared globally to act as report governors, preventing invalid report layouts from causing infinite loops when the report is filled. JasperServer also provides default governor implementations that limit report execution based on a maximum number of pages and/or timeout.
System requirements
In order to install JasperServer, you need to setup and configure the following application.
- Apache Tomcat (with JDK1.6 or JDK1.5) - to be use as Java container
- PostgreSQL 8.3 - to be use to store JasperServer metadata files
- PostgreSQL 8.3 JDBC Driver - Download correct JDBC driver based on PostgreSQL and Java version
Note: You may use JBoss and MySQL as an alternative to the above application.
How to install JasperServer?
JasperServer installation is very easy as no complicated process involved. In this guide, we will use the stand-alone WAR file distribution. Follow the step-by-step below to complete the installation.
A. Download and Unpack JasperServer file
The WAR file distribution comes in a ZIP file format. Please download the file from www.jasperforge.com. Once you have downloaded the WAR file distribution, you need to unpack it in order to access the contained files. Go to any working directory location to unpack the ZIP file.
user@server:~# unzip jasperserver-3.5-bin.zip user@server:~# ls apache-ant docs jasperserver.war js-installer-version.txt license.txt releaseNotes.txt samples scripts
B. Setup the JasperServer database
- Connect to the PostgreSQL database and create a user for JasperServer. In this document, we will use "jasperadmin" as JS database user with the password is "dbpassword".
- Create a database for JasperServer with jasperadmin as database owner and UTF-8 encoding. In this example, we will use "prd_jasperserver" as database name.
- Connect to the JasperServer database
- Create the schema for JasperServer (Refer attached file). If you already have the database dump, please skip the steps below.
- Populate the database with default user login credential.
postgres> CREATE USER jasperadmin PASSWORD 'dbpassword';
postgres> CREATE DATABASE prd_jasperserver OWNER jasperadmin ENCODING 'UTF-8';
postgres> \c prd_jasperserver prd_jasperserver>
prd_jasperserver> \i js-3.5-create-schema.sql
prd_jasperserver> \i js-3.5-create-default-security.sql
C. Install/Deploy JasperServer into Tomcat
Because the JasperServer is stand-alone JSP files, the installation process involves dropping the files into the webapps directory of the Tomcat server. If you decided to use JasperServer as default page, then you should put the files into ROOT directory.
user@server:~# cd $TOMCAT_ROOT/webapps user@server:~# mkdir jasperserver user@server:~# cd jasperserver/ user@server:~# jar xvf /home/user/jasperserver.war user@server:~# ls cal images j openflashchart wcf externalResource.htm index.htm jpivot scripts WEB-INF favicon.ico inputControl.htm META-INF stylesheets
Allocate static memory for Tomcat (Java). The default memory is not enough to extract data which is more than 1000 records (estimation only). To do this, edit the $TOMCAT_ROOT/bin/setclasspath.sh and add the following lines at the end of file.
JAVA_OPTS="$JAVA_OPTS -Xms512m -Xmx512m -XX:PermSize=32m -XX:MaxPermSize=128m -Xss2m -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -XX:+CMSPermGenSweepingEnabled "
Note: It is best to allocate the same amount RAM for Xms (min) and Xmx (max). Change the value based on total memory installed on the machine.
D. Edit configuration files
There are few configuration files that need to edit. The list of files and its contents as below:
- $JASPER_ROOT/META-INF/context.xml
- $JASPER_ROOT/WEB-INF/hibernate.properties
- $JASPER_ROOT/WEB-INF/js.quartz.base.properties
- $JASPER_ROOT/WEB-INF/js.quartz.properties
<Context path="/jasperserver" antiJARLocking="true" debug="5" reloadable="true" crossContext="true"> <Resource name="jdbc/jasperserver" auth="Container" type="javax.sql.DataSource" maxActive="100" maxIdle="30" maxWait="10000" username="jasperadmin" password="dbpassword" driverClassName="org.postgresql.Driver" url="jdbc:postgresql://localhost:5432/prd_jasperserver" defaultAutoCommit="false"/> </Context>
metadata.hibernate.dialect=com.jaspersoft.hibernate.dialect.PostgresqlNoBlobDialect
metadata.hibernate.dataSource.jndiName=jdbc/jasperserverorg.quartz.scheduler.instanceName=JasperServerScheduler org.quartz.threadPool.threadCount=20 org.quartz.threadPool.threadPriority=5 org.quartz.jobStore.misfireThreshold=180000
quartz.delegateClass=org.quartz.impl.jdbcjobstore.PostgreSQLDelegate quartz.tablePrefix=QRTZ_ quartz.extraSettings= report.scheduler.mail.sender.host=smtp.raj2u.net report.scheduler.mail.sender.username=username report.scheduler.mail.sender.password=password report.scheduler.mail.sender.from=jasper@raj2u.net report.scheduler.mail.sender.protocol=smtp report.scheduler.mail.sender.port=25 report.scheduler.web.deployment.uri=http://localhost:8080/jasperserver
Note: Don't forget to put all the required JDBC drivers in $TOMCAT_ROOT/lib or $TOMCAT_ROOT/common/lib
Now you may start the Tomcat and check the Tomcat's log file to see that there are not serious errors on the startup. If JasperServer started up properly, you should be able to login. Login by going to the following URL: http://host-address:port/jasperserver. The default username is "jasperadmin" and the password is "mypassword". The user credential can be found in the attached file (js-3.5-create-default-security.sql). FYI, the password encryption is already enabled by default in JasperServer 3.5, therefore the password in database is encrypted.
Note: JasperServer Customization (How-To) has been moved to new page.
References
For more information on the installation guide and troubleshooting, please visit http://wwww.jasperforge.org
| Attachment | Size |
|---|---|
| 5.78 KB | |
| 3.58 KB |
Comments
I can't login to jasperserver
I can't login to jasperserver web-application with login 'jasperadmin' and password 'mypassword'. In log I have such error:
11:10:51,565 WARN LoggerListener,http-8080-3:55 - Authentication event AuthenticationFailureBadCredentialsEvent: jasperadmin; details: org.acegisecurity.ui.WebAuthenticationDetails@2cd90: RemoteIpAddress: 192.168.1.10; SessionId: B6897DD4CA70081B84E70F768A32F14F; exception: Bad credentials
Check Password in DB
Hi,
First of all, do you modified the password encryption algorithm? Also, please check the encrypted password key in DB is "A34FAB575B828B127AC85B236B096043"
Hi, I am going through the
Hi,
I am going through the same problem. I have check the encrypted key in DB and it is the same(A34FAB575B828B127AC85B236B096043). I tried to login using the "anonymousUser" user too but it failed. Any more suggestions would be helpfull.
Cheers,
Shez
login problems
Did anyone figure out why you couldn't log on to your Jasper Server. I have the
same exact error. The DB password seems fine for 'jasperadmin/jasperadmin'. 349AFAADD5C5A2BD477309618DCD58B9 is the password in the DB.
I still receive this error:
2010-02-22 15:08:11,811 WARN LoggerListener,http-8081-Processor19:60 - Authentication event AuthenticationFailureBadCredentia
lsEvent: anonymousUser; details: org.springframework.security.ui.WebAuthenticationDetails@ffff6a82: RemoteIpAddress: 192.168.0.1; SessionId: 9E4D5CB578423DDAA5402EE836DE59C7; exception: Bad credentials
The same problem
Hello,
I run into the same problem as mentioned above.
Any help will be appreciated.
Cheers,
Cristian
Using JS RC?
Hi,
This guide is written / updated based on latest SVN code on 2009-04-07. So, what version of JS 3.5 you using? If you are using the RC version, then you need to enable the password encryption. This option enabled by default in latest source code, so in final GA release it should enabled also.
To enable the password encryption, follow the guide in http://www.raj2u.net/jasperserver-installation-on-linux.html - look for section "A. How to enable password encryption?"
Unable to login
I'm still unable to login in Jasper server.
I have version 3.5RC downloaded as a ZIP file. I follow installation instructions, I run the two scripts attached and I enabled password encryption.
<bean id="daoAuthenticationProvider" class="org.acegisecurity.providers.dao.DaoAuthenticationProvider">
<property name="userDetailsService"><ref bean="internalUserAuthorityService"/></property>
<property name="passwordEncoder"><ref local="passwordEncoder"/></property>
</bean>
<bean id="passwordEncoder" class="com.jaspersoft.jasperserver.api.metadata.common.service.impl.PasswordCipherer">
<property name="allowEncoding"><value>true</value></property>
<property name="keyInPlainText"><value>false</value></property>
<property name="secretKey"><value>0xC8 0x43 0x29 0x49 0xAE 0x25 0x2F 0xA1 0xC1 0xF2 0xC8 0xD9 0x31 0x01 0x2C 0x52 0x54 0x0B 0x5E 0xEA 0x9E 0x37 0xA8 0x61</value></property>
<property name="secretKeyAlgorithm"><value>DESede</value></property>
<property name="cipherTransformation"><value>DESede/CBC/PKCS5Padding</value></property>
</bean>
Still I was unable to login. Does anybody have a clue?
Thanks in advance
JasperServer GA
I will review my blog based on latest JS-3.5 GA release.
EDIT: I just downloaded the latest JS and follow my instruction to install, and successfully install and login to the JS. Im not sure what is the problem at your side. Perhaps can you try reinstall again?
Adding new fields to login page
Hi,
While I have been able to customize the JasperServer to use existing iBatis/Struts infrastructure and integrate authentication using existing app, there is one thorn. How can I change the login page to accept another field? Say I want user to enter Domain in addition to username and password. And use the three to authenticate and eventually show reports. I have been able to write my custom Dao that validates jasper user from my DB, but how do I get new attribute - domain to reach my Dao, so that it can be used to authenticate the user?
Thx
Re: Adding new fields to login page
While customizing the login page to accept additional fields is straightforward - you just need to modify login.jsp and make it your login page - making the new values reach \'some Java handler\' is an issue.
Appreciate inputs on this.
Thx
Problem with tomcat jasperserver war
Hi,
thanks for the great install guide! I need some basic information on the tomcat configuration on debian linux because I always get errors like AccessDenied... logging...
So it looks like basic permission problem with tomcat. Can anyone give me hints on how to configure jasperserver (I think logging is the problem)?
many thanks
You might need to set proper
You might need to set proper file permission for Tomcat. Tomcat run as which user? Make sure that user have r+w to the tomcat's logs / cache folder.
To be more specific, please provide the full error stack.
Typo ... ?
Thanks for the very useful tutorial.
I think that there is a typo in the database creation commands: shouldn'it be jasperserver instead of prd_jasperserver? Otherwise I think that you should also change it in the configuration file.
The actual context.xml I have has some additional content (foodfarm ...): I changed them in the same way as the one you propose: is this correct?
I think that the tutorial would be even nicer if you would provide the modified configuration file ready for use (in a way similar to the scipts that you already provide).
Thanks again,
Hi, Actually i use
Hi,
Actually i use "prd_jasperserver" as DB name for my guide. We can always use different name, provided we change the name accordingly in context.xml file as well.
Yes, the actual context.xml file will have additional contents (foodmart / sugarcrm) - which is actually the sample data. In my case, i dont populate those sample data into database, therfore i have removed from my context.xml file.
Modified file?? I already provide in my guide (Section D - Edit configuration files). That is my actuall content of those files, you may just copy-paste it.
http://localhost:8080/jasperserver
Hi,
As per my bussiness requrement i have installed the jasperserver, i want access url: http://localhost:8080/jasperserver to
http://localhost:8080/mycompany
Can you please advice me.
Thanks,
Mruali
Hi, You can change the name
Hi,
You can change the name when deploy the JasperServer in Tomcat (Refer step C). In fact, you can have JS run as main web as http://localhost:8080/
Add new comment