http://127.0.0.1:1313/post/2022/2022-3-14-XuperChain/
第一天:
安装部署
- 阅读 资料
- 安装:XuperScan 区块链浏览器
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
export GOPROXY=https://goproxy.cn,direct
cd /root/xuperchain/output
# 启动xuper链
sh control.sh start
# check服务运行状况
bin/xchain-cli status -H 127.0.0.1:37101
wget https://nodejs.org/dist/v16.14.0/node-v16.14.0.tar.gz
VERSION=v16.14.0
DISTRO=linux-x64
export PATH=/usr/local/nodejs/bin/:$PATH
yum install -y nodejs
node -v
v16.14.0
npm -v
8.3.1
wget https://github.com/xuperchain/xuperscan/releases/download/v0.1.1/xuperindexer-linux-amd64.zip
unzip xuperindexer-linux-amd64.zip -d xuperindexer
cd xuperindexer
启动浏览器后端服务
bin/xindexer
https://xuper.baidu.com/n/ps/opensource
|
- 超级链基本操作
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
https://xuper.baidu.com/n/xuperdoc/quickstart/quickstart.html#basic-operation
[root@localhost output]# bin/xchain-cli account newkeys --output data/bob
create account using crypto type default
create account in data/bob
[root@localhost output]# bin/xchain-cli account new --account 1111111111111111 --fee 2000
contract response:
{
"pm": {
"rule": 1,
"acceptValue": 1.0
},
"aksWeight": {
"TeyyPLpp9L7QAcxHangtcHTu7HUZ6iydY": 1.0
}
}
The gas you cousume is: 1000
The fee you pay is: 2000
Tx id: 788d1e22e0c7b2453612be82eb9ddd8382667fc9d960ddf89b6418a5c4e8f58e
account name: XC1111111111111111@xuper
# 根据账户存储的路径,查询该账户的余额。--keys为要查询的账户的地址
bin/xchain-cli account balance --keys data/bob
bin/xchain-cli account balance Ts98cm9eKqwqDZ6tFRCmZ9Nb8QQgp3HeT
|