rsnapshot-1.2.1-r1.ebuild Note that just now reinstalling that version I CANNOT duplicate this problem. Maybe it was already fixed, or maybe gnu cp has been altered since I just finished an update Deep world. I'm going to describe the problem anyway since it is a potentially very serious matter. The problem I had was that rsnapshot and the newest gnu cp now fail due to changes in gnu cp. It now enforces the trailing slash to be removed when cping 2 directories. See this report for details. http://sourceforge.net/mailarchive/forum.php?thread_id=8988105&forum_id=41320 Here is a quote from the supplied URL: =========================== We encountered problems with the latest version of GNU cp (GNU coreutils 5.93) and the latest version of Rsnapshot (1.2.1 source). I noticed an important change in GNU cp between version 5.2.1 and 5.93 that causes Rsnapshot to fail. GNU cp 5.93 (and possibly other 5.9x) now enforce the trailing / to be removed when copying two directories. ===================== What makes this a serious problem is that when the cp fails and given a default installation which has no safeguards against something like this, rsnapshot reports the error as a cp failure. But still (mv) moves the existing backups thru a rotation 1 moved to 2 etc and 5 is deleted. But since the copy (cp) of hourly.0 to hourly.1 fails no new data is moved into the 1 slot. Next run another backup is deleted and the others rotated etc until all backups are gone. This actually occured before an update deep world and again I CANNOT reproduce it but will continue testing. Meantime someone way more skilled than I need to look at this. Gentoo Base System version 1.12.0_pre15 Portage 2.1_pre4-r1 (default-linux/x86/2005.1, gcc-3.3.6, glibc-2.3.6-r2, 2.6.15-gentoo-r3 i686) ================================================================= System uname: 2.6.15-gentoo-r3 i686 AMD Athlon(tm) 64 Processor 3400+ dev-lang/python: 2.3.5-r2, 2.4.2-r1 sys-apps/sandbox: 1.2.17 sys-devel/autoconf: 2.13, 2.59-r7 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1 sys-devel/binutils: 2.16.1-r1 sys-devel/libtool: 1.5.22 virtual/os-headers: 2.6.11-r3 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-Os -march=athlon-xp -pipe" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /var/bind /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-Os -march=athlon-xp -pipe" DISTDIR="/usr/portage/distfiles" FEATURES="autoconfig distlocks sandbox sfperms strict" GENTOO_MIRRORS="http://gentoo.mirrored.ca/ ftp://gentoo.mirrored.ca/" PKGDIR="/mnt/pack/gentoo/pkgiso/All" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="x86 X alsa apache2 apm arts avi berkdb bitmap-fonts cdr crypt cups dvd eds emacs emboss encode foomaticdb fortran gcj gdbm gif gpm gstreamer gtk gtk2 hal imlib jpeg kde libg++ libwww logrotate mad mbox mikmod motif mp3 mpeg mysql ncurses nls objc ogg oggvorbis opengl oss pam pdflib perl png python qt quicktime readline samba sasl sdl smb spell ssl symlinks tcpd truetype truetype-fonts type1-fonts vorbis xinerama xml2 xmms xv zlib elibc_glibc kernel_linux userland_GNU" Unset: ASFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, LANG, LC_ALL, LDFLAGS, LINGUAS, MAKEOPTS, PORTDIR_OVERLAY
Created attachment 82946 [details, diff] cp_al patch for rsnapshot
I created an ebuild with # 2006/03/23 twam: cp_al patch for newest GNU cp (coreutils), is probably fixed in rsnapshot 1.2.3 epatch ${FILESDIR}/cp_al.patch And everything seems to work. Regards Tobias
Tobias, having ran into the same problem yesterday I tried to apply your patch but seem to be doing something wrong. I put the patch into /usr/portage/app-backup/rsnapshot/files and ran ebuild rsnapshot-1.2.1-r1.ebuild digest. Them I reemerged rsnapshot 1.2.1-r1. However, the scheduled backup now at 00:00 quit with the same error message about cp and deleted another of hourly backups. Obviously I did something wrong, but what? How do I apply such patches correctly? Help would be greatly appreciated! Thanks! Andreas
Ok, stupid is as stupid does (but it's getting late). FWIW, and for future reference for stupid people like me: First: how could I forget I shouldn't do work in /usr/portage/app-backup/rsnapshot but in /usr/local/portage/app-backup/rsnapshot (with an appropriately set PORTDIR_OVERLAY). Second: Just as Tobias said a new ebuild /usr/local/portage/app-backup/rsnapshot/rsnapshot-1.2.1-r2 has to be created including a line like epatch ${FILESDIR}/cp_al.patch just after src_compile() { Then the digest has to be computed by ebuild /usr/local/portage/app-backup/rsnapshot/rsnapshot-1.2.1-r2 digest Now "=rsnapshot/rsnapshot-1.2.1-r2 ~x86" has to be added to /etc/portage/package.keywords followed by a reemerge of rsnapshot. Should now be rsnapshot-1.2.1-r2 with the patch applied correctly. Just tested it and rsnapshot works fine again. Thanks for the patch Tobias!
Fixed in rsnapshot-1.2.1-r2. Sorry about taking so long to handle this and thanks for the patch :)
*** Bug 130347 has been marked as a duplicate of this bug. ***