Skip to content
Standalone miner for grin
Rust CMake Other
Branch: master
Clone or download
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.ci Add plugins and config in release (#221) Jul 18, 2019
config 3.0.0-beta.1 versioning (#233) Dec 19, 2019
cuckoo-miner support CUDA C32 mining (#237) Jan 14, 2020
etc add script to automate crates.io Dec 12, 2018
ocl_cuckaroo 3.0.0-beta.1 versioning (#233) Dec 19, 2019
ocl_cuckatoo 3.0.0-beta.1 versioning (#233) Dec 19, 2019
plugin 3.0.0-beta.1 versioning (#233) Dec 19, 2019
src Fix compiler warning and rustfmt (#230) Dec 17, 2019
util 3.0.0-beta.1 versioning (#233) Dec 19, 2019
.gitignore Add Cargo.lock, fix bad enumset version Sep 15, 2018
.gitmodules re-include submodule Oct 25, 2018
Cargo.lock Cargo update (#234) Dec 20, 2019
Cargo.toml 3.0.0-beta.1 versioning (#233) Dec 19, 2019
Dockerfile Fix docker build (#91) Jan 3, 2019
LICENSE Initial commit Apr 16, 2018
README.md Remove Travis YML (#213) May 29, 2019
azure-pipelines.yml Improve CI: fix rustflags, remove unnecessary Rust Linux install and … Jul 12, 2019
grin-miner.toml support CUDA C32 mining (#237) Jan 14, 2020
install_ocl_plugins.sh Fix script to use = instead of == for compatibility Jan 31, 2019
rustfmt.toml

README.md

Build Status

Grin Miner

A standalone mining implementation intended for mining Grin against a running Grin node.

Supported Platforms

At present, only mining plugins for linux-x86_64 and MacOS exist. This will likely change over time as the community creates more solvers for different platforms.

Requirements

  • rust 1.30+ (use rustup- i.e. curl https://sh.rustup.rs -sSf | sh; source $HOME/.cargo/env)
  • cmake 3.2+ (for Cuckoo mining plugins)
  • ncurses and libs (ncurses, ncursesw5)
  • zlib libs (zlib1g-dev or zlib-devel)
  • linux-headers (reported needed on Alpine linux)

And a running Grin node to mine into!

Build steps

git clone https://github.com/mimblewimble/grin-miner.git
cd grin-miner
git submodule update --init
cargo build

Building the Cuckoo-Miner plugins

Grin-miner automatically builds x86_64 CPU plugins. Cuda plugins are also provided, but are not enabled by default. To enable them, modify Cargo.toml as follows:

change:
cuckoo_miner = { path = "./cuckoo-miner" }
to:
cuckoo_miner = { path = "./cuckoo-miner", features = ["build-cuda-plugins"]}

The Cuda toolkit 9+ must be installed on your system (check with nvcc --version)

Building the OpenCL plugins

OpenCL plugins are not enabled by default. Run install_ocl_plugins.sh script to build and install them.

./install_ocl_plugins.sh

You must install OpenCL libraries for your operating system before. If you just need to compile them (for development or testing purposes) build grin-miner the following way:

cargo build --features opencl

Build errors

See Troubleshooting

What was built?

A successful build gets you:

  • target/debug/grin-miner - the main grin-miner binary
  • target/debug/plugins/* - mining plugins

Make sure you always run grin-miner within a directory that contains a grin-miner.toml configuration file.

While testing, put the grin-miner binary on your path like this:

export PATH=/path/to/grin-miner/dir/target/debug:$PATH

You can then run grin-miner directly.

Configuration

Grin-miner can be further configured via the grin-miner.toml file. This file contains contains inline documentation on all configuration options, and should be the first point of reference.

You should always ensure that this file exists in the directory from which you're running grin-miner.

Using grin-miner

There is a Grin forum post with further detail on how to configure grin-miner and mine grin's testnet.

You can’t perform that action at this time.