NVIDIA UFM Cable Validation Tool

Apache Configuration for CVT Collector

Apache Configuration for CVT Collector

This document describes the configurable Apache settings for the CVT Collector, designed to optimize performance for different cluster scales.

Overview

The CVT Collector uses Apache as its web server. Apache performance can be tuned via profiles that adjust concurrency, connection handling, and logging settings based on your deployment scale.

Configuration Options

All Apache settings are configured in cvt_env.conf  under the [apache]  section: 

[apache]  
CVT_APACHE_PROFILE = small 
CVT_APACHE_LOG_LEVEL = warn  
CVT_APACHE_ACCESS_LOG = true 


CVT_APACHE_PROFILE

Selects the Apache performance profile. Each profile includes MPM (Multi-Processing Module) settings and connection optimization settings.

Profile

Cores

RAM

Agents

MaxRequestWorkers

small

2-16

8-64GB

< 1,000

150

medium

32-128

128-512GB

1,000-10,000

2,048

large 

200-300

1TB+

10,000-20,000

12,800

xlarge 

400+

1.5TB+

20,000+

25,600

auto

-

-

-

Auto-detect based on CPU cores

Default: small 

CVT_APACHE_LOG_LEVEL

Controls the verbosity of Apache error logs. Higher levels reduce log volume.

Level

Description

debug 

Debug messages (very verbose)

info

Informational messages

notice

Normal but significant conditions

warn

Warning conditions (default)

error

Error conditions

crit

Critical conditions

alert

Action must be taken immediately

emerg

System is unusable

Default: warn 

Recommendation for large clusters: Use error  or crit  to reduce log I/O.

CVT_APACHE_ACCESS_LOG

Enable or disable Apache access logs (HTTP request logging).

Value

Description

true

Access logs enabled (default)

false

Access logs disabled

Default: true 

Recommendation for large clusters: Set to false  to reduce disk I/O.

Profile Details

Small Profile (Default)

For development and small production deployments.

# MPM Settings
StartServers          2
MinSpareThreads      25
MaxSpareThreads      75
ThreadLimit          64
ThreadsPerChild      25
MaxRequestWorkers   150
# Connection Settings
KeepAlive On
KeepAliveTimeout 5
MaxKeepAliveRequests 100
Timeout 180 

Medium Profile

For mid-size production clusters.

# MPM Settings
StartServers                 4
MinSpareThreads             75
MaxSpareThreads            250
ThreadLimit                 64
ThreadsPerChild             64
ServerLimit                 32
MaxRequestWorkers         2048
AsyncRequestWorkerFactor     2


# Connection Settings
KeepAlive On
KeepAliveTimeout 3
MaxKeepAliveRequests 500
Timeout 150
EnableMMAP Off 

Large Profile

For large-scale production deployments. 

# MPM Settings
StartServers                 8
MinSpareThreads            200
MaxSpareThreads            600
ThreadLimit                128
ThreadsPerChild            128
ServerLimit                100
MaxRequestWorkers        12800
AsyncRequestWorkerFactor     2


# Connection Settings
KeepAlive On
KeepAliveTimeout 2
MaxKeepAliveRequests 1000
Timeout 120
EnableMMAP Off 

XLarge Profile

For very large-scale hyperscale deployments.

# MPM Settings
StartServers                   8
MinSpareThreads              250
MaxSpareThreads              750
ThreadLimit                  128
ThreadsPerChild              128
ServerLimit                  200
MaxRequestWorkers          25600
AsyncRequestWorkerFactor       2

# Connection Settings
KeepAlive On
KeepAliveTimeout 2
MaxKeepAliveRequests 1000
Timeout 120
EnableMMAP Off 

Usage

Via cvt_env.conf (Recommended)

Edit the configuration file (persisted across restarts):

[apache]
CVT_APACHE_PROFILE = large
CVT_APACHE_LOG_LEVEL = error
CVT_APACHE_ACCESS_LOG = false 

The configuration file is located at:

  • Container: /cable_bringup_root/config/cvt_env.conf

  • Default: /etc/cablevalidation/cvt_env.conf

Via Environment Variables

Set environment variables when starting the container:

docker run \
   -e CVT_APACHE_PROFILE=large \
   -e CVT_APACHE_LOG_LEVEL=error \
   -e CVT_APACHE_ACCESS_LOG=false \
   ... 

Environment variables take precedence over cvt_env.conf settings.

Auto-Detection

Use auto  to automatically select a profile based on available CPU cores: CVT_APACHE_PROFILE = auto 

Auto-detection thresholds:

  • 400+ cores → xlarge 

  • 200-399 cores → large 

  • 32-199 cores → medium 

  • < 32 cores → small 

Configuration Files

The Apache configuration is applied at container startup via apache2_wrapper.sh :

Setting Type

Destination File

MPM settings

/etc/apache2/mods-available/mpm_event.conf

Performance settings

/etc/apache2/conf-available/cvt_performance.conf

Log level

/etc/apache2/apache2.conf

Access logs

/etc/apache2/conf-available/*.conf 

/etc/apache2/sites-available/*.conf

Customizing Profiles

Profiles are defined in /etc/apache2/apache_profiles.conf (copied from conf/collector/apache_profiles.conf at build time).

To add a custom profile:

  1. Edit the profiles file

  2. Add a new section with MPM and Performance settings:

    [custom]
    # custom - Description
    # === MPM ===
    StartServers 6
    MinSpareThreads 100
    ...
    # === Performance ===
    KeepAlive On
    KeepAliveTimeout 4
    ...
    
  3. Set CVT_APACHE_PROFILE = custom in cvt_env.conf

Troubleshooting

Apache fails to start with "already running"

This occurs when a stale PID file exists from a previous unclean shutdown. The wrapper script automatically cleans stale PID files, but if the issue persists:

rm -f /cable_bringup_root/config/run/apache2/apache2.pid
supervisorctl start apache

Check current configuration

# Verify profile was applied
cat /etc/apache2/mods-available/mpm_event.conf
cat /etc/apache2/conf-available/cvt_performance.conf


# Check Apache config syntax
apache2ctl configtest


# View current settings
apache2ctl -V
 View Apache logs
# Error log
tail -f /cable_bringup_root/log/apache2/error.log

# Access log (if enabled)
tail -f /cable_bringup_root/log/apache2/access.log

Best Practices for Large Clusters

  1. Use appropriate profile: Match your hardware resources

  2. Disable access logs: Reduces disk I/O significantly

  3. Increase log level: Use error or crit instead of warn

  4. Monitor resources: Watch CPU and memory usage after profile changes

  5. Test before production: Validate configuration in staging environment

Example high-performance configuration: 

[apache]
CVT_APACHE_PROFILE = large
CVT_APACHE_LOG_LEVEL =crit
CVT_APACHE_ACCESS_LOG = false

Last updated: