diff options
| author | intrigeri <intrigeri@boum.org> | 2012-06-15 20:41:25 +0200 | 
|---|---|---|
| committer | intrigeri <intrigeri@boum.org> | 2012-06-15 20:41:25 +0200 | 
| commit | 87fafa017b855b1aa665ff600a5ca7483091b120 (patch) | |
| tree | d235c62c3fbdc632bb604fea4404468e842d5100 | |
| parent | 9cba5db20b6298fddeb61457edc29b190de3d039 (diff) | |
| parent | 713ec859fccd9546605c3e82c3bf2da9932a1d6a (diff) | |
| download | backupninja-87fafa017b855b1aa665ff600a5ca7483091b120.tar.gz backupninja-87fafa017b855b1aa665ff600a5ca7483091b120.tar.bz2  | |
Merge tag 'backupninja_upstream/1.0' into debian
Upstream version 1.0
| -rw-r--r-- | AUTHORS | 1 | ||||
| -rw-r--r-- | ChangeLog | 16 | ||||
| -rw-r--r-- | backupninja.spec | 2 | ||||
| -rwxr-xr-x | configure | 20 | ||||
| -rw-r--r-- | configure.in | 2 | ||||
| -rw-r--r-- | handlers/maildir.in | 3 | ||||
| -rw-r--r-- | handlers/mysql.in | 13 | ||||
| -rw-r--r-- | handlers/rsync.in | 15 | ||||
| -rw-r--r-- | handlers/sys.in | 24 | ||||
| -rwxr-xr-x | src/backupninja.in | 2 | 
10 files changed, 64 insertions, 34 deletions
@@ -43,3 +43,4 @@ aihtdikh -- Allow 'when = XXX' with spaces in .sh files.  Chris Lamb <lamby@debian.org> -- rdiff.helper bugfix  Yuval Kogman <nothingmuch@woobling.org> -- RackSpace's CloudFiles support for duplicity  exobuzz - mysql bugfixes +Glennie Vignarajah <glennie@glennie.fr> -- mysql bugfix @@ -1,3 +1,19 @@ +version 1.0 -- June 15, 2012 +    The "happy birthdays" release! +    handler changes +	mysql: +	 . Use --skip-events when backing up the performance_schema database. +	   (Closes: #673572) +	rsync: +	 . Generate excludes command-line snippet the same way as +	   the duplicity handler does. +	 . Run rsync command-line through a shell, so that single-quotes +	   around excludes are interpreted (Closes: #677410) +	sys: +	 . Don't execute /usr/bin/lspci or /sbin/modinfo when $hardware == "no" +    backupninja changes +	 . Make it clear what lockfile could not be acquired, if any. +  version 1.0-rc1 -- May 15, 2012      handler changes  	dup: diff --git a/backupninja.spec b/backupninja.spec index f55a6dd..124f0d1 100644 --- a/backupninja.spec +++ b/backupninja.spec @@ -1,5 +1,5 @@  %define name    backupninja -%define version 1.0-rc1 +%define version 1.0  Summary:    Backupninja backup tool  Name:       %{name} @@ -1,6 +1,6 @@  #! /bin/sh  # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for backupninja 1.0-rc1. +# Generated by GNU Autoconf 2.69 for backupninja 1.0.  #  # Report bugs to <backupninja@lists.riseup.net>.  # @@ -579,8 +579,8 @@ MAKEFLAGS=  # Identity of this package.  PACKAGE_NAME='backupninja'  PACKAGE_TARNAME='backupninja' -PACKAGE_VERSION='1.0-rc1' -PACKAGE_STRING='backupninja 1.0-rc1' +PACKAGE_VERSION='1.0' +PACKAGE_STRING='backupninja 1.0'  PACKAGE_BUGREPORT='backupninja@lists.riseup.net'  PACKAGE_URL='' @@ -1203,7 +1203,7 @@ if test "$ac_init_help" = "long"; then    # Omit some internal or obsolete options to make the list less imposing.    # This message is too long to be a string in the A/UX 3.1 sh.    cat <<_ACEOF -\`configure' configures backupninja 1.0-rc1 to adapt to many kinds of systems. +\`configure' configures backupninja 1.0 to adapt to many kinds of systems.  Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1269,7 +1269,7 @@ fi  if test -n "$ac_init_help"; then    case $ac_init_help in -     short | recursive ) echo "Configuration of backupninja 1.0-rc1:";; +     short | recursive ) echo "Configuration of backupninja 1.0:";;     esac    cat <<\_ACEOF @@ -1336,7 +1336,7 @@ fi  test -n "$ac_init_help" && exit $ac_status  if $ac_init_version; then    cat <<\_ACEOF -backupninja configure 1.0-rc1 +backupninja configure 1.0  generated by GNU Autoconf 2.69  Copyright (C) 2012 Free Software Foundation, Inc. @@ -1353,7 +1353,7 @@ cat >config.log <<_ACEOF  This file contains any messages produced by compilers while  running configure, to aid debugging if configure makes a mistake. -It was created by backupninja $as_me 1.0-rc1, which was +It was created by backupninja $as_me 1.0, which was  generated by GNU Autoconf 2.69.  Invocation command line was    $ $0 $@ @@ -2169,7 +2169,7 @@ fi  # Define the identity of the package.   PACKAGE='backupninja' - VERSION='1.0-rc1' + VERSION='1.0'  cat >>confdefs.h <<_ACEOF @@ -3143,7 +3143,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1  # report actual input values of CONFIG_FILES etc. instead of their  # values after options handling.  ac_log=" -This file was extended by backupninja $as_me 1.0-rc1, which was +This file was extended by backupninja $as_me 1.0, which was  generated by GNU Autoconf 2.69.  Invocation command line was    CONFIG_FILES    = $CONFIG_FILES @@ -3196,7 +3196,7 @@ _ACEOF  cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1  ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"  ac_cs_version="\\ -backupninja config.status 1.0-rc1 +backupninja config.status 1.0  configured by $0, generated by GNU Autoconf 2.69,    with options \\"\$ac_cs_config\\" diff --git a/configure.in b/configure.in index 3cddf61..dcb8c24 100644 --- a/configure.in +++ b/configure.in @@ -3,7 +3,7 @@  # The maintainer mode is causing me grief with newest versions of autotools  #AM_MAINTAINER_MODE -AC_INIT([backupninja],[1.0-rc1],[backupninja@lists.riseup.net]) +AC_INIT([backupninja],[1.0],[backupninja@lists.riseup.net])  AC_CONFIG_SRCDIR([src/backupninja.in])  AM_INIT_AUTOMAKE diff --git a/handlers/maildir.in b/handlers/maildir.in index 912c0e6..64ac987 100644 --- a/handlers/maildir.in +++ b/handlers/maildir.in @@ -85,9 +85,6 @@ if [ $test ]; then     testflags="--dry-run -v"  fi -rsyncflags="$testflags -e 'ssh -p $destport -i $destid_file $sshoptions' -r -v --ignore-existing --delete --size-only --bwlimit=$speedlimit" -excludes="--exclude '.Trash/\*' --exclude '.Mistakes/\*' --exclude '.Spam/\*'" -  ##################################################################  ### FUNCTIONS diff --git a/handlers/mysql.in b/handlers/mysql.in index 65deebb..6ade49e 100644 --- a/handlers/mysql.in +++ b/handlers/mysql.in @@ -256,10 +256,15 @@ then     for db in $databases     do        DUMP_BASE="$MYSQLDUMP $defaultsfile $sqldumpoptions" -      if [ "$db" = "information_schema" ] || [ "$db" = "performance_schema" ] -      then -         DUMP_BASE="${DUMP_BASE} --skip-lock-tables" -      fi + +      case "$db" in +         information_schema) +            DUMP_BASE="${DUMP_BASE} --skip-lock-tables" +            ;; +         performance_schema) +            DUMP_BASE="${DUMP_BASE} --skip-lock-tables --skip-events" +            ;; +      esac        # Dumping structure and data        DUMP="$DUMP_BASE $ignore $db" diff --git a/handlers/rsync.in b/handlers/rsync.in index 386255e..f0df52f 100644 --- a/handlers/rsync.in +++ b/handlers/rsync.in @@ -275,8 +275,15 @@ function eval_config {      mv=move_files    fi -  excludes=`echo "$exclude" | @SED@ -e "s/^/--exclude='/g" -e "s/ /' --exclude='/g" -e "s/$/'/"` - +  set -o noglob +  SAVEIFS=$IFS +  IFS=$(echo -en "\n\b") +  for i in $exclude; do +     str="${i//__star__/*}" +     excludes="${excludes} --exclude='$str'" +  done +  IFS=$SAVEIFS +  set +o noglob  }  function rotate_short { @@ -1109,9 +1116,9 @@ for SECTION in $include; do    set_dest    info "Syncing $SECTION on $dest_path..." -  debug $nice $rsync "${rsync_options[@]}" $filelist_flag "$excludes" $batch_option $orig $dest_path +  debug $nice $rsync ${rsync_options[@]} $filelist_flag $excludes $batch_option $orig $dest_path    set_pipefail -  $nice $rsync "${rsync_options[@]}" $filelist_flag "$excludes" $batch_option $orig $dest_path | tee -a $log +  $nice su -c "$rsync ${rsync_options[@]} --delete-excluded $filelist_flag $excludes $batch_option $orig $dest_path" | tee -a $log    if [ "$?" != "0" ]; then      fatal "Rsync error when trying to transfer $SECTION" diff --git a/handlers/sys.in b/handlers/sys.in index 74133a3..92998cc 100644 --- a/handlers/sys.in +++ b/handlers/sys.in @@ -348,13 +348,15 @@ echo "Getting information about the kernel."  echo  STATUS="Getting kernel version:"  catifexec "/bin/uname" "-a" -STATUS="Checking module information:" -catifexec "/sbin/lsmod" -for x  in $(/sbin/lsmod | /usr/bin/cut -f1 -d" " 2>/dev/null | /bin/grep -v Module 2>/dev/null -) ; do -   STATUS="Checking module information $x:" -   catifexec "/sbin/modinfo" "$x" -done +if [ "$hardware" == "yes" ]; then +   STATUS="Checking module information:" +   catifexec "/sbin/lsmod" +   for x  in $(/sbin/lsmod | /usr/bin/cut -f1 -d" " 2>/dev/null | /bin/grep -v Module 2>/dev/null +   ) ; do +      STATUS="Checking module information $x:" +      catifexec "/sbin/modinfo" "$x" +   done +fi  STATUS="Gathering information about your filesystems:"  catiffile "/proc/filesystems" @@ -432,9 +434,11 @@ catiffile "/proc/rtc"  STATUS="Gathering information about your ide drivers:"  catiffile "/proc/ide" -STATUS="Gathering information about your bus:" -catifexec "/usr/bin/lspci" -catiffile "/proc/bus" +if [ "$hardware" == "yes" ]; then +   STATUS="Gathering information about your bus:" +   catifexec "/usr/bin/lspci" +   catiffile "/proc/bus" +fi  echo  echo "Getting disk and filesystem information." diff --git a/src/backupninja.in b/src/backupninja.in index 0400828..0f74906 100755 --- a/src/backupninja.in +++ b/src/backupninja.in @@ -349,7 +349,7 @@ function process_action() {         else  	   # a backup is probably ongoing already, so display an error message -	   debug "failed to acquire lock" +	   debug "failed to acquire lock $lockfile"  	   echo "Fatal: Could not acquire lock $lockfile. A backup is probably already running for $file." >>$bufferfile         fi     } 200> $lockfile  | 
