Skip to content

References

Usage

Bminer supports the following options in the command line. You can also run bminer -help to get the full list of options.

Option
Default Description
-api string null The endpoint that Bminer serves its REST API. For example, 127.0.0.1:1880. The REST API is disabled if it is unspecified.
-devices value null List of GPU devices that Bminer should run on. If it is unspecified bminer runs on all CUDA devices available on the system.
-failover value immediateNext Fail-over strategy between multiple pools. Bminer can retry the connection, failover to the next pool or a pool that is randomly chosen in the lists of available pools. Supported strategies are sameHost, immediateNext and random.
-gpucheck uint 90 The interval in seconds that Bminer polls whether the CUDA devices have hung. Set to 0 to disable the checks.
-logfile string null Append the logs to the file.
-max-network-failures -1 Number of consecutive attempts that Bminer tries to recover from network failures. Set to -1 to keep on recovering.
-max-temperature int 85 Hard limits of the temperature of the GPUs. BMiner slows down itself when the temperautres of the devices exceed the limits.
-no-runtime-info Disable runtime information collection for Bminer.
-no-timestamps Remove timestamp in your logging messages.
-nofee Disable the devfee but it also disables some optimizations.
-pers BgoldPoW Personalization string for Equihash 144,5 based coins. Can be set to auto.
-share-check 900 The interval of seconds that Bminer polls to ensure there are accepted shares. Set to 0 to disable the checks.
-strict-secure Verify the certificates of servers when connecting to a SSL-enabled Stratum server. The default is off.
-uri value List of comma-separated URIs that bminer should mine towards. URI has a format of <scheme>://<username>[:<password>]@<host>:<port>. Note that the <scheme> for all the URIs have to be the same.
-uri2 value List of comma-separated URIs that bminer should mine towards secondarily. It has the format of <scheme>://<username>[:<password>]@<host>:<port>. Currently Bminer supports scheme blake14r:// or blake2s:// as secondary for Ethash mining as primary.
-dual-subsolver int -1 The sub-solver for dual mining. Valid values are 0, 1, 2, 3. Default is -1, which is to tune automatically.
-dual-intensity int 0 The intensity of the secondary mining. Valid values are from 0 to 300. Default is 0, which is to tune automatically.
-intensity 6 The CPU intensity of mining AE / Grin. Valid values are from 0 to 12.
-watchdog true Automatic restart to recover from hung GPUs. Bminer exits itself in case of errors if watchdog is disabled.
-version Output version and exit.

Specfying URIs

Bminer uses URIs to identify the mining pool and the account of the pool. The URIs has the format of <scheme>://<username>[:<password>]@<host>:<port>. Following RFC 3986, the scheme specifies both the proof-of-work (PoW) algorithm and the networking protocol. Bminer supports mining coins using the following PoW algorithm and protocols:

PoW algorithm Networking protocol Scheme
* Equihash Stratum stratum://
* Equihash Stratum over SSL stratum+ssl://
* Equihash 144,5 Stratum equihash1445://
* Equihash 144,5 Stratum over SSL equihash1445+ssl://
* Zhash Stratum zhash://
* Zhash Stratum over SSL zhash+ssl://
* Ethash Stratum ethash://
* Ethash Stratum over SSL ethash+ssl://
* Ethash Ethereum Proxy ethproxy://
* Ethash Ethereum Stratum ethstratum://
* Blake14r (secondary) Stratum blake14r://
* Blake2s (secondary) Stratum blake2s://

Bminer also supports failing over between multiple pools in case of network failures. To enable the feature, you can pass a lists of URIs that are separate by commas. For example, the following command

./bminer -uri stratum://[email protected]:3333,
stratum://[email protected]:6666

will instruct Bminer to mine Zcash over both Flypool and Nanopool.

Dashboards and REST APIs

Bminer provides a Web-based dashboard to monitor the health of the miner. The dashboard resides at the same address of the management API. For example, you can access the dashboard at http://127.0.0.1:1880 if you have enabled the API at 127.0.0.1:1880.

Below is a screenshot of the dashboard:

Screenshot


Bminer also provides REST APIs to automate large-scale deployments.

GET /api/v1/status/solver

Example value for equihash:

{
  "devices": {
    "0": {
      "solvers": [
        {
          "algorithm": "equihash",
          "speed_info": {
            "nonce_rate": 359.27,
            "solution_rate": 677.53
          }
        }
      ]
    }
  }
}

Example value for dual mining mode:

{
  "devices": {
    "0": {
      "solvers": [
        {
          "algorithm": "ethash",
          "speed_info": {
            "hash_rate": 30828134.4
          }
        },
        {
          "algorithm": "blake2s",
          "speed_info": {
            "hash_rate": 1778500208.17
          }
        }
      ]
    }
  }
}

GET /api/v1/status/device

Example value:

{
  "devices": {
    "0": {
      "temperature": 83,
      "power": 199,
      "fan_speed": 74,
      "global_memory_used": 4385,
      "utilization": {
        "gpu": 100,
        "memory": 73
      },
      "clocks": {
        "core": 1809,
        "memory": 5005
      }
      "pci_bus_id": "0000:01:00.0"
    }
  }
}

GET /api/v1/status/stratum

Example value for dual mining mode:

{
  "stratums": {
    "blake2s": {
      "failover_uris": [
        {
          "name": "blake2s://DDXKDhq73GRM3hjh6uee57fJ3LS2ctNtyi.my:c=XVG,[email protected]:5766",
          "active": true
        }
      ],
      "accepted_shares": 1,
      "rejected_shares": 0,
      "accepted_share_rate": 0.02,
      "rejected_share_rate": 0
    },
    "ethash": {
      "failover_uris": [
        {
          "name": "ethproxy://0xb76d43eAaB2e905028a7f0F3aF13C7A84c477B9f.w@guangdong-pool.ethfans.org:3333/",
          "active": true
        }
      ],
      "accepted_shares": 2,
      "rejected_shares": 0,
      "accepted_share_rate": 0.01,
      "rejected_share_rate": 0
    }
  }
}

The semantics of the fields are the following:

Name
Type Description
stratum object The information of the Stratum client.
failover_uris object An array of uris that are intended for mining
name string Name of uri
active boolean If this uri is an active uri being used for mining
accepted_shares integer Total number of shares that are accepted by the Stratum server.
rejected_shares integer Total number of shares that are rejected by the Stratum server.
accepted_shares_rate number The number of accepted shares per second.
rejected_shares_rate number The number of rejected shares per second.
miners object The map that maps the ID of the CUDA device to the status of the miner running on the device.
devices object The map that maps the ID of the CUDA device to the status of the miner running on the device.
solver object Statistics of the Equihash solver.
solvers object An array of solvers running on a device.
algorithm string The name of the algorithm of a solver.
speed_info object Primary speed metrics of a solver.
hash_rate number Number of hash rate of the algorithm. (H/s)
solution_rate number Number of Equihash solutions found. (Sols/s)
nonce_rate number Number of nonces that are evaluated for equihash. (I/s)
device object Statistics of the CUDA device.
temperature integer The temperature of the CUDA device. (Celsius)
power integer The amount of power used by the CUDA device. (Watts)
fan_speed integer The utilization of the fan speed, from 0-100.
global_memory_used integer The amount of memory that are used on the CUDA device.
utilization object Statistics of utilization of the CUDA device.
gpu integer The utilization of the GPU from 0-100.
memory integer The utilization of the memory bandwidth, from 0-100.
clocks object The frequency of the clocks of the CUDA device.
core integer The frequency of the GPU core. (MHz)
memory integer The frequency of the GPU memory. (MHz)
pci object The utilization of the PCI-E bus.
bar1_used integer The amount BAR1 memory used.
rx_throughput integer The throughput of the data received from the PCI-E bus. (MB/s)
tx_throughput integer The throughput of the data sent from the PCI-E bus. (MB/s)
pci_bus_id string The ID on the PCI-E bus
version string The version of Bminer.
start_time integer The time that Bminer starts, in UNIX time.

POST /api/v1/control/exit

Stop and exit once the request is received.