-
Notifications
You must be signed in to change notification settings - Fork 0
Mining
Webchaind is three-in-one : node of global webchain network, wallet and miner
You can make solo block mining with webchaind node or download Miner binaries and mine by pool . Also you can download Wallet binaries with GUI version
At first we need to run webchaind and create our wallet on which we will get mining rewards
Step 1. Downloading webchaind daemon/wallet and creating wallet number
Download webchaind according to your operating system from here - https://github.com/webchain-network/webchaind/releases and unpack it
From CMD, PowerShell or your preferred console, go to the route where you stored webchaind.exe.
Let’s say you stored webchain.exe in the recommended directory *$HOME\AppData\Roaming\Webchain/* <~ where $home is your C:\Users\UserName path
Input the following command: cd c:\users\UserName\AppData\Roaming\Webchain and hit enter
Once you’re there, you can write all the commands that webchaind.exe can execute!
Now we need to run console command, which create wallet in webchain network. Run from console:
webchaind.exe account new
For example you unpack it to /opt/webchaind/
in linux shell go to this folder by command cd /opt/webchaind/ run command from linux shell in this folder:
./webchaind account new
Result of command same for windows and linux , you will be prompted for password (enter it and save it in safe place!) and you will see you account wallet number:
Your new account is locked with a password. Please give a password. Do not forget this password. Passphrase: Repeat passphrase: Address: {918e173c8426593bd37d5bc7d03f17dcc154cd5b}
So 918e173c8426593bd37d5bc7d03f17dcc154cd5b is your wallet number.
Step 2. Running webchaind daemon/wallet console
Run command
webchain console (on Linux)
or
webchaind.exe console (Windows )
From same dir you stored webchaind binary
You will see initial screen from webchain.network and console prompt like
2018-05-10 21:40:54 webchaind version: v0.1.0 2018-05-10 21:40:54 Blockchain: Webchain Mainnet 2018-05-10 21:40:54 Chain database: /root/.webchain/mainnet/chaindata ..... coinbase: 0x918e173c8426593bd37d5bc7d03f17dcc154cd5b at block: 13041 (Thu, 10 May 2018 12:19:30 EEST) datadir: /root/.webchain/mainnet modules: admin:1.0 debug:1.0 eth:1.0 miner:1.0 net:1.0 personal:1.0 rpc:1.0 txpool:1.0 web3:1.0
>
So in this console you can run all commands to communicate with webchain network.
For example:
> webchain.coinbase "0x918e173c8426593bd37d5bc7d03f17dcc154cd5b"
will show you your based wallet number in system
web3.fromWei(webchain.getBalance(webchain.coinbase), "ether")
0
Will show your actual balance of your wallet, currently its 0 , but we will mine and it will grow up
Step 3. Mining
Mining is math process of confirmation next block with transactions in system. Approximately new block in webchain created every 10 minutes. Its no need to know much more even previous information to get money to wallet by mining :)
We download miner binary for your system from here https://github.com/webchain-network/webchain-miner/releases
Then unpack it and in dir of unpacked miner we see file config.json , which is our miner configuration file, which contains main mining setting, like wallet number, threads , max-cpu-usage , etc.
The main thing we need to do is to set your wallet number where we will get reward to config.json
So we put our wallet number created by webchaind to "user" field of config.json, it shoud be set like this:
"user": "0x918e173c8426593bd37d5bc7d03f17dcc154cd5b",
Now we can save config.json , start mining and get rewards
We ready to start miner, it done by command:
./webchain-miner (Linux)
or
webchain-miner.exe (Windows)
Now we will see screen like that:
./webchain-miner
- VERSIONS: webchain-miner/2.6.2 libuv/1.20.3-dev gcc/6.3.0
- CPU: Intel(R) Xeon(R) CPU D-1521 @ 2.40GHz (1) x64 AES-NI
- CPU L2/L3: 1.0 MB/6.0 MB
- THREADS: 5, cryptonight-webchain, av=1, donate=5%
- POOL #1: pool2.webchain.network:2222
- COMMANDS: hashrate, pause, resume
[2018-05-10 16:54:36] use pool pool2.webchain.network:2222 212.32.255.73
[2018-05-10 16:54:36] new job from pool2.webchain.network:2222 diff 5000 algo cn-web/1
[2018-05-10 16:54:36] READY (CPU) threads 5(5) huge pages 0/5 0% memory 10.0 MB
[2018-05-10 23:26:02] speed 2.5s/60s/15m 14.6 14.8 13.6 H/s max: 20.3 H/s
[2018-05-10 23:26:23] accepted (1/0) diff 5000 (170 ms)
Short description:
Pool is service which devide block finding task from webchain network between all miners in pool and also divide reward based on miners hashrate
Job is mining block finding task from network H/s is how much hashes in second your CPU can generate to find correct solution of block task accepted means your CPU found correct solution of task , send it to pool and it can be one of multiply correct block solution for what network will reward pool by 50 WEB, which will divide between miners based on their hasrate
So all you need is to run miner and wait some time (maybe 5 min, maybe 1 hour) when your miner find accepted shares and pool will give some part of reward coins to your account.
Step 4. Pool and payments
Currently we have 2 pools - pool.webchain.network:3333 and pool2.webchain.network:2222
The difference is in difficulty of block solution job First pool has 20000 difficulty, second pool has 5000 difficulty
If you have slow CPU so you should set your pool in config.json of miner to second pool - pool2.webchain.network:2222 because if you will not send accepted shares to pool you even cannot see your presence on mining pool
So we start mining and then open https://pool.webchain.network/
in search string below "Your Stats & Payment History" we put our wallet number:
0x918e173c8426593bd37d5bc7d03f17dcc154cd5b
and after miner send his first accepted share we will see realtime stats on top of page
First of all you will get coins in Immature Balance, it means you got coins from network, but they need confirmation. Pending Balance is your money already which wait pool payment schedule to pay to your wallet Total Paid: is how much money already sent from pool to your wallet Last Share Submitted means how much time ago your miner(s) submit accepted share to pool Workers Online means how much computers mine with the same wallet Hashrate (30m) and (3h) shows your common average from all your computers where you mining with this wallet number Blocks Found means how much block was found by your share solution Total payments means how much payment schedules was completed from pool with payment to your wallet Your round share is how much job of block solution your miner(s) do in comparison with all miners in pool
So when you will see some amount in Total paid, you can go back to your webchaind console and write command again:
web3.fromWei(webchain.getBalance(webchain.coinbase), "ether")
5
You will see other amount then 5 but it will be different from 0
If not, there can be some reason.
First - your webchaind not synchronizing with network. So you need some time to wait (maybe about 1 hour)
Also you can try to run
webchaind --fast console
and retry to get balance, or wait some time and try again
Second - your local time is not correct Check please your OS for how to resync your clock (example sudo ntpdate -s time.nist.gov) because even 12 seconds too fast can lead to 0 peers.
Also you can see your real time balance of coins at https://explorer.webchain.network, enter you wallet number at the right top of page and you will how much coins you have for now
How to transer funds you can see at Transfers
❤️ Stay Classy