GithubHelp home page GithubHelp logo

isabella232 / salt-formula-zookeeper Goto Github PK

View Code? Open in Web Editor NEW

This project forked from salt-formulas/salt-formula-zookeeper

0.0 0.0 0.0 36 KB

SaltStack formula for Zookeeper

License: Other

Shell 59.34% Makefile 16.71% HTML 2.57% SaltStack 21.38%

salt-formula-zookeeper's Introduction

zookeeper

Service zookeeper description

Sample pillars

Single zookeeper service

zookeeper:
  server:
    enabled: true
    members:
    - host: ${_param:single_address}
      id: 1

Cluster zookeeper service

zookeeper:
  server:
    enabled: true
    members:
    - host: ${_param:cluster_node01_address}
      id: 1
    - host: ${_param:cluster_node02_address}
      id: 2
    - host: ${_param:cluster_node03_address}
      id: 3

Backup client with ssh/rsync remote host

  zookeeper:
    backup:
      client:
        enabled: true
        full_backups_to_keep: 3
        hours_before_full: 24
        target:
          host: cfg01
          backup_dir: server-home-dir

.. note:: full_backups_to_keep param states how many backup will be stored locally on zookeeper client.
          More options to relocate local backups can be done using salt-formula-backupninja.

Backup client containers with ssh/rsync remote host

zookeeper:
  backup:
    client:
      enabled: true
      full_backups_to_keep: 3
      hours_before_full: 24
      containers:
      - opencontrail_controller_1
      target:
        host: cfg01
        backup_dir: server-home-dir

Backup client with local backup only

  zookeeper:
    backup:
      client:
        enabled: true
        full_backups_to_keep: 3
        hours_before_full: 24

.. note:: full_backups_to_keep param states how many backup will be stored locally on zookeeper client

Backup client at exact times:

..code-block:: yaml

zookeeper:
backup:
client:

enabled: true full_backups_to_keep: 3 incr_before_full: 3 backup_times:

day_of_week: 0 hour: 4 minute: 52

compression: true compression_threads: 2 database:

user: user password: password
target:
host: host01

Note

Parameters in backup_times section can be used to set up exact

time the cron job should be executed. In this example, the backup job would be executed every Sunday at 4:52 AM. If any of the individual backup_times parameters is not defined, the defalut * value will be used. For example, if minute parameter is *, it will run the backup every minute, which is ususally not desired. Available parameters are day_of_week, day_of_month, month, hour and minute. Please see the crontab reference for further info on how to set these parameters.

Note

Please be aware that only backup_times section OR

hours_before_full(incr) can be defined. If both are defined, the backup_times section will be peferred.

Note

New parameter incr_before_full needs to be defined. This

number sets number of incremental backups to be run, before a full backup is performed.

Backup server rsync

zookeeper:
  backup:
    server:
      enabled: true
      hours_before_full: 24
      full_backups_to_keep: 5
      key:
        zookeeper_pub_key:
          enabled: true
          key: ssh_rsa

Backup server without strict client restriction

zookeeper:
  backup:
    restrict_clients: false

Backup server at exact times:

..code-block:: yaml

zookeeper:
backup:
server:

enabled: true full_backups_to_keep: 3 incr_before_full: 3 backup_dir: /srv/backup backup_times:

day_of_week: 0 hour: 4 minute: 52
key:
zookeeper_pub_key:
enabled: true key: key

Note

Parameters in backup_times section can be used to set up exact

time the cron job should be executed. In this example, the backup job would be executed every Sunday at 4:52 AM. If any of the individual backup_times parameters is not defined, the defalut * value will be used. For example, if minute parameter is *, it will run the backup every minute, which is ususally not desired. Available parameters are day_of_week, day_of_month, month, hour and minute. Please see the crontab reference for further info on how to set these parameters.

Note

Please be aware that only backup_times section OR

hours_before_full(incr) can be defined. If both are defined, The backup_times section will be peferred.

Note

New parameter incr_before_full needs to be defined. This

number sets number of incremental backups to be run, before a full backup is performed.

Client restore from local backup:

  zookeeper:
    backup:
      client:
        enabled: true
        full_backups_to_keep: 3
        hours_before_full: 24
        target:
          host: cfg01
        restore_latest: 1
        restore_from: local

.. note:: restore_latest param with a value of 1 means to restore db from the last full backup. 2 would mean to restore second latest full backup.

Client restore from remote backup:

  zookeeper:
    backup:
      client:
        enabled: true
        full_backups_to_keep: 3
        hours_before_full: 24
        target:
          host: cfg01
        restore_latest: 1
        restore_from: remote

.. note:: restore_latest param with a value of 1 means to restore db from the last full backup. 2 would mean to restore second latest full backup.

Client restore container from remote backup:

zookeeper:
  backup:
    client:
      enabled: true
      full_backups_to_keep: 3
      hours_before_full: 24
      containers:
      - opencontrail_controller_1
      target:
        host: cfg01
      restore_latest: 1
      restore_from: remote

Read more

  • links

Documentation and Bugs

To learn how to install and update salt-formulas, consult the documentation available online at:

http://salt-formulas.readthedocs.io/

In the unfortunate event that bugs are discovered, they should be reported to the appropriate issue tracker. Use Github issue tracker for specific salt formula:

https://github.com/salt-formulas/salt-formula-zookeeper/issues

For feature requests, bug reports or blueprints affecting entire ecosystem, use Launchpad salt-formulas project:

https://launchpad.net/salt-formulas

You can also join salt-formulas-users team and subscribe to mailing list:

https://launchpad.net/~salt-formulas-users

Developers wishing to work on the salt-formulas projects should always base their work on master branch and submit pull request against specific formula.

https://github.com/salt-formulas/salt-formula-zookeeper

Any questions or feedback is always welcome so feel free to join our IRC channel:

#salt-formulas @ irc.freenode.net

salt-formula-zookeeper's People

Contributors

dis-xcom avatar epcim avatar fpytloun avatar jakubjosef avatar jiribroulik avatar martin819 avatar mirantis-slovaktelekom avatar miwinski avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.