Git Product home page Git Product logo

backup's Introduction

Backup Script

A simple backup script utilising OpenSSL, tar and rsync, written in bash.

Script Features

  • Incremental backup retention
  • Backups are encrypted with AES256-cbc with SHA1 message-digest
  • The backup script can store a copy both locally and on a remote device/server
  • Backups are sent over SSH
  • Currently supports GNU/Linux and FreeBSD

Backup Retention

By default:

  • Daily backups are retained for the past week
  • Weekly backups from Mondays are retained for the past month
  • Monthly backups from the first Monday of each month are retained for the past six months

The retention lengths are adjustable in backup.cfg:

If desired, the backup deletion can be run seperately:

  • To delete local backups, run "deleteoldbackups.sh"
  • To delete remote backups, run "deleteoldbackups.sh --remote"

Arguments

backup.sh:

  • --config [filename] : Specify a different configuration file (or location)

deleteoldbackups.sh:

  • --config [filename] : Specify a different configuration file (or location)
  • --remote : Delete remote backups (local backups are deleted by default)

Note that deleteoldbackups.sh is run both locally and remotely by backup.sh by default.

Use With cron

If you're running this script from cron, make sure you add the following line to the top of your crontab: PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin

backup's People

Contributors

xcp23x avatar pricetx avatar reidweb avatar zqueal avatar

Watchers

James Cloos 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.