Migrating VisualSVN Server from one Windows install to another
Asked Answered
W

2

35

I have VisualSVN Server on my Vista laptop. The repository resides on the second hard drive. I am doing a clean install of Windows 7 in the next few days.

How do I configure or install VisualSVN Server again and keep the users, repositories, and settings intact from the previous installation?

Winegrower answered 22/10, 2009 at 18:17 Comment(1)
You need to follow the steps specified in the article KB166: Migrating VisualSVN Server to another computer.Mushy
G
57

You can simply copy the folder containing the repositories (e.g. c:\repositories) to the new machine. That folder contains all the users (in the file htpasswd) and the access rights (authz).

Note: this is true if you're using subversion authentication. I'm not sure if it's the same when using windows authentication, but I guess it is, since there's also a file named (authz-windows).

Detailed instructions:

  • on the new server, install VisualSVN server
  • during the installation, you are asked where the repositories should be put (the default is c:\repositories)
  • once the server is installed, go to the old machine and open the VisualSVN Server Manager
  • right-click the VisualSVN Server (local) entry in the console and click Properties
  • it the dialog you can find where the repositories are currently located
  • copy everything contained in that folder to the new server's repository folder (e.g. c:\repositories)
  • maybe you'll have to restart the server, but then everything should be up and running
Gilmer answered 22/10, 2009 at 18:29 Comment(7)
How do I configure visualsvn to do that? Thats my question.Winegrower
It works just the same for the authz-windows file. No restart required for the actions you've described.Marybelle
Beware that with windows authentication security, it will only work if you have domain users or groups defined. If you add windows users locally, these are tied to the computer of course, and will not work on computer 2. I experienced this when I used local groups for grouping members of AD. The group is undefined on the new computer, and all information about who was in those groups are unknown.Raimes
Using Windows authentication, I switched to svn auth and re created users I saw in the log. Worked like a charm for meUndergarment
"on the new server, install VisualSVN server" does this need to be same version or can be newer major or minor version?Squiffy
@Squiffy aim to migrate to the same version then backup and upgrade on the new server / instance. I apply same principle to all Platform migrations. "Mi-grades" tend to cause headaches.Airedale
More detailed and official instructions are given in the article KB166: Migrating VisualSVN Server to another computer.Mushy
C
2

The roles/users are stored in the files groups.conf and htpasswd under the "Repositories" folder and can be copied to the new server. The individual permissions for each repo are stored in the VisualSVN-SvnAuthz file under "Repositories\your-repo\conf" and can also be copied as-is.

The best way to transfer the data history of the repos without getting incompatible file system errors is to create a dump file for each repo, then copy the dump file to the new server and import the dump file on the new server. You need to use the command line tool available in the VisualSVN Management console to create these dump files. Visual SVN has good documentation for the specifics here: http://www.visualsvn.com/support/topic/00010/

Cupidity answered 26/8, 2013 at 20:26 Comment(1)
No, you do not need to use dump files when you move VisualSVN Server from one computer to another.Mushy

© 2022 - 2024 — McMap. All rights reserved.