Install taosX-Agent
The features or components discussed in this document are available in TDengine TSDB-Enterprise only. TDengine TSDB-OSS does not include these features or components.
Overview
If taosX cannot connect directly to your data source, you can install taosX-Agent on the network where your data source is located. You can install taosX-Agent on the machine where your data source is located or on a different machine on the same network that can access the data source. taosX can then connect to your data source through taosX-Agent.
- It is not necessary to install TDengine on the same machine as the data source.
- If taosX can connect directly to your data source, it is not necessary to install taosX-Agent.
Create Agent
- Windows
- Linux
-
In a web browser, open taosExplorer.
-
From the main menu on the left, select Data In.
-
Open the Agent tab and click Create New Agent.
-
Click Windows to download taosX-Agent.
-
On your local machine, run the taosX-Agent installer and follow the prompts.
-
In taosExplorer, click Next.
-
Enter a unique name for your agent and click Next to generate an authentication token.
-
On your local machine, open the
C:\TDengine\cfg\agent.tomlfile. -
Copy the values of
endpointandtokendisplayed in taosExplorer into theagent.tomlfile.endpoint="http://localhost:6055"
token="eyJ0eX...BhA" -
In taosExplorer, click Next.
-
On your local machine, open a terminal as an administrator and run the following command:
sc start taosx-agent -
In taosExplorer, click Check Agent Connection.
-
If Success is displayed, click Finish.
-
In a web browser, open taosExplorer.
-
From the main menu on the left, select Data In.
-
Open the Agent tab and click Create New Agent.
-
Click Linux to download taosX-Agent.
-
On your local machine, run the taosX-Agent installer and follow the prompts.
-
In taosExplorer, click Next.
-
Enter a unique name for your agent and click Next to generate an authentication token.
-
On your local machine, open the
/etc/taos/agent.tomlfile. -
Copy the values of
endpointandtokendisplayed in taosExplorer into theagent.tomlfile.endpoint="http://localhost:6055"
token="eyJ0eX...BhA" -
In taosExplorer, click Next.
-
On your local machine, open a terminal and run the following command:
sudo systemctl start taosx-agent -
In taosExplorer, click Check Agent Connection.
-
If Success is displayed, click Finish.
When you create data in tasks, you can use this agent to connect to your data source.
Task Configuration and Agent Lifecycle
After taosX-Agent is installed and connected on the data-source side, reuse the same Agent long term. In taosExplorer you can:
- Create, edit, start, and stop Data In tasks (including OPC DA / OPC UA and others)
- Adjust task-level collection settings (such as collection interval)
- Append points and update point CSV / mapping
These operations do not require reinstalling the Agent on the OPC (or other) server host, and do not require generating and redistributing a new “agent install package” just to change points. Tasks communicate with central taosX using the configured endpoint and token.
Cases that do require changing the Agent host again include: replacing the connection endpoint / token, upgrading the Agent, or editing host-local agent.toml or store-and-forward options. Component reference: taosX-Agent. You can also manage agents and tasks with SQL; see Data Ingestion (Xnode).
Related Documentation
For full configuration options, see taosX-Agent.