Kipit is a backup script in bash. It does directory syncing, full and incremental backups. Backups are tarballs stored locally and sent on another server.
Technologies: bash, tar, find, sftp


  • Full and incremental backups of one or many directories
  • Stores backups locally and syncs them to a remote sftp server
  • Permits cleaning of local and remote locations by removing incremental backups older than the last full backup
  • Syncronizes local directory (home) to a remote sftp server


Copy the scripts in ~/bin/ for instance.

Customize configuration file:

  • TARBALL_DIR=/home/thibautbackups Local directory where to store the backup tarballs
  • TARBALL_BASENAME_FULL=kipit-banana-home-full Base name of the full backup tarballs
  • TARBALL_BASENAME_INCR=kipit-banana-home-incr Base name of the incremental backup tarballs
  • TIMESTAMP=`date +%Y%m%d-%H%M%S` Timestamp format
  • DIRECTORIES="/home/thibaut" #only one directory for now, todo: extend to multiple ones Directory to backup
  • EXCLUDE_FROM=/home/thibaut/.kipit/kipit-banana-home-exclude File listing the files to exclude from backup snapshots
  • EXCLUDE_FROM_SYNCPUSH=/home/thibaut/.kipit/kipit-banana-home-exclude-rsync File listing the files to exclude from syncing snapshots
  • RSH=thibaut192.168.0.1@ Sftp server
  • REMOTE_DIR=/mnt/backup/banana Remotre directory where backups are stored on the remote server
  • DISKUSAGE_LIMIT=90 # % Limit on local disk usage, message is printed is usage is above
  • PRIVATE_KEY=/home/thibaut/.ssh/id_rsa Location of private key for sftp connection

Use from the command line.
If unsure, kipit.sh help.

Example commands

  • kipit.sh full send clean distclean: Do a full backup, send remotely, clean local repo, clean remote repo
  • kipit.sh syncpush: Mirror the local directory to the remote directory
  • kipit.sh incremental send: Do an incremental backup, send remotely