Configure privileged API access for Antminer

Background

This feature is available on all modern Antminers, including S7, S9, R4, T9, L3, L3+ and D3.

In order to monitor a miner like Bitmain Antminer, Awesome Miner is connecting to the Cgminer/Bmminer API running on the miner to request information. By default, Antminer has the API enabled, but the API is running in Restricted mode. In Restricted mode it's possible to view statistics and information about the mining, but no changes like pool operations or restart can be performed.

To get full access to the API, Privileged mode instead of Restricted mode, the Antminer must be configured to allow this. Awesome Miner can connect to Bitmain Antminer using SSH to enable Privileged API access. This operation can be performed on multiple Antminer's at the same time, to make the management of a large number of miners efficient.

Set Privileged API acess

Follow these steps to enable Privileged API access for one or many Bitmain Antminers in a single operation.

  1. Select the Antminers you want to configure API access for in the main window of Awesome Miner
  2. Select the menu option Tools -> Antminer -> Configure API access
  3. Enter SSH username and password. The default username is root and the default password is admin
  4. Awesome Miner will automatically detect which Antminer you ar using, so leave the Auto detect feature enabled
  5. There are two options for specifying which from which IP addresses the API should be enabled. Please note that it is not the IP address of the Antminer that should be specified. It's the IP address of the computer or network where Awesome Miner is running.
    • Any IP address: The Antminer will allow API connections from any IP address. This option should only be selected if the Antminers are in a secure network.
    • Specified IP rule: The Antminer will only allow API connections from the IP addresses specified by the rule. All Privileged rules must use W: in front of the IP address. Learn more about API access rules.
      The Antminer itself requires API access from localhost (127.0.0.1) for internal use. A rule for this will automatically be appended if not already specified.
  6. Click OK to apply changes to all selected Antminers
  7. The Antminers will be restarted after the changes have been applied, and will for that reason appear as Disconnected in Awesome Miner for a short period of time.
enable bitmain antminer privileged api

Information about Antminer API access settings

Antminers can revert back to Restricted API access by themselves in some scenarios. Two common scenarios are:
  • If the mining pools of the Antminers are set via the Antminer web interface, the Antminer will revert the API access mode to Restricted when the settings are applied.
  • In some reboot scenarios, the Antminer may revert the API access mode back to Restricted.

Automatic detection and configuration of Antminers with Restricted API access

Awesome Miner can be configured to automatically detect Antminers with Restricted API access and configure them to get Privileged API access. This feature can be enabled in the Options dialog, Antminer API access section. This can be useful when adding new miners that needs the configuration for Privileged API access for the first time, but also to detect miners that for some reason has reverted back to Restricted API mode.

Please note the importance of defining a correct IP rule, otherwise the Antminer will be running in Restricted API mode even after the configuration, and Awesome Miner will a few minutes later try to reconfigure it and reboot it again. The best practice is to try the configuration described in the first part of this guide before using the same settings for the automatic detection feature.

Back to help section