Agent configuration is the process of defining server and client agent properties with CLI flags and configuration files. Learn what properties can be configured on reload and how Consul sets precedence for configuration settings.

Consul agent(Consul 代理)是运行在节点上的长期守护进程,是 Consul 运作的核心单元。代理具有高度可配置性,能够将 Consul 部署到任意基础设施中。本文档介绍了 Consul agent 的运行模式、生命周期、故障处理、退出机制、部署要求以及启动方式等基础知识。
consul agent <options> 命令,最低需指定 -data-dir 或通过 -config-file/-config-dir 提供配置;-dev 开发者模式不可用于生产。$ consul agent -data-dir=tmp/consul -dev
启动后输出包含节点名、数据中心、Server 标识、Client/Cluster 地址及 Serf 成员加入事件等关键信息。