eth搭建私链(「亲测」搭建基于以太坊go-ethereum的私有链)

  eth搭建私链(「亲测」搭建基于以太坊go-ethereum的私有链)

一、基础环境:

  

1、购买两台服务器一周使用期

  

2、比特币期货选择系统Ubuntu 16-18 我选64位、带宽1M 2CPU 经费有限 仅需验证

  

3、npm、nodejs 安装

  

购买测试服务器

  

sudo apt-get install software-properties-commonsudo add-apt-repository -y ppa!ethereum/ethereumsudo add-apt-repository -y ppa!ethereum/ethereum-devsudo apt-get updatesudo apt-get install ethereum

SSH 进入Ubuntu 18 服务器1

  

部署后:启动配置

  

geth --datadir mydata --networkid 8888 --rpc --rpccorsdomain ";*"; --nodiscover --port 30303 --allow-insecure-unlock --rpcport 8545 console


  

启动 私有链节点

  

miner。start()

启动挖矿 等待10分钟 挖矿成功

  

查询账号

  

eth。accounts


  

我创建过两个账号

  

进入控制台 创建新账户

  

personal。newAccount(";123456";) #括号里面 设置密码


  

创建新账户

  

查询挖矿后的创世币

  

  

eth。getBalance(";0xc49589e8051cf5f1a0dae6b067d6ed714168db74";)


  
","content_hash"!"4d18f558

版权声明

本文仅代表作者观点,不代表本站立场。
本文系作者授权发表,未经许可,不得转载。

评论