This article records the main steps and failure modes encountered while building OpenNMS from source and deploying a Core and Minion topology.
Prerequisites
- Prepare a machine with at least
8 GBof memory. - Install Java 17.
- Ensure that Maven Central and the required dependency repositories are reachable.
- Use a PostgreSQL version supported by the target OpenNMS release. For the environment described here, that means a version earlier than PostgreSQL 17.
Build OpenNMS from source
Clone the OpenNMS repository, then run the project scripts:
| |
When tests fail during assembly, use:
| |
Keep a custom Maven repository outside the OpenNMS source tree. The assembly process packages source directories, so a repository placed inside the checkout can make the generated archive unexpectedly large.
User and permission failures
If startup scripts report that the configured user does not exist or lacks permissions, review the RUNAS value in the runjava, install, and opennms scripts. For a controlled test environment, it can be set explicitly:
| |
Use a dedicated service account and minimal permissions for a production deployment.
PostgreSQL authentication
A common installation failure is:
| |
This means the installer reached PostgreSQL but did not receive a valid password. Verify the OpenNMS datasource configuration, the database role password, and the matching pg_hba.conf rule. Test the same credentials with psql before rerunning the OpenNMS installer.
Remote debugging
Enable the JVM debug agent on port 8001, then create a Remote JVM Debug configuration in IntelliJ IDEA. Bind the debug listener to a trusted interface only, and restrict the port with a firewall or SSH tunnel because the Java debug protocol must not be exposed publicly.
The OpenNMS web interface is available on port 8980 by default.
Core and Minion deployment
The distributed topology consists of:
- OpenNMS Core for event processing, persistence, alarms, and the web console.
- Minion close to monitored networks for collection and remote execution.
- gRPC for communication between Core and Minion.
The critical checks are:
- Core exposes the configured gRPC endpoint.
- Minion can resolve and reach the Core address.
- Certificates, credentials, and location identifiers match.
- The Minion appears online in the OpenNMS console.
- A test collection or scan can be executed from the expected location.
Treat network reachability, authentication, and location configuration as separate concerns. Verifying them independently makes distributed deployment failures much easier to diagnose.