Skip to main content
Version: 1.0.x.x LTS

Installing nevisAdapt

The installation of the nevisAdapt service includes the following software packages:

Package nameComponentRemarks
nevisadapt-<version>.noarch.rpmnevisAdapt service- Contains an embedded Tomcat servlet container.- Contains the database schema.

Install all software packages with the user "nauser " and the group "nbgroup". As a precondition, this user and group must exist.

File system layout

The table below describes the layout of the nevisAdapt file system:

PathDescriptionType
/opt/nevisadapt/Read-only base directory of the installation, owned by the user "nevisdetect" and group "nevisdetect".Installation directory
/opt/nevisadapt/util/util.shHelper script used during the post-install- and pre-remove-phase of the package.
/opt/nevisadapt/bin/nevisadapt-exec.jarExecutable jar file.
/opt/nevisadapt/bin/nevisadapt-exec.confLink to /var/opt/nevisadapt/conf/nevisadapt-exec.conf
/var/opt/nevisadapt/Read/write directory of the installation, owned by the user "nevisdetect" and group "nevisdetect".Spool directory
/var/opt/nevisadapt/logs/nevisadapt.logLog file(s).
/var/opt/nevisadapt/logs/nevisadapt.stdoutThe system redirects stdout to this file.
/var/opt/nevisadapt/conf/nevisadapt.propertiesnevisAdapt service configuration file.
/var/opt/nevisadapt/conf/riskscore-mapping.propertiesConfiguration file for the risk score mapping.
/var/opt/nevisadapt/conf/nevisadapt-exec.confConfiguration file for the init.d service.
/var/opt/nevisadapt/conf/logback.xmllogback configuration file.
/var/opt/nevisadapt/conf/role-to-permission.propertiesRole-to-permission mapping file.

Database schema

After the installation of nevisAdapt, it is possible to manually create and maintain the database schema, for example with Flyway, an open source database migration tool. See the sample command below:

[root@nevisdetect-dev rpm]# /opt/nevisadapt/flyway/bin/flyway.sh info
Flyway 4.1.2 by Boxfuse

Database: jdbc:oracle:thin:@oravml11.zh.adnovum.ch:41010:DCHNEV01 (Oracle 11.2)

+---------+-------------------+---------------------+---------+
| Version | Description | Installed on | State |
+---------+-------------------+---------------------+---------+
| 1 | nevisAdapt Schema | 2019-01-23 10:48:05 | Success |
+---------+-------------------+---------------------+---------+

By default, nevisAdapt uses the database connection configured in the file /var/opt/nevisadapt/conf/nevisadapt.properties. However, you can also configure the parameters with the command line. Flyway supports the following commands:

NameDescription
migrateMigrates the database.
cleanDrops all objects in the configured schemas.
infoPrints the details and status information about all the migrations.
validateValidates the applied migrations against the ones available on the classpath.
baselineBaselines an existing database, excluding all migrations up to and including the baseline version.
repairRepairs the schema history table.

Supported databases

nevisAdapt supports the following databases:

  • Oracle
  • MariaDB

To load the data types for the Flyway script, perform the following steps:

  1. Determine the database vendor from the JDBC URL (it should contain either the string jdbc:oracle or jdbc:mysql).
  2. Depending on the database vendor, load the data types for the Flyway script either from the flyway_oracle.properties file or the flyway_mariadb.properties file.

If you use MariaDB, you need to set the attribute lower_case_table_names to "1" in the MySQL settings (my.cnf file).

Software package installation - nevisAdapt service

To install the nevisAdapt service, proceed with the next steps.

The installation of the nevisAdapt plug-in is described further below.

  1. Execute the following command to install the component's software package:
rpm -i  nevisadapt-<version>.noarch.rpm

During the installation, the following happens:

  • Registration of the component as init.d service with the name nevisadapt.
  • Creation of the spool directory structure (if not already existing).
  • Extraction of the following files from the file /opt/nevisadapt/bin/nevisadapt-exec.jar:
    • /var/opt/nevisadapt/conf.properties
    • /var/opt/nevisadapt/conf/nevisadapt-exec.conf
    • /var/opt/nevisadapt/conf/logback.xml
  1. Administer the component with the following commands:
service nevisadapt start
service nevisadapt status
service nevisadapt stop
service nevisadapt restart

The configuration of the runtime environment of a service is located in the file nevisadapt-exec.conf.

The following sample code block illustrates the installation of the nevisAdapt service:

# variables used by the exec /opt/nevisadapt/bin/nevisadapt-exec.jar used by init.d
APP_NAME=nevisadapt
JAVA_OPTS="-Xmx1024M -XX:+UseConcMarkSweepGC -Dlogback.configurationFile=/var/opt/nevisadapt/conf/logback.xml"
LOG_FOLDER=/var/opt/nevisadapt/logs
LOG_FILENAME=nevisadapt.stdout

# variables used by the application i.e. logback and spring
export NEVISADAPT_SPOOL_DIR=/var/opt/nevisadapt
export NEVISADAPT_APP_NAME=nevisadapt

Software package de-installation

To de-install the nevisAdapt component, run the following command:

rpm -e nevisadapt-<version>.noarch

During the de-installation, the service is stopped and de-registered. The spool directory is not modified, so a subsequent installation will have the same configuration.

Installing the nevisAdapt plug-in

The installation of the nevisAdapt plug-in is similar to the installation of the other nevisDetect risk plug-ins. For more information about the installation of risk plug-ins in nevisDetect, have a look at the nevisDetect Reference Guide, chapter Installation of nevisDetect Core.