Add Apache HTTP Server
You can add Apache HTTP Server entities using the Add Entity UI or using the cloud agent command line interface (omcli
) with the appropriate JSON files.
Step 1: Prepare Apache HTTP Server for monitoring.
Apache HTTP Server Prerequisites |
---|
In this release, only Apache HTTP Server 2.4.x and 2.2 for Linux are supported. To enable the collection of configuration metrics, note the following:
In order to monitor an Apache HTTP Server you must first:
For more information, see https://httpd.apache.org/docs/2.4/mod/mod_status.html and http://httpd.apache.org/docs/current/mod/core.html#location. For HTTPS/Secure communication between Apache HTTP Server and the cloud agent during metrics collection, you must provide an SSL certificate. To make the certificate available with the cloud agent:
For data retrieval of memory-related metrics (supported on Unix platforms and when an entity is locally monitored), the PID file (httpd.pid) file needs to be accessed. If Apache is running as root or some user other than the agent process owner, access to the PID file will fail. Hence, to allow access to As a privileged user, run the following commands:
where |
Step 2: Decide how you want to add the Apache HTTP Server.
You can add Apache HTTP Server entities using one of two ways:
- Add them from UI
- Use the agent's
omcli add_entity
command with the appropriate JSON files
Adding Entities from the UI
- From the Management Cloud main menu, select Administration, Discovery, and then Add Entity. The Add Entity page displays.
- Select the Apache HTTP Server Entity Type.
- Enter the following UI properties.
Apache HTTP Server UI Properties - Entity Name: Name of the Apache HTTP Server entity appearing in the UI. .
- Host Name: Host Name of the Apache HTTP Server.
- Server Root: Server Root of the Apache HTTP Server.
- Absolute Path of httpd.conf: Absolute path of the Apache httpd.conf file. Note: Filename needs to be appended.
- Is Remote: Is the Apache installation host different from the agent host? Yes/No
- Binary Home: Absolute path of the httpd binary (Optional - default value, if not provided: <Apache Home>/bin or /usr/bin)
- Protocol: Protocol for connection to the Apache HTTP Server.
- Listen Port: Listen Port of the Apache HTTP Server.
- Server Status Connection Hostname: Server-status (Optional). This property specifies the value for the Host Name configured for /server-status connection (if different than FQDN - e.g., localhost). This needs to be specified if the connection-string (host:port) has a different host-name value than the value specified for host_name property. If specified, this value will be used to connect to Apache and retrieve data from the URI /server-status. If this property value is not specified, the default value will be the same as the host_name property value. (Optional)
- Cloud Agent: Cloud agent monitoring the Apache HTTP Server.
See Add Entities from the Console for detailed instructions on using the Add Entity UI.
Using omcli
and the Appropriate JSON Files
- Download and extract the required JSON file(s) from the master JSON zip file. See the table below for the specific JSON files you'll need.
- Edit the file(s) and specify the requisite properties shown below.
Apache HTTP Server JSON Files and Properties Definition File: omc_generic_apache_sample.json
- host_name: Host Name of the Apache HTTP Server.
- omc_listen_port: Listen Port of the Apache HTTP Server.
- omc_httpd_conf_path: Absolute Path of httpd.conf
- omc_protocol: Protocol for connection to the Apache HTTP Server.
- omc_server_root: Server Root of the Apache HTTP Server.
- omc_is_remote: Indicates whether the HTTP Apache Server is local(NO) or remote(YES) - possible values: yes / no.
- omc_binary_home: Absolute path of the httpd binary (Optional - default value, if not provided: $omc_server_root/bin)
- omc_access_log_path: Access Log Path (Optional)
- omc_error_log_path: Error Log Path (Optional)
- omc_server_status_connect_host: Server-status (Optional). This property specifies the value for the Host Name configured for /server-status connection (if different than FQDN - e.g., localhost). This needs to be specified if the connection-string (host:port) has a different host-name value than the value specified for host_name property. If specified, this value will be used to connect to Apache and retrieve data from the URI /server-status. If this property value is not specified, the default value will be the same as the host_name property value. (Optional)
- Add the entity using
omcli
.omcli add_entity agent DEFINITION_FILE [-credential_file CREDENTIAL_FILE [-encryption_method_gpg]]
- Verify the status of the newly added entity.
omcli status_entity agent DEFINITION_FILE
See step 4. Adding Entities to Your Service of Add Entities Using JSON Files for more information.
Step 3: (Optional but recommended) Set up alerts.
To enable lights-out monitoring, you can set up alert rules to generate alerts and send notifications if your entities have performance issues.
See Set Up Alert Rules and Set Up Alert Thresholds and Notifications.Troubleshooting
If you run into any issues regarding discovery or monitoring of Apache HTTP Server, see the following: