You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Jan Seeger <ja...@globalways.net> on 2009/08/06 15:47:58 UTC
Keeping backups in Subversion
Greetings!
I don't know if this has come up before, but I am looking for a possibility to pack backups into a subversion repository. I'm thinking like this:
rsync from remote to local host
checkin into subversion repository
The only problem here is how to delete files that have been deleted on the remote host. How would I go about detecting missing files and removing them from the working copy?
Best regards,
Jan Seeger
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2380908
To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].
Re: Keeping backups in Subversion
Posted by Radomir Zoltowski <ra...@s3group.com>.
Jan Seeger wrote:
>
> Greetings!
>
> I don't know if this has come up before, but I am looking for a
> possibility to pack backups into a subversion repository. I'm thinking
> like this:
>
> rsync from remote to local host
> checkin into subversion repository
>
> The only problem here is how to delete files that have been deleted on
> the remote host. How would I go about detecting missing files and
> removing them from the working copy?
>
> Best regards,
> Jan Seeger
>
> rsync -avz -e SSH --delete-after --cvs-exclude
or other options and combinations. I am just guessing here!
Read man on *rsync* for more. This won't however guarantee that your
working copy will be anyhow usable.
I think of that you should actually ask youself, whether you want backup
or archive? Backup usually does not need versioning, it's ok to have
just one immediate copy aside. Archive however does keep full history,
but I kind of doubt that Subversion is a good software to maintain any
archive in particular.
What is your goal and what are the sets you'd like to have backed
up/archived? Have you ever considered full vs incremental backups,
schedules or any appropriate software for the job?
R.
The information contained in this e-mail and in any attachments is confidential and is designated solely for the attention of the intended recipient(s). If you are not an intended recipient, you must not use, disclose, copy, distribute or retain this e-mail or any part thereof. If you have received this e-mail in error, please notify the sender by return e-mail and delete all copies of this e-mail from your computer system(s).
Please direct any additional queries to: communications@s3group.com.
Thank You.
Silicon and Software Systems Limited. Registered in Ireland no. 378073.
Registered Office: South County Business Park, Leopardstown, Dublin 18
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2380921
To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].
Re: Keeping backups in Subversion
Posted by Tyler Roscoe <ty...@cryptio.net>.
On Thu, Aug 06, 2009 at 05:47:58PM +0200, Jan Seeger wrote:
> I don't know if this has come up before, but I am looking for a
> possibility to pack backups into a subversion repository. I'm thinking
> like this:
svn may not be the best tool for this job.
> rsync from remote to local host
> checkin into subversion repository
>
> The only problem here is how to delete files that have been deleted on
> the remote host. How would I go about detecting missing files and
> removing them from the working copy?
What about adding new files?
You could parse the output of svn status or of rsync (I think it reports
when a new file is being copied or an old one is being deleted). Then
svn add/svn rm accordingly.
tyler
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2380916
To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].
Re: Keeping backups in Subversion
Posted by Rob van Oostrum <rv...@gmail.com>.
On Thu, Aug 6, 2009 at 7:50 PM, Ryan Schmidt <
subversion-2009b@ryandesign.com> wrote:
> On Aug 6, 2009, at 10:47, Jan Seeger wrote:
>
> > The only problem here is how to delete files that have been deleted
> > on the remote host. How would I go about detecting missing files
> > and removing them from the working copy?
>
> Basically, you don't detect such things.
>
> http://subversion.tigris.org/faq.html#wc-change-detection
>
> ------------------------------------------------------
>
> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2381126
>
> To unsubscribe from this discussion, e-mail: [
> users-unsubscribe@subversion.tigris.org].
>
Missing files show up as such in 'svn status' (prefixed by '!').
So something like this:
svn st | grep ^! | cut -c 8- | xargs svn rm
svn st | grep ^? | cut -c 8- | xargs svn add
Might need some tweak and polish, but that should essentially do the job.
Hope that helps,
Rob
--
Polarion Software
Subversion Training & Consulting Services | ttp://
www.polarion.com/services/index.php
Download Eclipse bundled with Subversive today! |
http://www.polarion.com/products/eclipse/
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2381129
To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].
Re: Keeping backups in Subversion
Posted by Ryan Schmidt <su...@ryandesign.com>.
On Aug 6, 2009, at 10:47, Jan Seeger wrote:
> The only problem here is how to delete files that have been deleted
> on the remote host. How would I go about detecting missing files
> and removing them from the working copy?
Basically, you don't detect such things.
http://subversion.tigris.org/faq.html#wc-change-detection
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2381126
To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].
Re: Keeping backups in Subversion
Posted by Les Mikesell <le...@gmail.com>.
Jan Seeger wrote:
>
> I don't know if this has come up before, but I am looking for a
> possibility to pack backups into a subversion repository. I'm thinking
> like this:
>
> rsync from remote to local host
> checkin into subversion repository
>
> The only problem here is how to delete files that have been deleted on
> the remote host. How would I go about detecting missing files and
> removing them from the working copy?
The big problem here is that there is no reasonable mechanism for ever
deleting anything from a subversion repository. It might work if you
started a new repository every month or so and aged out old ones.
However, you probably would be better off looking at something like
http://backuppc.sourceforge.net/ which has a good scheme for minimizing
the disk space requirement and is already designed to handle backups
sensibly. The one thing subversion might handle better would be large
files with small changes between runs. Backuppc will merge duplicate
copies of identical files but even a small change takes separate storage.
--
Les Mikesell
lesmikesell@gmail.com
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2380938
To unsubscribe from this discussion, e-mail: [users-unsubscribe@subversion.tigris.org].