Docs Menu
Docs Home
/
MongoDB Ops Manager
/

Manage Ops Manager Hostname and Ports

On this page

  • Override the Ops Manager Hostname
  • Change the Default Port
  • Enable the Health Check Endpoint

Ops Manager must provide a consistent hostname and consistent ports. Follow these procedures to:

  • Override the default hostname for Ops Manager

  • Change the default ports for Ops Manager

  • Enable the health-check endpoints

Note

All of these procedures are optional. You shouldn't need to change these settings unless your Ops Manager Backup Daemons or Ops Manager Application doesn't appear with the correct hostname, or you need to change ports to meet local security concerns.

Ops Manager tries to detect its host's FQDN. There might be times when the Ops Manager hosts select the wrong hostname. If you need to override the hostname that Ops Manager selected, you can set Ops Manager to use a hostname that you specify.

Important

If Ops Manager works as expected from the URL you wanted, you can skip this procedure.

To set the hostname on Ubuntu or Debian hosts:

1
2
  1. Navigate to the <install_dir>/conf/ directory.

  2. Open the mms.conf file as root in your preferred text editor.

    Example

    sudo -H vi /opt/mongodb/mms/conf/mms.conf
3

Add two options with the mms.system.hostname value:

  • JAVA_MMS_UI_OPTS for the Ops Manager Application

  • JAVA_DAEMON_OPTS for the Backup Daemon

Example

These Java options should look similar to this example:

JAVA_MMS_UI_OPTS="${JAVA_MMS_UI_OPTS} -Dmms.system.hostname=opsmanager.example.com"
JAVA_DAEMON_OPTS="${JAVA_DAEMON_OPTS} -Dmms.system.hostname=opsmanager-bkp.example.com"

You can use environment variables on Linux systems to set this value:

JAVA_MMS_UI_OPTS="${JAVA_MMS_UI_OPTS} -Dmms.system.hostname=$(hostname -f)"
JAVA_DAEMON_OPTS="${JAVA_DAEMON_OPTS} -Dmms.system.hostname=$(hostname -f)"
4
  1. In the Ops Manager Application, click the Admin link in the upper right corner of the page.

  2. Click the General tab and then click Ops Manager Config.

  3. Update the URL to Access Ops Manager field to use the value you specified in the Java Options registry value.

    Example

    https://opsmanager.example.com:11800
  4. Click Save.

5

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo /etc/init.d/mongodb-mms restart

You can access the Ops Manager Application from the new URL after Ops Manager restarts.

To set the hostname on Red Hat or CentOS hosts:

1
2
  1. Navigate to the <install_dir>/conf/ directory.

  2. Open the mms.conf file as root in your preferred text editor.

    Example

    sudo -H vi /opt/mongodb/mms/conf/mms.conf
3

Add two options with the mms.system.hostname value:

  • JAVA_MMS_UI_OPTS for the Ops Manager Application

  • JAVA_DAEMON_OPTS for the Backup Daemon

Example

These Java options should look similar to this example:

JAVA_MMS_UI_OPTS="${JAVA_MMS_UI_OPTS} -Dmms.system.hostname=opsmanager.example.com"
JAVA_DAEMON_OPTS="${JAVA_DAEMON_OPTS} -Dmms.system.hostname=opsmanager-bkp.example.com"

You can use environment variables on Linux systems to set this value:

JAVA_MMS_UI_OPTS="${JAVA_MMS_UI_OPTS} -Dmms.system.hostname=$(hostname -f)"
JAVA_DAEMON_OPTS="${JAVA_DAEMON_OPTS} -Dmms.system.hostname=$(hostname -f)"
4
  1. In the Ops Manager Application, click the Admin link in the upper right corner of the page.

  2. Click the General tab and then click Ops Manager Config.

  3. Update the URL to Access Ops Manager field to use the value you specified in the Java Options registry value.

    Example

    https://opsmanager.example.com:11800
  4. Click Save.

5

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo /etc/init.d/mongodb-mms restart

You can access the Ops Manager Application from the new URL after Ops Manager restarts.

To set the hostname on Linux hosts:

1
2
  1. Navigate to the <install_dir>/conf/ directory.

  2. Open the mms.conf file as root in your preferred text editor.

    Example

    sudo -H vi /opt/mongodb/mms/conf/mms.conf
3

Add two options with the mms.system.hostname value:

  • JAVA_MMS_UI_OPTS for the Ops Manager Application

  • JAVA_DAEMON_OPTS for the Backup Daemon

Example

These Java options should look similar to this example:

JAVA_MMS_UI_OPTS="${JAVA_MMS_UI_OPTS} -Dmms.system.hostname=opsmanager.example.com"
JAVA_DAEMON_OPTS="${JAVA_DAEMON_OPTS} -Dmms.system.hostname=opsmanager-bkp.example.com"

You can use environment variables on Linux systems to set this value:

JAVA_MMS_UI_OPTS="${JAVA_MMS_UI_OPTS} -Dmms.system.hostname=$(hostname -f)"
JAVA_DAEMON_OPTS="${JAVA_DAEMON_OPTS} -Dmms.system.hostname=$(hostname -f)"
4
  1. In the Ops Manager Application, click the Admin link in the upper right corner of the page.

  2. Click the General tab and then click Ops Manager Config.

  3. Update the URL to Access Ops Manager field to use the value you specified in the Java Options registry value.

    Example

    https://opsmanager.example.com:11800
  4. Click Save.

5

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo /etc/init.d/mongodb-mms restart

You can access the Ops Manager Application from the new URL after Ops Manager restarts.

Ops Manager uses the ports and health-check endpoints described in Firewall Configuration. The endpoints default to disabled.

To change the ports on Ubuntu or Debian hosts:

1
2
  1. Navigate to the <install_dir>/conf/ directory.

  2. Open the mms.conf file as root in your preferred text editor.

    Example

    sudo -H vi /opt/mongodb/mms/conf/mms.conf
3

When changing the port, ensure that the chosen port is available for use.

By default, Ops Manager uses port 8080. Change the BASE_PORT value to the desired port number.

BASE_PORT=11700

If you want to change the port for Ops Manager connections over TLS, update BASE_SSL_PORT.

4
  1. In the Ops Manager Application, click the Admin link in the upper right corner of the page.

  2. Click the General tab and then click Ops Manager Config.

  3. Update the URL to Access Ops Manager field to use the value you specified in the Java Options registry value.

    Example

    https://opsmanager.example.com:11800
  4. Click Save.

5

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo /etc/init.d/mongodb-mms restart

You can access the Ops Manager Application from the new URL after Ops Manager restarts.

To change the ports on Red Hat or CentOS hosts:

1
2
  1. Navigate to the <install_dir>/conf/ directory.

  2. Open the mms.conf file as root in your preferred text editor.

    Example

    sudo -H vi /opt/mongodb/mms/conf/mms.conf
3

When changing the port, ensure that the chosen port is available for use.

By default, Ops Manager uses port 8080. Change the BASE_PORT value to the desired port number.

BASE_PORT=11700

If you want to change the port for Ops Manager connections over TLS, update BASE_SSL_PORT.

4
  1. In the Ops Manager Application, click the Admin link in the upper right corner of the page.

  2. Click the General tab and then click Ops Manager Config.

  3. Update the URL to Access Ops Manager field to use the value you specified in the Java Options registry value.

    Example

    https://opsmanager.example.com:11800
  4. Click Save.

5

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo /etc/init.d/mongodb-mms restart

You can access the Ops Manager Application from the new URL after Ops Manager restarts.

To change the ports on Linux hosts:

1
2
  1. Navigate to the <install_dir>/conf/ directory.

  2. Open the mms.conf file as root in your preferred text editor.

    Example

    sudo -H vi /opt/mongodb/mms/conf/mms.conf
3

When changing the port, ensure that the chosen port is available for use.

By default, Ops Manager uses port 8080. Change the BASE_PORT value to the desired port number.

BASE_PORT=11700

If you want to change the port for Ops Manager connections over TLS, update BASE_SSL_PORT.

4
  1. In the Ops Manager Application, click the Admin link in the upper right corner of the page.

  2. Click the General tab and then click Ops Manager Config.

  3. Update the URL to Access Ops Manager field to use the value you specified in the Java Options registry value.

    Example

    https://opsmanager.example.com:11800
  4. Click Save.

5

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo service mongodb-mms restart

Invoke the following command:

sudo /etc/init.d/mongodb-mms restart

You can access the Ops Manager Application from the new URL after Ops Manager restarts.

Ops Manager provides an HTTP health-check endpoint. This endpoint is accessed on port 8090 and is disabled by default. Before you enable the endpoint, make sure that another application or process isn't using port 8090 .

To enable the endpoint:

1

Open the mms.conf file with root access. mms.conf is located in the <install_dir>/conf/ directory.

2

To enable the endpoint, remove the # symbol so that the line reads:

DEBUG.PORT=8090

Important

This port is only accessible from localhost (or 127.0.0.1). The port number can be changed from 8090 to another value.

3
4

Back

Configure Firewall to Access Ops Manager