github.com/aergoio/aergo@v1.3.1/consensus/impl/raftv2/test/test_join_syncer_crash.sh (about)

     1  #!/usr/bin/env bash
     2  echo "================= sync crash of joinned node and restart (nobackup) test ===================="
     3  
     4  BP_NAME=""
     5  source test_common.sh
     6  
     7  rm BP11004* BP11005*
     8  
     9  echo "kill_svr & clean 11004~11007"
    10  kill_svr.sh
    11  for i in  11004 11005 11006 11007; do
    12  	rm -rf ./data/$i
    13  	rm -rf ./BP$i.toml
    14  done
    15  
    16  TEST_SKIP_GENESIS=0 make_node.sh
    17  RUN_TEST_SCRIPT set_system_admin.sh
    18  
    19  #4 node add & crash
    20  DEBUG_SYNCER_CRASH=2 add_member.sh aergo4
    21  
    22  WaitShutdown 11004 30
    23  if [ "$?" = "0" ]; then
    24  	echo "failed to syncer crash of joined node 11004"
    25  	exit 100
    26  fi
    27  
    28  # 4 node restart
    29  run_svr.sh 11004
    30  checkSync 10001 10004 120 result