CUDA Miner Issue

I was able to setup the node and confirmed it is running with block heights changing as they should. I issue is with getting the GPU’s on the rig to mine. I looked at the github referenced for multi GPU and the link takes you to documents for CUDA miner that are 16 days old and reference 1.0.0 RC2. I cant seem to find anything that has changed from the last time I setup and was able to mine the test net with a single GPU.

Configuration in the epoch.yaml for mining is the same. Not sure what I need to do to even get it to mine with a single GPU anymore.

You CUDA miner documents reference Ubuntu 16.04 but nothing for 18.04. CUDA Toolkit 9.2 is not supported in 18.04 so you have to use CUDA Toolkit 10.0 I successfully installed 18.04 and CUDA 10.0 and mined testnet 0.0.24 some time back.

Is there and updated document for the multi GPU that I am just not seeing. Help would be greatly appreciated. Here is my epoch.yaml configuration if that helps. FYI…It passed the “epoch.yaml” tester.

sync:
port: 3115
external_port: 3015

keys:
dir: keys
peer_password: “secret”

http:
external:
port: 3013
internal:
port: 3113

websocket:
channel:
port: 3014

mining:
beneficiary:
cuckoo:
miner:
edge_bits: 29
executable: cuda29
extra_args: -d 0
autostart: true

chain:
persist: true
db_path: ./my_db

fork_management:
network_id: ae_mainnet

So I recompiled the miner successfully

Compilation of CUDA miner is done by invoking:

cd apps/aecuckoo && make cuda29

Finally the actual installation of the miner binary is copying it to the node corresponding path, the documentation assumes the epoch node is installed in ~/node directory.

cp priv/bin/cuda29 ~/node/lib/aecuckoo-0.1.0/priv/bin

I can mine wih a single GPU as before. How do you mine with multiple?

Thanks
Rob

Hey @ROB,

Here is the answer of our developers:
To use the multi_gpu you first need to checkout the right branch (multi_gpu) from the GitHub repository and build it. Once it is built it will recognize another configuration option (this is btw documented on the multi_gpu branch):

mining:
  cuckoo:
    miner:
      instances: N
      executable: ...
      ...

I hope that helps,
Albena

Sorry, that does not help. How exactly instances interact with extra_args: -d ?
Is it like this?
instances: 4
extra_args: -d 0,1,2,3
Or like this?
instances: 4
extra_args: -d 0 1 2 3
Or should we completely omit “-d” and use only new option “instances”?
I can’t make my multi-GPU rig work yet.

1 Like

I too can’t get it to work. I followed the epoch/docs/installation.md on the multi_GPU branch on Github. I built the node from release binary epoch-1.0.0-ubuntu-x86_64.tar.gz. I have tried to use the instances: N in many diffident configuration and none of them pass the check tool.

Any guidance would be greatly appreciated

You have to build the multi_gpu branch or else it will not recognize the instances option - multi_gpu is not yet part of the binary release.

You should just leave the -d out of the extra_args completely, it will be added by the multi_gpu mining feature in the node… I realize this is not clear from the documentation, will try to get it updated!

So with instances: 2 the node will launch cuda29 <extra_args> -d 0 and cuda29 <extra_args> -d 1.

1 Like

I apologize for my ignorance but can someone help out on the “build from multi-gpu branch”. I see the branch on githib but not sure how to build an node from that branch.

Already helped out :slight_smile:

1 Like

So I rebuilt the epoch by cloning the multi_gpu branch and using the make prod-build. Completed without error. I added the “instances: 2”. I use the check tool and it fails…again. I test it OK before the “instances” line and it OK. Here is the output.
Validation failed
Position: mining/cuckoominer/instances
Value : #{<<101,100,103,101,95,98,105,116,115>>=>29,<<101,120,101,99,117,116,97,98,108,101>>=><<99,117,100,97,50,57>>,<<101,120,116,114,97,95,97,114,103,115>>=><<>>,<<105,110,115,116,97,110,99,101,115>>=>2}
Schema :
{
“additionalProperties”: false,
“properties”: {
“edge_bits”: {
“default”: 29,
“description”: “Number of bits used for representing an edge in the Cuckoo Cycle problem. It affects both PoW generation (mining) and verification. WARNING: Changing this makes the node incompatible with the chain of other nodes in the network, do not change from the default unless you know what you are doing.”,
“type”: “integer”
},
“executable”: {
“default”: “mean29-generic”,
“description”: “Executable binary of the miner. Options are: “mean29-generic” (memory-intensive), “mean29-avx2” (memory-intensive, benefits from faster CPU supporting AVX2 instructions), “lean29-generic” (CPU-intensive, useful if memory-constrained), “lean29-avx2” (CPU-intensive, useful if memory-constrained, benefits from faster CPU supporting AVX2 instructions).”,
“type”: “string”
},
“extra_args”: {
“default”: “-t 1”,
“description”: “Extra arguments to pass to the miner executable binary. The safest choice is specifying no arguments i.e. empty string.”,
“type”: “string”
},
“hex_encoded_header”: {
“default”: false,
“description”: “Hexadecimal encode the header argument that is send to the miner executable. CUDA executables expect hex encoded header.”,
“type”: “boolean”
},
“nice”: {
“description”: “Miner process priority (niceness) in a UNIX fashion. Higher nice means lower priority. Keep it unset to inherit parent process priority.”,
“type”: “integer”
}
},
“required”: [
“executable”,
“extra_args”,
“edge_bits”
],
“type”: “object”
}
Reason : No extra properties allowed
Configuration error (validation_failed)

Not sure where to go from here.

Hey @ROB,

Here’s the answer from our dev Hans:

So from the Schema it does look like something went wrong along the way. The config schema is indeed missing the “instances” key/field so it is not surprising that the check fails :frowning_face:

I.e. it seems you somehow compiled/installed the wrong thing. After checking out the multi_gpu branch (make sure you have a clean git repository) you could check the file apps/aeutils/priv/epoch_config_schema.json and make sure you have instances in the object mining > cuckoo > miner… Also when you install the prod-build make sure there are no old files lying around.\

1 Like

Not sure what is going on. I just removed the epoch and node directories and rebooted. Following the doc in the multople_gpu branch I i_t clone GitHub - aeternity/aeternity: æternity blockchain - scalable blockchain for the people - smart contracts, state channels, names, tokens epoch and made a successful production build.
I checked the file path you mention above and no mention I can see of “instances” Here is what is has. I dont know what I am doing wrong and I seem to be doing it wrong over and over. Mines fine with one GPU.

            "cuckoo" : {
                "type" : "object",
                "additionalProperties" : false,
                "properties" : {
                    "miner" : {
                        "type" : "object",
                        "additionalProperties" : false,
                        "required" : [
                            "executable",
                            "extra_args",
                            "edge_bits"
                        ],
                        "properties" : {
                            "executable" : {
                                "description" : "Executable binary of the miner. Options are: \"mean29-generic\" (memory-intensive), \"mean29-avx2\" (memory-intensive, benefits from faster CPU supporting AVX2 instructions), \"lean29-generic\" (CPU-intensive, useful if memory-constrained), \"lean29-avx2\" (CPU-intensive, useful if memory-constrained, benefits from faster CPU supporting AVX2 instructions).",
                                "type" : "string",
                                "default": "mean29-generic"
                            },
                            "extra_args" : {
                                "description" : "Extra arguments to pass to the miner executable binary. The safest choice is specifying no arguments i.e. empty string.",
                                "type" : "string",
                                "default": "-t 1"
                            },
                            "edge_bits" : {
                                "description" : "Number of bits used for representing an edge in the Cuckoo Cycle problem. It affects both PoW generation (mining) and verification. WARNING: Changing this makes the node incompatible with the chain of other nodes in the network, do not change from the default unless you know what you are doing.",
                                "type": "integer",
                                "default": 29
                            },
                            "hex_encoded_header" : {
                                "description" : "Hexadecimal encode the header argument that is send to the miner executable. CUDA executables expect hex encoded header.",
                                "type": "boolean",
                                "default": false
                            },
                            "nice" : {
                                "description" : "Miner process priority (niceness) in a UNIX fashion. Higher `nice` means lower priority. Keep it unset to inherit parent process priority.",
                                "type": "integer"
                            }
                        }
                    }
                }
            }
        }
    },

You also have to checkout the right branch:

git clone GitHub - aeternity/aeternity: æternity blockchain - scalable blockchain for the people - smart contracts, state channels, names, tokens epoch
cd epoch
git checkout multi_gpu

Got it up an going with multiple GPU’s now. It was me being an idiot but wanted to thank @doge for helping me out!

2 Likes

Do you get blocks ? Because I got none for 14 hours with 20 1080tis

1 Like

There are some real heavy hitters mining. Every 3rd or so block goes to one of 3 miners. There are 5 or so miners solving a majority of blocks. I am not one of them but I will keep trying.

2 Likes