Solutions
Archived

Installing OpenAM 13.x with an external OpenDJ instance fails with a NPE

Last updated Jan 5, 2021

The purpose of this article is to provide assistance if installing or configuring OpenAM with an external OpenDJ instance fails with a "Setting up monitoring authentication file.AMSetupServlet.processRequest: errorjava.lang.NullPointerException" error.


Archived

This article has been archived and is no longer maintained by ForgeRock.

Symptoms

The installation fails when attempting to set up the monitoring authentication file.

You can see this failure in the browser if you are configuring OpenAM via the browser:

Checking configuration directory /openam/conf....Success. Reinitializing system properties....Done Configuring server instance....Done Setting up monitoring authentication file. null, refer to install.log under /openam/conf for more information.

The install.log (located in $HOME directory) also shows the same error, with additional details:

Checking configuration directory /openam/conf....Success. Reinitializing system properties....Done Configuring server instance....Done Setting up monitoring authentication file.AMSetupServlet.processRequest: errorjava.lang.NullPointerException at java.net.URLEncoder.encode(URLEncoder.java:205) at com.sun.identity.setup.BootstrapCreator.getBootStrapURL(BootstrapCreator.java:189) at com.sun.identity.setup.BootstrapCreator.update(BootstrapCreator.java:104) at com.sun.identity.setup.BootstrapCreator.updateBootstrap(BootstrapCreator.java:82) at com.sun.identity.common.configuration.ServerConfigXMLObserver.update(ServerConfigXMLObserver.java:108) ...

Recent Changes

Installed, upgraded or reconfigured OpenAM with an external OpenDJ instance.

Causes

The external data store already contains some entries, perhaps from a failed install, which is causing the install to fail.

Solution

This issue can be resolved by removing the old entries from the data store before reinstalling or reconfiguring.

You can do this by importing an LDIF file that just contains the data store root suffix (for example, dc=example,dc=com); this will remove the backend with any entries and replace with the base entry. You can use an import-ldif command such as:

$ ./import-ldif --hostname ds1.example.com --port 4444 --backendID userRoot --includeBranch dc=example,dc=com --ldifFile /path/to/remove.ldif

See Also

OpenDJ Reference › Tools Reference › import-ldif

Related Training

N/A

Related Issue Tracker IDs

OPENAM-1793 (Configurator throws NPE when Setting up monitoring authentication file if there are entries in the data store under the ROOT DN)


Copyright and Trademarks Copyright © 2021 ForgeRock, all rights reserved.