Execoin is a new scrypt ASIC-proof and multipool-mining resistant cryptocurrency that can be effectively mined via P2Pool.
This guide will show you how to configure p2pool node software for Execoin, how to join ether the official (and largest) Execoin P2Pool network or a smaller low-hash rate P2Pool network and establish your node as a mining operator peer. We will be using a fork of the original Bitcoin p2pool software, called zen2pool, that has been optimized for scrypt- and progressive-N scrypt-based altcoins.
If want try P2Pool by just mining at an existing pool, rather than installing and configuring your own node, go ahead and download a customized Execoin version of your favorite miner and point it at this P2Pool node. Miner command line parameters are given below.
Some prerequisites need to be installed (Windows installation instructions), and the rest of this guide will illustrate the process for Ubuntu Linux. It is assumed that you already have a local instance of the execoind daemon running with the following parameters:
$ ./execoind -daemon -server -rpcallowip=127.0.0.1
The P2Pool software will later connect to the execoind in server mode and will relay mining software RPC communication via the localhost.
Install Linux package dependencies:
$ sudo apt-get install git python-zope.interface python-twisted python-twisted-web
Now clone the zen2pool source code from GitHub to a local directory (git will automatically create the source directory):
$ git clone https://github.com/venzen/zen2pool.git
Change into the directory and have a look around:
$ cd ./zen2pool $ ls -l
Both the generic and progressive-N scrypt modules are included. Let’s build both while we’re at it:
cd py_modules cd litecoin_scrypt sudo python setup.py install cd ../vertcoin_scrypt sudo python setup.py install
At this point, we are ready to start the P2Pool node, but for the sake of readers who may be configuring existing p2pool installations, we need to provide the Execoin specific configuration settings. These are pre-configured in zen2pool so you can skip the next section if you’re not customizing an existing p2pool software installation.
Execoin-specific configuration settings need to be placed in two files in p2pool. Your p2pool installation includes a p2pool/ subdirectory, which, in turn, contains a bitcoin/ subdirectory. We will be adding dictionary items to two files (both called networks.py) in these subdirectories. Add the code below after the first (usually bitcoin) entry for convenience.
The file p2pool/networks.py contains definitions that determine how p2pool will build the Execoin sharechain. Some of these settings can be tweaked to the mining operator’s context, but for now some failsafe values to get started.
execoin_zen=math.Object( PARENT=networks.nets['execoin'], SHARE_PERIOD=9, # seconds CHAIN_LENGTH=24*60*60//10, # shares REAL_CHAIN_LENGTH=24*60*60//10, # shares TARGET_LOOKBEHIND=200, # shares SPREAD=40, # blocks IDENTIFIER='657865636f696e65'.decode('hex'), PREFIX='65657865636f696e'.decode('hex'), P2P_PORT=9172, MIN_TARGET=0, MAX_TARGET=2**256//2**20 - 1, PERSIST=True, WORKER_PORT=9173, BOOTSTRAP_ADDRS='184.108.40.206'.split(' '), ANNOUNCE_CHANNEL='#p2pool-exe', VERSION_CHECK=lambda v: True, VERSION_WARNING=lambda v: 'Upgrade Execoin to >=0.8.5.1!' if v < 80501 else None, ),
The critical value that should remain unchanged in the file above is
This is the port over which the Execoin P2Pool network communicates the sharechain. In order for your node to join the network, it will use the P2P_PORT to bootstrap the sharechain and find other nodes with which to form peer-to-peer connections.
Also, the PERSIST setting should be set to “True”.
The p2pool/bitcoin/networks.py file tells the p2pool software about the cryptocurrency parameters of Execoin – its block time, subsidy amount, and so forth. Notice that this file also defines the execoind port, as well as the execoind RPC port. These settings should not be changed without good reason.
execoin_zen=math.Object( P2P_PREFIX='fabfb5da'.decode('hex'), P2P_PORT=9989, ADDRESS_VERSION=33, RPC_PORT=9988, RPC_CHECK=defer.inlineCallbacks(lambda bitcoind: defer.returnValue( 'execoinaddress' in (yield bitcoind.rpc_help()) and not (yield bitcoind.rpc_getinfo())['testnet'] )), SUBSIDY_FUNC=lambda height: 50*100000000 >> (height + 1)//840000, POW_FUNC=lambda data: pack.IntType(256).unpack(__import__('vtc_scrypt').getPoWHash(data)), BLOCK_PERIOD=45, # s SYMBOL='EXE', CONF_FILE_FUNC=lambda: os.path.join(os.path.join(os.environ['APPDATA'], 'Execoin') if platform.system() == 'Windows' else os.path.expanduser('~/Library/Application Support/Execoin/') if platform.system() == 'Darwin' else os.path.expanduser('~/.execoin'), 'execoin.conf'), BLOCK_EXPLORER_URL_PREFIX='https://altexplorer.net/block/', ADDRESS_EXPLORER_URL_PREFIX='https://altexplorer.net/address/', TX_EXPLORER_URL_PREFIX='https://altexplorer.net/tx/', SANE_TARGET_RANGE=(2**256//1000000000 - 1, 2**256//1000 - 1), DUMB_SCRYPT_DIFF=2**16, DUST_THRESHOLD=1e8, ),
Ensure execoind is running as described above and determine the RPC username and password that execoind would have prompted you to create upon the first run:
$ cat ~/.execoin/execoin.conf rpcuser=execoinrpc rpcpassword=<longrandomcharacterpassword>
Make sure you’re in the zen2pool application root directory. We are going to start zen2pool with the following parameters:
–net tells zen2pool to use the ‘execoin_zen’ definition in the networks.py files. zen2pool will automatically retrieve your execoind RPC login credentials from ~/.execoin/execoin.conf
To join the “official” (and largest, hence more competitive) Execoin P2Pool network, substitute ‘execoin_zen’ with ‘execoin’.
Execute the complete command:
$ python run_zen2pool.py --net execoin_zen
You should see zen2pool start up and connect to execoind as well as the wider P2Pool network.
If zen2pool complains about “bitcoind” taking a long time – make sure execoind is running and that you are not passing it a -maxconnections= parameter.
If you see the message “Success” and lots of messages with “???” declarations, don’t worry, this is normal – zen2pool is bootstrapping the sharechain, and we have yet to point a miner at this node. Bootstrapping can take anywhere from a few minutes to an hour. We’ll continue setting up while this process runs.
Firstly, due to its built-in ASIC resistance, Execoin needs to be mined with specially compiled versions of most popular mining software. Binaries are available on the Execoin website.
zen2pool wants to pay you as soon as the network nodes (or you!) find a block, so you have to provide zen2pool with a wallet address to which payments will be sent. You do this by generating a new wallet address from a running execoind instance: ./execoind getnewaddress or by obtaining an Execoin paper wallet address from here. Pass this wallet address as your username in the miner software parameters. The password needs to be sent but it is irrelevant and you can simply use “pass”:
$ cgminer --scrypt -o https://127.0.0.1:9173 -u mywalletaddress -p pass
P2Pool does not react to mining software in the same way as other mining pool software does, so you may have to scale back on the intensity of GPU setting parameters.
Start your mining software and keep an eye on its output – it will not connect until zen2pool has finished downloading the sharechain – so this is a good time to grab some coffee!
Test your zen2pool web interface by pointing your browser at
Alternatively, if you’re running zen2pool on a remote server/VPS, substitute 127.0.0.1 with the remote IP address.
Once the sharechain has finished downloading, stop and restart zen2pool. At startup it will display progress of loading the sharechain from its local disk cache and then indicate that its ready for mining by displaying empty local and global P2Pool stats. Startup your mining software and once it has submitted work for about an hour, the statics will be meaningfully populated, and you can monitor your mining in relation to the wider P2Pool network as well as other useful metrics.
Please feel free to make comments or ask questions below.
Last modified (UTC): March 25, 2014 07:24