Reporting server setup

From NetXMS Wiki
Jump to: navigation, search

Prerequisites: Java 1.7+

  1. Create directories (modify locations to your liking):
mkdir -p /opt/netxms-reporting-server
mkdir /opt/netxms-reporting-server/conf
mkdir /opt/netxms-reporting-server/workspace
mkdir /opt/netxms-reporting-server/workspace/definitions
  1. Download and unpack Reporting server binaries:
cd /opt/netxms-reporting-server
wget http://www.netxms.org/download/reporting/netxms-reporting-server-2.0.6.zip
unzip netxms-reporting-server-2.0.6.zip
rm  netxms-reporting-server-2.0.6.zip
  1. Create configuration file:
cd /opt/netxms-reporting-server/conf
vim nxreporting.xml

Sample configuration file:

<config>
  <workspace>/opt/netxms-reporting-server/workspace</workspace>
    <netxmsdConfig>/etc/netxmsd.conf</netxmsdConfig>
    <smtp>
        <server>127.0.0.1</server>
        <from>noreply@netxms.org</from>
    </smtp>
    <netxms>
        <server>127.0.0.1</server>
        <login>admin</login>
        <password>netxms</password>
    </netxms>
</config>
  1. Create additional tables:

Schema for each database type available in GIT: http://git.netxms.org/public/netxms.git/tree/refs/heads/develop:/src/java/nxreporting/sql

wget http://git.netxms.org/public/netxms.git/blob_plain/refs/heads/develop:/src/java/nxreporting/sql/postgres/nxreporting.sql
wget http://git.netxms.org/public/netxms.git/blob_plain/refs/heads/develop:/src/java/nxreporting/sql/postgres/quartz.sql
nxdbmgr batch nxreporting.sql
nxdbmgr batch quartz.sql
  1. Add sample report definition:
cd /opt/netxms-reporting-server/workspace/definitions
wget https://alk.lv/alarm-resolution-time-1.0.0.jar
  1. Configure and restart NetXMS server:
nxdbmgr set EnableReportingServer 1
service netxmsd restart
  1. Run reporting server:
cd /opt/netxms-reporting-server
java -jar reporting-server-2.0.6.jar

In under 30 seconds NetXMS should establish connection with reporting server. Open Management Console and select perspective "Reporting", sample report "Alarm Resolution Time" should be listed on the left.