0. this guide assumes that you're running this playbook from the same machine that you used to make initial deployment of your node. So that you already have `python` and `ansible` installed, and you have the correct ssh keypair to root-access the node.
### Running the update
1. clone this repository if you haven't done so before
**NOTE** if you're getting ssh connection error, try to add option `-e 'ansible_ssh_user=ubuntu'` to the command line above, substituting `ubuntu` with correct ssh username, which is usually either `ubuntu` or `root` or `poa` or `centos` depending on your setup
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
By Wood/Paronyan/Kotewicz/Drwięga/Volf
Habermeier/Czaban/Greeff/Gotchac/Redmann
```
3. during the following day check status of your node on network status webpage and associated functions (e.g. for validators - are block rewards still being sent from your mining key to your payout key).
### Rollback to the previous version (in case of problems)
**NOTE**: if you get any errors please consult the POA Team first, probably you have a minor issue and don't need to rollback
1. connect to the node:
```
ssh root@192.0.2.1
```
2. switch to your home folder (replace `bootnode` with correct role name):
```
cd /home/bootnode
```
3. stop services:
```
systemctl stop poa-netstats
systemctl stop poa-parity
```
4. locate the backup folder:
```
ls backups-version
```
it contains folders labeled by the time backup was created in format`<year><month><day>T<hour><minute><second>`, e.g.
```
# ls backups-version
20180208T152105 20180209T214517
```
copy the version number that corresponds to this day. In the following examples we assume that it's `20180209T214517`.
5. make sure you have your mining key data (keyfile, password, address) available to you
6. remove files from the new version:
```
rm -rf parity_data
rm parity
rm node.toml
```
7. restore previous versions of these files from backup (note dots `.` at the end of each line here, they are important):
```
cp -a backups-version/20180209T214517/parity .
cp -a backups-version/20180209T214517/parity_data .