"Han The Man" <hantheman12@hotmail.com> writes:
> I've been upgrading SVN and I really hate schema changes (having 30
> repositories and counting... puhhhft :-)
>
> Since schema changes are necessary, I have a couple of questions:
>
> 1) Do you guys expect more schema changes any time soon?
CMike tries to keep them to a minimum, so I'd say no.
However, if there are going to be anymore, I'll betcha they'll be before
beta, and definitely before 1.0.
> 2) How would you go about automating this process? I'm not any good at
> scripting... perhaps someone should write an upgrading script, or something?
CMike sent this pseudocode to the list a few weeks ago:
cmpilato@collab.net writes:
> "Han The Man" <hantheman12@hotmail.com> writes:
>
> > I noticed somewhere that 0.28 will have schema changes.
> >
> > We are currently running 0.27 and at this point, we've migrated about
> > 25 projects into 20 repositories. Do we need to dump/load each
> > repository? What is the easiest way to upgrade to 0.28 when it's out?
> >
> > Is there a tool that will upgrade all repositories? I hope so - by
> > next week, we're probably done migrating, having about 30
> > repositories...
>
> I know of no such tool. But if the repositories are all in a single
> directory, it should be fairly simple to script the process.
>
> I probably shouldn't advocate doing things this way, but what the
> heck. This is how I do it, since I know how the filesystem works.
> And since I keep extra junk in my repos directories sometimes (besides
> hooks and such), I don't want to lose that in a conversion.
>
> Follow my pseudocode, if you will:
>
> # Make a backup directory for unconverted repositories
> mkdir BACKUP
>
> # Now, loop over the list of repositories
> for repos in repos-list; do
>
> # Backup the old repos
> cp -R ${repos} BACKUP
>
> # Make a new, temporary repos
> rm -rf tmp-repos
> svnadmin create tmp-repos
>
> # Dump the old repos into the temporary repos
> old-svnadmin dump ${repos} | svnadmin load tmp-repos
>
> # Replace the db/ directory from the old repos with the db/
> # directory from the new, temporary repos
> rm -rf ${repos}/db; mv tmp-repos/db ${repos/db}
>
> # Finally, bump the repository format number
> echo "2" > ${repos}/format
>
> [insert any disclaimers you can think of here]
-Fitz
--
Brian W. Fitzpatrick <fitz_at_red-bean.com> http://www.red-bean.com/fitz/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Sep 6 22:28:44 2003