AMS server configuration
Ant Media Server can be configured either through the management console (web panel) or by directly modifying the configuration files. Most settings are defined in the configuration files.
Main Configuration File
The primary configuration file is located at: <AMS_DIR>/conf/red5.properties. Below are the available server configuration options.
General Server Settings
policy.host: Socket policy host. Default:0.0.0.0policy.port: Socket policy port (must be open). Default:843server.name: Ant Media Server name (optional).server.licence_key: Ant Media Server license key (required for Enterprise Edition).server.heartbeatEnabled: Enables server heartbeat. Default:trueserver.kafka_brokers: Kafka broker address (default Kafka port is9092). Optional.server.cpu_limit: CPU usage limit (percentage). Default75server.min_free_ram: Minimum free RAM required (in MB). Default:10logLevel: Logging level (TRACE, DEBUG, INFO, WARN, ERROR). Default:INFOuseGlobalIp: Whether to use the global IP for WebSocket clusters. Default:false
HTTP Settings
http.host: HTTP host. Default:0.0.0.0http.port: HTTP port. Default:5080https.port: HTTPS port. Default:5443http.URIEncoding: URI encoding. Default:UTF-8http.max_keep_alive_requests: Maximum keep-alive requests. Default:-1http.max_threads: Maximum HTTP threads. Default:20http.acceptor_thread_count: Acceptor thread count. Default:10http.processor_cache: Processor cache size. Default:20
RTMP Settings
rtmp.host: RTMP host. Default:0.0.0.0rtmp.port: RTMP port. Default:1935rtmp.io_threads: IO thread count. Default16rtmp.send_buffer_size: Send buffer size. Default:65536rtmp.receive_buffer_size: Receive buffer size. Default:65536rtmp.ping_interval: Ping interval (ms). Default:1000rtmp.max_inactivity: Maximum inactivity (ms). Default:60000rtmp.max_handshake_time: Max handshake time (ms). Default:5000rtmp.tcp_nodelay: TCP no-delay option. Default:truertmp.tcp_keepalive: TCP keep-alive option. Default:falsertmp.default_server_bandwidth: Default server bandwidth. Default:10000000rtmp.default_client_bandwidth: Default client bandwidth. Default:10000000rtmp.client_bandwidth_limit_type: Bandwidth limit type. Default:2rtmp.bandwidth_detection: Bandwidth detection. Default:falsertmp.encoder_base_tolerance: Encoder base tolerance (ms). Default:5000rtmp.encoder_drop_live_future: Drop live future frames. Default:falsertmp.traffic_class: Traffic class. Default:-1rtmp.backlog: Backlog size. Default:32rtmp.thoughput_calc_interval: Throughput calculation interval. Default:15rtmp.default_acceptor: Default acceptor. Default:. Default:truertmp.initial_pool_size: Initial Pool Size. Default:0rtmp.max_pool_size: Max Pool Size. Default:2rtmp.max_processor_pool_size: Max Processor Pool Size. Default:16rtmp.executor_keepalive_time: Executer Keep-Alive Time. Default:60000mina.logfilter.enable: Mina Log Filter Enable. Default:falsertmp.scheduler.pool_size: Scheduler Pool Size. Default:16rtmp.deadlockguard.sheduler.pool_size: Deadlockguard Scheduler Pool Size. Default:16rtmp.executor.core_pool_size: Executer Core Pool Size. Default:4rtmp.executor.max_pool_size: Executer Max Pool Size. Default:32rtmp.executor.queue_capacity: Executer Queue Capacity. Default:64rtmp.executor.queue_size_to_drop_audio_packets: Executer Queue Size to Drop Audio Packets. Default:60rtmp.max_handling_time: Max Handling Time. Default:2000rtmp.channel.initial.capacity: Channel Initial Capacity. Default:3rtmp.channel.concurrency.level: Channel Concurrency Level. Default:1rtmp.stream.initial.capacity: Stream Initial Capacity. Default:1rtmp.stream.concurrency.level: Stream Concurrency Level. Default:1rtmp.pending.calls.initial.capacity: Pending Calls Initial Capacity. Default:3rtmp.pending.calls.concurrency.level: Pending Calls Concurrency Capacity Level. Default:1rtmp.reserved.streams.initial.capacity: Reserved Streams Initial Capacity. Default:1rtmp.reserved.streams.concurrency.level: Reserved Streams Concurrency Level. Default:1rtmp.max_packet_size: Max Packet Size. Default:3145728
RTMPS Settings
rtmps.host: Host value. Default:0.0.0.0rtmps.port: Port value. Default:8443rtmps.ping_interval: Ping Interval. Default:5000rtmps.max_inactivity: Max Inactivity value. Default:60000rtmps.max_keep_alive_requests: Max Keep Alive Requests. Default:-1rtmps.max_threads: Max Threads. Default:20rtmps.acceptor_thread_count: Acceptor Thread Count. Default:2rtmps.processor_cache: Processor Cache. Default:20
RTMPS Key & Truststore
rtmps.keystorepass: Keystore Password. Default:passwordrtmps.keystorefile: Keystore File location. Default:conf/keystore.jksrtmps.truststorepass: Truststore Pass. Default:passwordrtmps.truststorefile: Truststore File location. Default:conf/truststore.jks
RTMPT Settings
rtmpt.host: RTMP Host. Default:0.0.0.0rtmpt.port: RTMPT Port. Default:8088rtmpt.ping_interval: Ping interval. Default:5000rtmpt.max_inactivity: Max Inactivity. Default:60000rtmpt.max_handshake_time: Max Handshake Time. Default:5000rtmpt.max_keep_alive_requests: Max Keep Alive Requests. Default:-1rtmpt.max_threads: Max Threads. Default:20rtmpt.acceptor_thread_count: Acceptor Thread Count. Default:2rtmpt.processor_cache: Processor Cache. Default:20rtmpt.encoder_base_tolerance: Encoder Base Tolerance. Default:5000rtmpt.encoder_drop_live_future: Encoder Drop Live Future. Default:truertmpt.target_response_size: Target Response Size. Default:32768(For streaming),8192(For small messages)rtmpt.max_in_msg_process: Max incoming messages to process at once. Default:166rtmpt.max_queue_offer_time: Max queue offer time (ms). Default:125rtmpt.max_queue_offer_attempts: Max queue offer attempts. Default:4
Debug Proxy (requires activation in red5-core.xml)
proxy.source_host: Proxy source host. Default:127.0.0.1proxy.source_port: Proxy Source Port. Default:1936proxy.destination_host: Proxy Destination Host. Default:127.0.0.1proxy.destination_port: Proxy Destination Port. Default:1935
JMX Settings
jmx.rmi.host: JMX RMI Host. Default:localhostjmx.rmi.port: JMX RMI Port. Default:9999jmx.rmi.sport: JMX RMI Sport. Default:9998jmx.rmi.port.remoteobjects: JMX RMI Remote Objects Port. Optional.jmx.keystorepass: JMX Keystore Pass. Default:passwordjmx.mina.monitor.enable: Enable Mina Monitor. Default:falsejmx.mina.poll.interval: Mina Poll Interval. Default:1000jmx.registry.create: Always create registry in-process. Default:truejmx.reuse.existing.server: Reuse existing MBean server. Default:truejmx.register.factory: Register MBean server with factory. Default:truejmx.daemon: Run JMX connector threads as daemon. Default:truejmx.threaded: Start JMX connector server in a separate thread. Default:true
Other Server Settings
so.max.events.per.update: Max events per update. Default:64so.scheduler.pool_size: Scheduler pool size. Default:4keyframe.cache.entry.max: Max keyframe cache entries. Default:500war.deploy.server.check.interval: WAR deploy check interval (ms). Default:600000fileconsumer.delayed.write: Enable delayed file writes. Default:truefileconsumer.queue.size: File consumer queue size. Default:120subscriberstream.buffer.check.interval: Buffer check interval (ms). Default:5000subscriberstream.underrun.trigger: Underrun trigger threshold. Default:100broadcaststream.auto.record: Enable auto recording of broadcasts. Default:false
Auto Recording (MP4 & HLS)
broadcastream.auto.record.mp4: Auto record to MP4. Default:truebroadcastream.auto.record.hls: Auto record to HLS. Default:true
Cluster DB Specifications
clusterdb.host: Cluster DB host. Default:localhostclusterdb.user: Cluster DB user. Optional.clusterdb.password: Cluster DB password. Optional.