problem with edit/delete on primary

Darrell Schulte dschulte@facstaff.wisc.edu
Tue, 03 Sep 2002 14:40:03 -0500


Hi,

I installed
http://rdiff-backup.stanford.edu/rdiff-backup-0.8.0-1.noarch.rpm
on two identical systems (Linux 2.4.18-10smp).

made appropriate Python2 change as noted on 
http://rdiff-backup.stanford.edu/FAQ.html#redhat

Followed instructions at
http://arctic.org/~dean/rdiff-backup/unattended.html and now 
unattended rdiff-backup seems to work without complaints.

Created the following cron script.

cron.hourly/rdiff-backup

#!/bin/bash
cd /usr/local/etc/httpd
rdiff-backup primary-backup::/usr/local/etc/httpd/html html
rdiff-backup --remove-older-than 7D /usr/local/etc/httpd/html/

Here's what I've encountered. Was it anything I did? Let me know if 
more info is needed. Thanks.



primary machine has "bingo.txt" and "test.txt" as test files in 
/usr/local/etc/httpd/html and the mirror with the same directory 
structure which contains no files.

first run of cron script yields:

Fatal Error: No increments older than Tue Aug 27 14:22:51 2002 found

result is that the mirror now contains both "bingo.txt" and 
"test.txt" and the directory, rdiff-backup-data.

all is well at this point.

if I edit the test.txt file on the primary and re-run the cron script 
on the mirror, I get the following:

Exception '['rdiff', 'signature', 'html/test.txt'] exited with 
non-zero value 256' raised of class '__main__.RdiffException':
   File "/usr/bin/rdiff-backup", line 6037, in patch_increment_and_finalize
     for indexed_tuple in collated:
   File "/usr/bin/rdiff-backup", line 3688, in Collate2Iters
     try: relem1 = riter1.next()
   File "/usr/bin/rdiff-backup", line 3584, in FromRaw
     for index, data, num_files in raw_iter:
   File "/usr/bin/rdiff-backup", line 1001, in next
     type, data = self._get()
   File "/usr/bin/rdiff-backup", line 976, in _get
     header = self.file.read(8)
   File "/usr/bin/rdiff-backup", line 1173, in read
     l - len(self.buffer)))
   File "/usr/bin/rdiff-backup", line 1847, in read
     return self.connection.VirtualFile.readfromid(self.id, length)
   File "/usr/bin/rdiff-backup", line 1792, in __call__
     return apply(self.connection.reval, (self.name,) + args)
   File "/usr/bin/rdiff-backup", line 1731, in reval
     if isinstance(result, Exception): raise result

Writing intermediate hard link data to disk
Traceback (most recent call last):
   File "/usr/bin/rdiff-backup", line 6779, in ?
     Globals.Main.Main(sys.argv[1:])
   File "/usr/bin/rdiff-backup", line 6488, in Main
     self.take_action(rps)
   File "/usr/bin/rdiff-backup", line 6465, in take_action
     elif self.action == "backup": self.Backup(rps[0], rps[1])
   File "/usr/bin/rdiff-backup", line 6521, in Backup
     HighLevel.Mirror_and_increment(rpin, rpout, self.incdir, RSI)
   File "/usr/bin/rdiff-backup", line 5817, in Mirror_and_increment
     DestS.patch_increment_and_finalize(dest_rpath, diffiter, inc_rpath)
   File "/usr/bin/rdiff-backup", line 6049, in patch_increment_and_finalize
     except: cls.handle_last_error(finished_dsrp, finalizer, ITR)
   File "/usr/bin/rdiff-backup", line 6037, in patch_increment_and_finalize
     for indexed_tuple in collated:
   File "/usr/bin/rdiff-backup", line 3688, in Collate2Iters
     try: relem1 = riter1.next()
   File "/usr/bin/rdiff-backup", line 3584, in FromRaw
     for index, data, num_files in raw_iter:
   File "/usr/bin/rdiff-backup", line 1001, in next
     type, data = self._get()
   File "/usr/bin/rdiff-backup", line 976, in _get
     header = self.file.read(8)
   File "/usr/bin/rdiff-backup", line 1173, in read
     l - len(self.buffer)))
   File "/usr/bin/rdiff-backup", line 1847, in read
     return self.connection.VirtualFile.readfromid(self.id, length)
   File "/usr/bin/rdiff-backup", line 1792, in __call__
     return apply(self.connection.reval, (self.name,) + args)
   File "/usr/bin/rdiff-backup", line 1731, in reval
     if isinstance(result, Exception): raise result
__main__.RdiffException: ['rdiff', 'signature', 'html/test.txt'] 
exited with non-zero value 256
Traceback (most recent call last):
   File "/usr/bin/rdiff-backup", line 6779, in ?
     Globals.Main.Main(sys.argv[1:])
   File "/usr/bin/rdiff-backup", line 6488, in Main
     self.take_action(rps)
   File "/usr/bin/rdiff-backup", line 6464, in take_action
     PipeConnection(sys.stdin, sys.stdout).Server()
   File "/usr/bin/rdiff-backup", line 1716, in Server
     self.get_response(-1)
   File "/usr/bin/rdiff-backup", line 1681, in get_response
     try: req_num, object = self._get()
   File "/usr/bin/rdiff-backup", line 1587, in _get
     raise ConnectionReadError("Truncated header string (problem "
__main__.ConnectionReadError: Truncated header string (problem 
probably originated remotely)
Fatal Error: No increments older than Tue Aug 27 14:26:11 2002 found

if I start from scratch again, create a file called "chicken.txt" on 
the primary, file moves.

if I delete "chicken.txt" from primary and re-run script, I get the following:

Exception '['rdiff', 'signature', 'html/chicken.txt'] exited with 
non-zero value 256' raised of class '__main__.RdiffException':
   File "/usr/bin/rdiff-backup", line 6037, in patch_increment_and_finalize
     for indexed_tuple in collated:
   File "/usr/bin/rdiff-backup", line 3688, in Collate2Iters
     try: relem1 = riter1.next()
   File "/usr/bin/rdiff-backup", line 3584, in FromRaw
     for index, data, num_files in raw_iter:
   File "/usr/bin/rdiff-backup", line 1001, in next
     type, data = self._get()
   File "/usr/bin/rdiff-backup", line 976, in _get
     header = self.file.read(8)
   File "/usr/bin/rdiff-backup", line 1173, in read
     l - len(self.buffer)))
   File "/usr/bin/rdiff-backup", line 1847, in read
     return self.connection.VirtualFile.readfromid(self.id, length)
   File "/usr/bin/rdiff-backup", line 1792, in __call__
     return apply(self.connection.reval, (self.name,) + args)
   File "/usr/bin/rdiff-backup", line 1731, in reval
     if isinstance(result, Exception): raise result

Writing intermediate hard link data to disk
Traceback (most recent call last):
   File "/usr/bin/rdiff-backup", line 6779, in ?
     Globals.Main.Main(sys.argv[1:])
   File "/usr/bin/rdiff-backup", line 6488, in Main
     self.take_action(rps)
   File "/usr/bin/rdiff-backup", line 6465, in take_action
     elif self.action == "backup": self.Backup(rps[0], rps[1])
   File "/usr/bin/rdiff-backup", line 6521, in Backup
     HighLevel.Mirror_and_increment(rpin, rpout, self.incdir, RSI)
   File "/usr/bin/rdiff-backup", line 5817, in Mirror_and_increment
     DestS.patch_increment_and_finalize(dest_rpath, diffiter, inc_rpath)
   File "/usr/bin/rdiff-backup", line 6049, in patch_increment_and_finalize
     except: cls.handle_last_error(finished_dsrp, finalizer, ITR)
   File "/usr/bin/rdiff-backup", line 6037, in patch_increment_and_finalize
     for indexed_tuple in collated:
   File "/usr/bin/rdiff-backup", line 3688, in Collate2Iters
     try: relem1 = riter1.next()
   File "/usr/bin/rdiff-backup", line 3584, in FromRaw
     for index, data, num_files in raw_iter:
   File "/usr/bin/rdiff-backup", line 1001, in next
     type, data = self._get()
   File "/usr/bin/rdiff-backup", line 976, in _get
     header = self.file.read(8)
   File "/usr/bin/rdiff-backup", line 1173, in read
     l - len(self.buffer)))
   File "/usr/bin/rdiff-backup", line 1847, in read
     return self.connection.VirtualFile.readfromid(self.id, length)
   File "/usr/bin/rdiff-backup", line 1792, in __call__
     return apply(self.connection.reval, (self.name,) + args)
   File "/usr/bin/rdiff-backup", line 1731, in reval
     if isinstance(result, Exception): raise result
__main__.RdiffException: ['rdiff', 'signature', 'html/chicken.txt'] 
exited with non-zero value 256
Traceback (most recent call last):
   File "/usr/bin/rdiff-backup", line 6779, in ?
     Globals.Main.Main(sys.argv[1:])
   File "/usr/bin/rdiff-backup", line 6488, in Main
     self.take_action(rps)
   File "/usr/bin/rdiff-backup", line 6464, in take_action
     PipeConnection(sys.stdin, sys.stdout).Server()
   File "/usr/bin/rdiff-backup", line 1716, in Server
     self.get_response(-1)
   File "/usr/bin/rdiff-backup", line 1681, in get_response
     try: req_num, object = self._get()
   File "/usr/bin/rdiff-backup", line 1587, in _get
     raise ConnectionReadError("Truncated header string (problem "
__main__.ConnectionReadError: Truncated header string (problem 
probably originated remotely)
Fatal Error: No increments older than Tue Aug 27 14:30:16 2002 found

Darrell
_____________________________________________________________________
	       Darrell A. Schulte - dschulte@wisc.edu
      University of Wisconsin-Madison - University Communications
        The Why Files http://whyfiles.org - The Graduate School