mirror of
https://github.com/raspiblitz/raspiblitz.git
synced 2025-09-27 20:16:22 +02:00
fix copy host
This commit is contained in:
@@ -99,18 +99,18 @@ copyHost()
|
|||||||
cd /mnt/hdd/${network}
|
cd /mnt/hdd/${network}
|
||||||
|
|
||||||
# transfere beginning flag
|
# transfere beginning flag
|
||||||
date +%s > ./copy_begin.time
|
date +%s > /home/admin/copy_begin.time
|
||||||
sudo sshpass -p "${targetPassword}" rsync -avhW -e 'ssh -o StrictHostKeyChecking=no -p 22' ./copy_begin.time bitcoin@${targetIP}:/mnt/hdd/bitcoin
|
sudo sshpass -p "${targetPassword}" rsync -avhW -e 'ssh -o StrictHostKeyChecking=no -p 22' /home/admin/copy_begin.time bitcoin@${targetIP}:/mnt/hdd/bitcoin
|
||||||
rm ./copy_begin.time
|
sudo -f rm /home/admin/copy_begin.time
|
||||||
|
|
||||||
# transfere blockchain data
|
# transfere blockchain data
|
||||||
sudo sshpass -p "${targetPassword}" rsync -avhW -e 'ssh -o StrictHostKeyChecking=no -p 22' --info=progress2 ./chainstate ./blocks bitcoin@${targetIP}:/mnt/hdd/bitcoin
|
sudo sshpass -p "${targetPassword}" rsync -avhW -e 'ssh -o StrictHostKeyChecking=no -p 22' --info=progress2 ./chainstate ./blocks bitcoin@${targetIP}:/mnt/hdd/bitcoin
|
||||||
sed -i "s/^state=.*/state=/g" /home/admin/raspiblitz.info
|
sed -i "s/^state=.*/state=/g" /home/admin/raspiblitz.info
|
||||||
|
|
||||||
# transfere end flag
|
# transfere end flag
|
||||||
date +%s > ./copy_end.time
|
date +%s > /home/admin/copy_end.time
|
||||||
sudo sshpass -p "${targetPassword}" rsync -avhW -e 'ssh -o StrictHostKeyChecking=no -p 22' ./copy_end.time bitcoin@${targetIP}:/mnt/hdd/bitcoin
|
sudo sshpass -p "${targetPassword}" rsync -avhW -e 'ssh -o StrictHostKeyChecking=no -p 22' /home/admin/copy_end.time bitcoin@${targetIP}:/mnt/hdd/bitcoin
|
||||||
rm ./copy_end.time
|
sudo -f rm /home/admin/copy_end.time
|
||||||
|
|
||||||
echo "# start services again ..."
|
echo "# start services again ..."
|
||||||
sudo systemctl enable ${network}d
|
sudo systemctl enable ${network}d
|
||||||
|
Reference in New Issue
Block a user