Installing on macOS¶
Prerequisites
macOS 12 or higher is required. For versions lower than the recommended version, please refer to this link https://docs.guance.com/datakit/datakit-install/#major-version.
Selecting the DataWay Data Gateway Address¶
DataWay is the data gateway for TrueWatch. All data reported by collectors to TrueWatch must pass through the DataWay gateway.
Installation Command¶
Copy the installation command below and run it on your server.
DK_DATAWAY="https://openway.guance.com?token=tkn_7f5********fda8681" bash -c "$(curl -L https://static.guance.com/datakit-v2/install.sh)"
During the installation phase, you can define some DataKit configurations by adding environment variables to the installation command. Prefix the variables with
$env:, and separate multiple environment variables withsemicolons.
Common Configurations¶
- Add global host tags. Separate multiple tags with English commas. For example:
host=datakit_hostname. - Specify the collectors to be enabled. By default, some host-related collectors are enabled. For example:
cpu,mem,disk.
RUM & HTTP¶
- Configure the DataKit HTTP service address (❗️If using RUM functionality, configure this as a publicly accessible address). For example:
localhost. - Configure the port bound to the DataKit HTTP service. The default is 9529.
- Choose whether to enable the RUM collector.
- Choose whether to install the IP geolocation database.
- Choose whether to disable the DataKit 404 page.
- Choose whether to install the Source Map toolset.
APM¶
- Choose whether to enable the DDTrace collector.
- Choose whether to enable APM auto-injection.
DCA¶
Choose whether to enable the DCA service.
Notes¶
If the following appears during installation/upgrade:
"launchctl" failed with stderr: /Library/LaunchDaemons/com.guance.datakit.plist: Service is disabled
- First, execute the command:
- Then, execute the command: