入门-windows下安装ETH挖矿

访客 阅读:21 2024-06-27 18:48:37 评论:0
美化布局示例

欧易(OKX)最新版本

【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   全球官网 大陆官网

币安(Binance)最新版本

币安交易所app【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址

火币HTX最新版本

火币老牌交易所【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址

对刚入门的区块链开发者来说,刚开始可以在windows本地搭建私有链,便于操作,毕竟,要想真正挖到币还是有难度的,下面以ETH为例,在windows环境下安装并实现挖矿。

For the newly introduced block chain developers, private chains can be built locally in Windows for ease of operation. After all, it is difficult to actually dig money, for example, to install and dig in the Windows environment.

步骤一、安装geth环境。下载地址:https://geth.ethereum.org/downloads/

Step one, install the geth environment. Download:

选择对应操作系统的版本下载安装。下载完安装到对应本地目录,如:E\BlockChain\ETH\Geth

Select the version of the download installation for the corresponding operating system. After downloading, install it to the corresponding local directory, for example: E\BlockChain\ETH\

步骤二、配置初始化用的创世纪文件,命名genesis.json,放到geth的执行目录,内容格式参考如下:

Step two. Configure the original Genesis file, name genesis.json, in the executive directory of geth, in the following format:

{
"config": {
"chainId": 10,
"homesteadBlock": 0,
"eip155Block": 0,
"eip158Block": 0
},
"alloc" : {},
"coinbase" : "0x0000000000000000000000000000000000000000",
"difficulty" : "0x02000000",
"extraData" : "",
"gasLimit" : "0x2fefd8",
"nonce" : "0x0000000000000042",
"mixhash" : "0x0000000000000000000000000000000000000000000000000000000000000000",
"parentHash" : "0x0000000000000000000000000000000000000000000000000000000000000000",
"timestamp" : "0x00"
}

步骤三、初始化:geth --datadir "E:\BlockChain\ETH\Geth\data" init genesis.json

Step three, initialization: geth-datadir "E: \Blockchain\ETH\data" init genesis.json

步骤四、启动服务:geth --datadir=E:\BlockChain\ETH\Geth\data --rpc --rpcport 8545 --rpcaddr "0.0.0.0"  --rpcapi "personal,db,eth,net,web3" console

Step IV. Start-up services: geth-datadir=E: \BlockChain\ETH\ETH\data-rpc-rpcport 8545-rpcaddr "0.0.0.0"  rpcapi "personal, db,eth,net, web3" console

步骤五、创建账户:personal.newAccount("你的密码")

Step five, create account: personal.newAcaccount

  会返回一个钱包地址

returns a wallet address

步骤六、开始挖矿:miner.start(1)

Step VI. Commencement of mining: miner.start (1)

  其中1位线程个数,可以适当调整

Of which 1 number of threads can be adjusted appropriately

步骤七、查看挖矿状态:eth.mining

Step 7. Viewing the state of mining: eth.mining

  查看区块高度:eth.blockNumber

View block height: Eth. BlockNumber

  查看账户余额:eth.getBalance(eth.accounts[0]) 或 eth.getBalance("地址")

View account balances: eth. GetBallance (eth. accounts [0]) or eth.getBallance("Address")

  停止挖矿:miner.stop()

Stop mining: mine.stop()

也可以在本地安装ETH钱包,实现账户可视化

The ETH wallet can also be installed locally to make the account visible

步骤一、下载ETH钱包:https://github.com/ethereum/mist/releases

Step I: Download ETH wallet:

  注意版本,安装完打开后会提示更新

Note version. Update when installed and open

步骤二、安装:可以选择geth的安装目录,E:\BlockChain\ETH\Geth\data

Step two, installation: you can choose the installation directory for geth, E:\Blockchain\ETH\data\

  安装完打开钱包,如下:

Open wallet after installation as follows:

 

文字格式和图片示例

注册有任何问题请添加 微信:MVIP619 拉你进入群

弹窗与图片大小一致 文章转载注明 网址:
https://netpsp.com/?id=69191

美化布局示例

欧易(OKX)最新版本

【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   全球官网 大陆官网

币安(Binance)最新版本

币安交易所app【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址

火币HTX最新版本

火币老牌交易所【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址
可以去百度分享获取分享代码输入这里。
声明

1.本站遵循行业规范,任何转载的稿件都会明确标注作者和来源;2.本站的原创文章,请转载时务必注明文章作者和来源,不尊重原创的行为我们将追究责任;3.作者投稿可能会经我们编辑修改或补充。

发表评论
平台列表
美化布局示例

欧易(OKX)

  全球官网 大陆官网

币安(Binance)

  官网

火币(HTX)

  官网

Gate.io

  官网

Bitget

  官网

deepcoin

  官网
关注我们

若遇到问题,加微信客服---清歌

搜索
排行榜
扫一扫,加我为微信好友加我为微信好友