z-classic / z-nomp

z-nomp is mining pool software for Zcash and Zclassic so you can create internet money in your home!
MIT License
291 stars 437 forks source link

Code -9 #287

Closed empty333 closed 6 years ago

empty333 commented 6 years ago

console

[Server] Website started on 0.0.0.0:8080
2018-02-09 17:52:07 [Master]    [PoolSpawner] Spawned 1 pool(s) on 2 thread(s)
2018-02-09 17:52:07 [Switching] [Setup] (Thread 1) Loading last proxy state from redis
2018-02-09 17:52:07 [Pool]      [zclassic] (Thread 1) Share processing setup with redis (127.0.0.1:6379)
2018-02-09 17:52:07 [Pool]      [zclassic] (Thread 1) getblocktemplate call failed for daemon instance 0 with error {"code":-9,"message":"Zcash is not connected!"}
2018-02-09 17:52:07 [Pool]      [zclassic] (Thread 1) Error with getblocktemplate on creating first job, server cannot start
2018-02-09 17:52:07 [Switching] [Setup] (Thread 2) Loading last proxy state from redis
2018-02-09 17:52:07 [Pool]      [zclassic] (Thread 2) Share processing setup with redis (127.0.0.1:6379)
2018-02-09 17:52:07 [Pool]      [zclassic] (Thread 2) getblocktemplate call failed for daemon instance 0 with error {"code":-9,"message":"Zcash is not connected!"}
2018-02-09 17:52:07 [Pool]      [zclassic] (Thread 2) Error with getblocktemplate on creating first job, server cannot start

zclassic.conf

daemon=1
rpcuser=xxxxxx
rpcpassword=xxxxxx
rpcport=8232
gen=1
blocknotify=node /home/nick/z-nomp/scripts/cli.js blocknotify zclassic %s

addnode=dnsseed.zclassic.org
addnode=dnsseed.rotorproject.org

zclassic.json

"enabled": true,
    "coin": "zclassic.json",

    "address": "t1R16r9iqKjWos2uTdPFAUzps7A1MNN5MC3",
    "_comment_address": "a transparent address to send coinbase rewards to and to transfer to zAddress.",

    "zAddress": "zcak2yv28RG2dYZTaP1KDDRtLYSfeUJ8z1x5yZH4zN8Rf4FcjHxuoJe1Cqn62xvbrJiS9kCKLKPceSmuG1vAsyBqcG6EWvR",
    "_comment_zAddress": "a private address used to send coins to tAddress.",

    "tAddress": "t1R16r9iqKjWos2uTdPFAUzps7A1MNN5MC3",
    "_comment_tAddress": "transparent address used to send payments, make this a different address, otherwise payments will not send",

    "walletInterval": 2.5,

    "rewardRecipients": {
        "": 0.2,
        "": 0.3
    },

    "tlsOptions": {
        "enabled": false,
        "serverKey":"",
        "serverCert":"",
        "ca":""
    },

    "paymentProcessing": {
    "minConf": 10,
        "enabled": true,
        "paymentMode": "prop",
        "_comment_paymentMode":"prop, pplnt",
        "paymentInterval": 600,
        "minimumPayment": 0.0001,
        "maxBlocksPerPayment": 3,
        "daemon": {
            "host": "127.0.0.1",
            "port": 8232,
            "user": "XXXXXX",
            "password": "XXXXXX"
        }
    },

    "ports": {
        "3032": {
            "tls":false,
            "diff": 0.05,
            "varDiff": {
                "minDiff": 0.04,
                "maxDiff": 16,
                "targetTime": 15,
                "retargetTime": 60,
                "variancePercent": 30
            }
        }
    },

    "daemons": [
        {
            "host": "127.0.0.1",
            "port": 8232,
            "user": "XXXXXXX",
            "password": "XXXXXX"
        }
    ],

    "p2p": {
        "enabled": false,
        "host": "127.0.0.1",
        "port": 19333,
        "disableTransactions": true
    },

    "mposMode": {
        "enabled": false,
        "host": "127.0.0.1",
        "port": 3306,
        "user": "XXXX",
        "password": "XXXXXX",
        "database": "XXXXX",
        "checkPassword": true,
        "autoCreateWorker": false
    }

}

z-nomp - config.json

{
    "logLevel": "debug",
    "logColors": true,

    "cliPort": 17117,

    "clustering": {
        "enabled": true,
        "forks": "auto"
    },

    "defaultPoolConfigs": {
        "blockRefreshInterval": 500,
        "jobRebroadcastTimeout": 55,
        "connectionTimeout": 600,
        "emitInvalidBlockHashes": false,
        "validateWorkerUsername": true,
        "tcpProxyProtocol": false,
        "banning": {
            "enabled": true,
            "time": 600,
            "invalidPercent": 50,
            "checkThreshold": 500,
            "purgeInterval": 300
        },
        "redis": {
            "host": "127.0.0.1",
            "port": 6379,
            "password": ""
        }
    },

    "website": {
        "enabled": true,
        "host": "0.0.0.0",
        "port": 8080,
        "stratumHost": "cryppit.com",
        "stats": {
            "updateInterval": 30,
            "historicalRetention": 14400,
            "hashrateWindow": 300
        },
        "adminCenter": {
            "enabled": true,
            "password": "326710"
        },
        "tlsOptions" : {
            "enabled": false,
            "cert": "",
            "key": ""
        }
    },

    "redis": {
        "host": "127.0.0.1",
        "port": 6379
    },

    "switching": {
        "switch1": {
            "enabled": false,
            "algorithm": "equihash",
            "ports": {
                "3032": {
                    "diff": 0.05,
                    "varDiff": {
                         "minDiff": 0.04,
                         "maxDiff": 4096,
                         "targetTime": 15,
                         "retargetTime": 90,
                         "variancePercent": 30
                    }
                }
            }
        },
        "switch2": {
            "enabled": false,
            "algorithm": "scrypt",
            "ports": {
                "4444": {
                    "diff": 10,
                    "varDiff": {
                        "minDiff": 16,
                        "maxDiff": 512,
                        "targetTime": 15,
                        "retargetTime": 90,
                        "variancePercent": 30
                    }
                }
            }
        },
        "switch3": {
            "enabled": false,
            "algorithm": "x11",
            "ports": {
                "5555": {
                    "diff": 0.001,
                    "varDiff": {
                        "minDiff": 0.001,
                        "maxDiff": 1,
                        "targetTime": 15,
                        "retargetTime": 60,
                        "variancePercent": 30
                    }
                }
            }
        }
    },

    "profitSwitch": {
        "enabled": false,
        "updateInterval": 600,
        "depth": 0.90,
        "usePoloniex": true,
        "useCryptsy": true,
        "useMintpal": true,
        "useBittrex": true
    }
}

Please help me figure out what the error is -9 ("Zcash is not connected!")

To start the zclassic daemon, use the string ./src/zcashd -txindex

empty333 commented 6 years ago

managed to run the z-classic coin demon with other nodes and the error was gone. For those who have the same problem, try adding zclassic.conf to the file

addnode=betthis.ddns.net
addnode=104.196.20.10
addnode=50.112.137.36
addnode=188.166.136.203
addnode=159.89.198.93
addnode=zcl.suprnova.cc
addnode=dnsseed.zclassic.org
addnode=dnsseed.rotorproject.org