Set Up taosX-Agent Reference Guide
Introduction
This section explains how to deploy the Agent
(for taosX
).
Configuration
The default configuration file for the Agent
is located at /etc/taos/agent.toml
, and it includes the following configuration items:
endpoint
: Mandatory, the GRPC service address oftaosX
.token
: Mandatory, the Token generated when creating theAgent
onExplorer
.compression
: Optional, can betrue
orfalse
, default tofalse
. If configured totrue
, enable communication data compression betweenAgent
andtaosX
.log_level
: Optional, log level, default isinfo
. Similar totaosX
, it supportserror
,warn
,info
,debug
,trace
.log_keep_days
: Optional, the number of days to keep logs, default is30
days.
As shown below:
endpoint = "grpc://<taosx-ip>:6055"
token = "<token>"
compression = true
log_level = "info"
log_keep_days = 30
Start taos-Agent
On Linux, use the systemctl
command to start the taosX
agent:
systemctl start taosx-agent
On Windows, open the Services app and start the taosx-agent service.
Troubleshooting
You can view the log file or use the journalctl
command to view Agent
log files.
The command to view logs using journalctl
on Linux is as follows:
journalctl -u taosx-agent [-f]