Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Wiki Replica
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
The Tor Project
TPA
Wiki Replica
Commits
de9c8757
Commit
de9c8757
authored
5 years ago
by
Iain R. Learmonth
Browse files
Options
Downloads
Patches
Plain Diff
onionoo: upgrade
parent
5717c4f2
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
metrics/ops/onionoo-ops.mdwn
+27
-6
27 additions, 6 deletions
metrics/ops/onionoo-ops.mdwn
with
27 additions
and
6 deletions
metrics/ops/onionoo-ops.mdwn
+
27
−
6
View file @
de9c8757
...
...
@@ -104,10 +104,12 @@ The header for this template includes the command required to deploy the stack.
It will deploy in your local user's namespace (the output of whoami) and must
be provided with the name of your SSH key pair.
From the CloudFormation portal, select your stack and view the outputs. You
will find here the public IP address for the EC2 instance that has been created.
Add this instance to *ansible/dev* in your local copy of metrics-cloud.git
under "[onionoo-backends]".
From the [CloudFormation
portal](https://console.aws.amazon.com/cloudformation/home?region=us-east-1#/stacks),
select your stack and view the outputs. You will find here the public IP
address for the EC2 instance that has been created. Add this instance to
*ansible/dev* in your local copy of metrics-cloud.git under
"[onionoo-backends]".
You can now setup the machine with Ansible by running:
...
...
@@ -115,6 +117,8 @@ You can now setup the machine with Ansible by running:
ansible-playbook -i dev oninooo-backends-aws.yml
```
Note that the AWS AMI used has passwordless sudo, so no password need be given.
### Fresh machine from TSA
Begin by copying the *state* and *out* directories from another Onionoo backend
...
...
@@ -126,11 +130,29 @@ copy of metrics-cloud.git under "[onionoo-backends]" and commit the change.
You can now setup the machine with Ansible by running:
```
ansible-playbook -i production onionoo-backends.yml
ansible-playbook -i production
-K
onionoo-backends.yml
```
## Upgrade
The version number of Onionoo to install is stored as a variable in the main
onionoo-backends.yml playbook. Begin by changing this to the new version number
in your local clone, commit and push the change.
Login to each of the Onionoo backends and check the logs for the hourly updater
to ensure it's not mid-update. If everything is idle:
```
systemctl -u onionoo -i bash -c 'systemctl --user stop onionoo'
```
You can now run the Ansible playbook to update the installed versions and
restart the services:
```
ansible-playbook -i production -K onionoo-backends.yml
```
# DIAGNOSTICS
Logs for the hourly updater can be found in
...
...
@@ -153,7 +175,6 @@ rm -rf /srv/onionoo.torproject.org/onionoo/onionoo/{.,}\*
Then pretend you are deploying a new backend from the instructions above.
## Single backend failure, hardware failure
In the event of a single backend failure, ask TSA to trash it and make a new
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment