Add Telemetry and Name to xx chain

From xx network wiki
Revision as of 17:03, 15 October 2021 by Anne (talk | contribs) (Protected "Add Telemetry and Name to xx chain" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)))
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
This is a team contributed page

If you have downloaded the Node and/or Gateway tarballs before 8/12/2021 or your xx chain service files lack a --telemetry-url flag, then a modification needs to be made to the xx chain service file on both machines to include the name and URL for telemetry.

Add Telemetry Flags to the Node

Follow the instructions below on the Node machine.

  1. Open up the xx chain service file.

  2. Next, the name used for telemetry of your Node needs to be configured. Use the down key to navigate to the line that starts with ExecStart and, after the --validator flag, add the flag --name followed by your desired name for the Node. While not required, you may want to make the name unique so you can differentiate your Node from other Nodes and Gateways. If you do not set a name, then a random name will automatically be assigned to your Node.

  3. After the --name flag, add the flag --telemetry-url "wss://telemetry.polkadot.io/submit/ 0".

    Note that if your entire line (from /opt/xxnetwork/bin/xxnetwork-chain to 2>&1) starts with double quotes (" ") instead of single quotes (' '), then the telemetry URL should be enclosed with single quotes (--telemetry-url 'wss://telemetry.polkadot.io/submit/ 0').
  4. Once the change is made, save the file by pressing Ctrl+X, and when prompted to save the buffer, press Y. Finally, when prompted with the file name, press Enter.

  5. Reload the systemd service files.

  6. To activate the change, restart the xx chain service.

  7. Finally, check that xx chain is running properly by tailing the log file.

    It should print an output that looks similar to the followign example.

Add Telemetry Flags to the Gateway

Follow the instructions below on the Gateway machine.

  1. First, stop the xx chain service.

  2. Open up the xx chain service file.

  3. Next, the name used for telemetry of your Gateway needs to be configured. After the flag --light, add the flag --name followed by your desired name for the Gateway. While not required, you may want to make the name unique so you can differentiate your Gateway from other Nodes and Gateways. If you do not set a name, then a random name will automatically be assigned to your Gateway.

  4. After the --name flag, add the flag --telemetry-url "wss://telemetry.polkadot.io/submit/ 0".

    Note that if your entire line (from /opt/xxnetwork/bin/xxnetwork-chain to 2>&1) starts with double quotes (" ") instead of single quotes (' '), then the telemetry URL should be enclosed with single quotes (--telemetry-url 'wss://telemetry.polkadot.io/submit/ 0').
  5. Once the change is made, save the file by pressing Ctrl+X, and when prompted to save the buffer, press Y. Finally, when prompted with the file name, press Enter.

  6. Reload the systemd service files.

  7. To activate the change, start the xx chain service.

  8. Finally, check that xx chain is running properly by tailing the log file.

    It should print an output that looks similar to the followign example.