DBCollect/Ansible: Difference between revisions
Jump to navigation
Jump to search
Created page with " = Overview = ''dbcollect'' can be run on multiple hosts in one go using Ansible. This document describe how to setup and run dbcollect using Ansible Playbooks." |
|||
(4 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
[[Category:DBCollect]] | |||
= Overview = | |||
{{dbcollect}} can be run on multiple hosts in one go using Ansible. This document describe how to setup and run dbcollect using Ansible Playbooks. | |||
= Prerequisites = | |||
* Python 3 installed and configured (python3 should execute correctly) | |||
* Ansible must be installed and operational on a working host (ideally, not one of the database hosts on which dbcollect should be executed) | |||
* The ansible user should have root access to the target hosts using Ansible (i.e., have password-less SSH keys configured) | |||
* The working host has HTTP access to github.com | |||
= Installing = | |||
* Assuming the local user is ''user'' | |||
<syntaxhighlight lang=bash> | |||
# Make a working directory on $HOME and make it the current dir | |||
mkdir $HOME/multicollect && cd $HOME/multicollect | |||
# Download the playbook, multicollect executable and example hosts file | |||
curl -O https://raw.githubusercontent.com/outrunnl/dbcollect/master/contrib/ansible/dbcollect.yml | |||
curl -O https://raw.githubusercontent.com/outrunnl/dbcollect/master/contrib/ansible/hosts | |||
curl -O https://raw.githubusercontent.com/outrunnl/dbcollect/master/contrib/ansible/multicollect | |||
# Make multicollect executable | |||
chmod 755 multicollect | |||
# Edit the hosts file and place your hosts (full qualified domain names) in the [servers] section | |||
vi hosts | |||
# Test multicollect | |||
./multicollect -h | |||
./multicollect -V | |||
</syntaxhighlight> | |||
= Usage = | |||
<syntaxhighlight lang=bash> | |||
# Now you can run multicollect with any options | |||
./multicollect <options> | |||
</syntaxhighlight> |
Latest revision as of 06:23, 29 May 2024
Overview
dbcollect can be run on multiple hosts in one go using Ansible. This document describe how to setup and run dbcollect using Ansible Playbooks.
Prerequisites
- Python 3 installed and configured (python3 should execute correctly)
- Ansible must be installed and operational on a working host (ideally, not one of the database hosts on which dbcollect should be executed)
- The ansible user should have root access to the target hosts using Ansible (i.e., have password-less SSH keys configured)
- The working host has HTTP access to github.com
Installing
- Assuming the local user is user
# Make a working directory on $HOME and make it the current dir
mkdir $HOME/multicollect && cd $HOME/multicollect
# Download the playbook, multicollect executable and example hosts file
curl -O https://raw.githubusercontent.com/outrunnl/dbcollect/master/contrib/ansible/dbcollect.yml
curl -O https://raw.githubusercontent.com/outrunnl/dbcollect/master/contrib/ansible/hosts
curl -O https://raw.githubusercontent.com/outrunnl/dbcollect/master/contrib/ansible/multicollect
# Make multicollect executable
chmod 755 multicollect
# Edit the hosts file and place your hosts (full qualified domain names) in the [servers] section
vi hosts
# Test multicollect
./multicollect -h
./multicollect -V
Usage
# Now you can run multicollect with any options
./multicollect <options>