Closed xgocn closed 1 month ago
the second node:
root@xiangtu:~# hisweave/bin/start peer node1IP:1979 data_dir /root/hisweave-data mining_addr Y0vGB IgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA storage_module 0,Y0vGBIgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA mine max_disk_pool_buffer_mb 1 port 1979 Arweave launch script: hisweave/bin/start Arweave launch script: /root/hisweave/bin/arweave Arweave launch options: +Ktrue +A1024 +SDio1024 +MBsbct 103424 +MBsmbcs 10240 +MBlmbcs 410629 +MBmmmbc 1024 +MBas aobf +sbwtvery_long +sbwtdcpuvery_long +sbwtdiovery_long +swtvery_low +swtdcpuvery_low +swtdiovery_low +Bi peer node1IP:1979 data_dir /root/hisweave-data mining_addr Y0vGBIgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA storage_module 0,Y0vGBIgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA mine max_disk_pool_buffer_mb 1 port 1979 Custom Erlang Options: Launching Erlang Virtual Machine... Exec: /root/hisweave/erts-12.2.1/bin/erlexec -noinput +Bd -boot /root/hisweave/releases/2.7.4/start -mode embedded -boot_var SYSTEM_LIB_DIR /root/hisweave/lib -config /root/hisweave/releases/2.7.4/sys.config -args_file /root/hisweave/releases/2.7.4/vm.args -- foreground +Ktrue +A1024 +SDio1024 +MBsbct 103424 +MBsmbcs 10240 +MBlmbcs 410629 +MBmmmbc 1024 +MBas aobf +sbwtvery_long +sbwtdcpuvery_long +sbwtdiovery_long +swtvery_low +swtdcpuvery_low +swtdiovery_low +Bi -run ar main peer node1IP:1979 data_dir /root/hisweave-data mining_addr Y0vGBIgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA storage_module 0,Y0vGBIgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA mine max_disk_pool_buffer_mb 1 port 1979 Root: /root/hisweave /root/hisweave =INFO REPORT==== 12-Aug-2024::17:56:36.774914 === alarm_handler: {set,{system_memory_high_watermark,[]}}
VDF step computed in 0.05 seconds.
2024-08-12T17:57:08.238882+08:00 [error] ar_join:get_block_index/2:88 event: failed_to_fetch_block_index [os_mon] cpu supervisor port (cpu_sup): Erlang has closed [os_mon] memory supervisor port (memsup): Erlang has closed Arweave Heartbeat: Server terminated safely.
when I restart the second node:
root@xiangtu:~# hisweave/bin/start peer node1IP:1979 data_dir /root/hisweave-data mining_addr Y0vGBIgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA storage_module 0,Y0vGBIgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA mine max_disk_pool_buffer_mb 1 port 1979 Arweave launch script: hisweave/bin/start Arweave launch script: /root/hisweave/bin/arweave Arweave launch options: +Ktrue +A1024 +SDio1024 +MBsbct 103424 +MBsmbcs 10240 +MBlmbcs 410629 +MBmmmbc 1024 +MBas aobf +sbwtvery_long +sbwtdcpuvery_long +sbwtdiovery_long +swtvery_low +swtdcpuvery_low +swtdiovery_low +Bi peer node1IP:1979 data_dir /root/hisweave-data mining_addr Y0vGBIgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA storage_module 0,Y0vGBIgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA mine max_disk_pool_buffer_mb 1 port 1979 Custom Erlang Options: Launching Erlang Virtual Machine... Exec: /root/hisweave/erts-12.2.1/bin/erlexec -noinput +Bd -boot /root/hisweave/releases/2.7.4/start -mode embedded -boot_var SYSTEM_LIB_DIR /root/hisweave/lib -config /root/hisweave/releases/2.7.4/sys.config -args_file /root/hisweave/releases/2.7.4/vm.args -- foreground +Ktrue +A1024 +SDio1024 +MBsbct 103424 +MBsmbcs 10240 +MBlmbcs 410629 +MBmmmbc 1024 +MBas aobf +sbwtvery_long +sbwtdcpuvery_long +sbwtdiovery_long +swtvery_low +swtdcpuvery_low +swtdiovery_low +Bi -run ar main peer node1IP:1979 data_dir /root/hisweave-data mining_addr Y0vGBIgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA storage_module 0,Y0vGBIgGBHCSgCEgaxju-9_9wiXpYueaaptbctPrYAA mine max_disk_pool_buffer_mb 1 port 1979 Root: /root/hisweave /root/hisweave =INFO REPORT==== 12-Aug-2024::18:03:15.097893 === alarm_handler: {set,{system_memory_high_watermark,[]}}
VDF step computed in 0.05 seconds.
dets: file "/root/hisweave-data/ar_tx_blacklist/ar_tx_blacklist" not properly closed, repairing ... dets: file "/root/hisweave-data/ar_tx_blacklist/ar_tx_blacklist_pending_headers" not properly closed, repairing ... dets: file "/root/hisweave-data/ar_tx_blacklist/ar_tx_blacklist_pending_data" not properly closed, repairing ... dets: file "/root/hisweave-data/ar_tx_blacklist/ar_tx_blacklist_offsets" not properly closed, repairing ... dets: file "/root/hisweave-data/ar_tx_blacklist/ar_tx_blacklist_pending_restore_headers" not properly closed, repairing ... 2024-08-12T18:03:46.471533+08:00 [error] ar_join:get_block_index/2:88 event: failed_to_fetch_block_index [os_mon] memory supervisor port (memsup): Erlang has closed [os_mon] cpu supervisor port (cpu_sup): Erlang has closed Arweave Heartbeat: Server terminated safely.
{"version":5,"release":71,"queue_length":0,"peers":1,"node_state_latency":0,"network":"hisweave","height":-1,"current":"not_joined","blocks":0}
@xgocn I think the problem here is that you really need to build the localnet
release from scratch.
To do that you need to
git clone --recurse-submodules https://github.com/ArweaveTeam/arweave.git
);ar-rebar3 localnet release
command.Alternatively, if you want to hack the arweave source code or play with something else, you can take a look at localnet
profile, you will see the list of parameters you can alter with ERL_COMPILER_OPTIONS
env variable.
Note, that these will only make any difference if you will be recompiling the source from scratch (ensure to run ./rebar3 clean
or just remove the _build
directory)
thank you for your help.
I have followed the setup instructions and configured the hisweave
profile in rebar.config
. However, when I attempt to start mining, I encounter the following error:
error: {{badmatch,false},[{ar_wallets,set_current,4,[{file,"/root/arweave/apps/ar_wallets.erl"},{line,382}]},{ar_wallets,initialize_state,2,[{file,"/root/arweave/apps/ar_wallets.erl"},{line,255}]}...
Modify rebar.config
to add a new profile hisweave
with the following configuration:
{hisweave, [
{relx, [
{dev_mode, false},
{include_erts, true}
]},
{erl_opts, [
{d, 'DEBUG', debug},
{d, 'NETWORK_NAME', "hisweave"}
]}
]}
Install Erlang and dependencies:
sudo apt update
sudo apt install -y erlang
Build the release:
./rebar3 as hisweave tar
Extract and configure the node:
mv _build/hisweave/rel/arweave/arweave-2.7.4.tar.gz ./
tar -zxvf arweave-2.7.4.tar.gz -C ./hisweave
~/hisweave/bin/create-wallet ~/hisweave-data
Attempt to start mining:
./hisweave/bin/start init data_dir /root/hisweave-data mining_addr <my_address> storage_module 0,<my_address> mine max_disk_pool_buffer_mb 1 port 1979
was this right?
@xgocn The part you're missing is {d, 'FORKS_RESET', true}
setting in localnet
profile. What this actually does is resetting the hardfork heights to zero, allowing you to start the new weave with the latest code.
Try to add this option to your profile, delete the _build
directory and rebuild the release.
ok. thank you, I'll try it
IT WORKS!
By the way, if I add {d, 'DEBUG', debug} and {d, 'TEST', true}, will these two options prevent hisweave
from becoming a production environment?Or, what difference will it bring to the running results?
@xgocn actually there are two ways to ensure this: change the network name and the list of trusted peers. The network name is changed with compilation flag, and the list of peers is defined in the start arguments of the node.
I'll close this issue as resolved for now. If you have any further questions, consider joining the Arweave discord server and asking the questions there.
ok,thank u!
I am attempting to set up a custom Arweave network for educational purposes on port 1979 and encountered an issue when trying to start mining.
how to resolve the errors?
Thank you for your help!