-
Notifications
You must be signed in to change notification settings - Fork 69
GPUs
At the beginning of 2023, the Chia blockchain took a turn that meant more hardware was needed to plot and farm efficiently. Where before just a mid-range computer with an average CPU and an SSD could plot and farm, the advent of Gigahorse and the subsequent attempts by Bladebit to keep up, a GPU became a helpful add-on for plotting and farming.
As of 2023-03-20, here is the current support:
Platform | Plotting Support | Farming Supported |
---|---|---|
Chia/Bladebit | Yes (Nvidia - alpha) | No |
Chia/Gigahorse | Yes (Nvidia & AMD) | Yes (Nvidia & AMD) |
MMX/Madmax | Yes | Yes (Nvidia, AMD, Intel) |
You'll need the Nvidia Driver Runtime. On Unraid, just install the Nvidia Driver plugin.
Then please add the following to your docker-compose.yml.
Extend the existing environment
section
environment:
- OPENCL_GPU=nvidia
- NVIDIA_VISIBLE_DEVICES=0
- NVIDIA_DRIVER_CAPABILITIES=compute,utility
Then add a new runtime line, (at same level as environment
):
runtime: nvidia
OR for Unraid, using the Docker admin tab, edit the Machinaris-MMX config, create 3 new Variables (shown) and add --runtime=nvidia
to the "Extra Parameters" field.
Ideally you can target the device by position or GUID, which you can later override in Unraid Docker Configuration or compose ENVs,
-e NVIDIA_VISIBLE_DEVICES=0 or -e NVIDIA_VISIBLE_DEVICES=GPU-a8b96998-xxxx-xxxx
Further explained here.
For AMD GPUs, as per this tutorial (AMD section part-way down), please add the following to your docker-compose.yml. Extend the existing environment
section
environment:
- OPENCL_GPU=amd
- ROC_ENABLE_PRE_VEGA=1
and add the following devices
section at the same level as environment
:
devices:
- "/dev/kfd:/dev/kfd"
- "/dev/dri/:/dev/dri/"
Extend the existing environment
section
environment:
- OPENCL_GPU=intel
and add the following devices
section at the same level as environment
:
devices:
- "/dev/dri/:/dev/dri/"
On the host machine, add the user that runs the container to the "video" and "render" groups.
sudo adduser $USER video
sudo adduser $USER render
To see if it worked, after the container starts, connect to it and type "clinfo"
docker exec -it machinaris-mmx bash
clinfo
You should see something like:
root@localhost:/chia-blockchain# clinfo
Number of platforms 1
Platform Name Intel(R) OpenCL HD Graphics
Platform Vendor Intel(R) Corporation
Platform Version OpenCL 3.0
Platform Profile FULL_PROFILE
CHIA NETWORK INC, CHIA™, the CHIA BLOCKCHAIN™, the CHIA PROTOCOL™, CHIALISP™ and the “leaf Logo” (including the leaf logo alone when it refers to or indicates Chia), are trademarks or registered trademarks of Chia Network, Inc., a Delaware corporation. There is no affiliation between the Machinaris project and the main Chia Network project.