Linux Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsOperating SystemsLinux Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old October 22nd, 2012, 04:48 PM
williamvee williamvee is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2012
Posts: 2 williamvee User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 41 m 56 sec
Reputation Power: 0
How to restore a list of files with rdiff-backup?

Does anyone know how to restore a specific list of files from an rdiff-backup repository?

I have a file with a list of files to restore e.g files.txt:
dir1/file1
dir1/file2
dir2/file3
dir2/file4

And I want to restore only these files with rdiff-backup to a temporary local dir.

I've tried something like this:
# rdiff-backup --include-filelist files.txt -r 1D remote.host.com::/remote/backup/path/ local_restore_path/

But I get the error:
Warning: file specification 'dir1/file1' in filelist files.txt
doesn't start with correct prefix local_restore_path. Ignoring.

Any ideas how to do it the right way?

Thanks in advance!

Reply With Quote
  #2  
Old October 23rd, 2012, 12:46 AM
kevin2s kevin2s is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2012
Posts: 24 kevin2s Negative: is most likely a SPAMMER and a traitor to the cause. 
Time spent in forums: 4 h 29 m 28 sec
Reputation Power: 0
It is a very lengthy procedure but yo can go to some specific websites in where you can get all the information you want.

Reply With Quote
  #3  
Old October 23rd, 2012, 01:34 AM
williamvee williamvee is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2012
Posts: 2 williamvee User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 41 m 56 sec
Reputation Power: 0
I've spent several hours searching with Google for sites with examples on this topic, but could not find any answer that helped me on my way.. Maybe you could post a few useful links you're talking about?

I think I'm able to write a script that loops through every single line of the file list and restores the files one by one, but we're talking about maybe a thousand files. That may take quite some time I think.

The reason I want to do this, is because someone hacked one of our webservers and corrupted all index.php, main.php, index.htm and index.html files. I just want to restore these specific files in all directories and not restore the entire repository first.

One solution actually is to restore all files first, then use tar to get all files from the file list:
# rdiff-backup -r 1D remote.host.com::/remote/backup/path local_restore_path
# cp file-list.txt local_restore_path/
# cd local_restore_path/
# tar -cvf the_files.tar -I file-list.txt
# mv the_files.tar /path/to/restore/files/to/
# cd /path/to/restore/files/to
# tar -xvf the_files.tar

But I think this is a waste of time as well as a waste of disk space. Surely other sysadmins have needed to do something like this. I would be surprised to see that rdiff-backup would not provide a solution for this..

Reply With Quote
Reply

Viewing: Dev Shed ForumsOperating SystemsLinux Help > How to restore a list of files with rdiff-backup?

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap