After upgrading TortoiseSVN and AnkhSVN to SubVersion 1.5, I set about upgrading the server this morning. The main reason for this is that I wanted to merge a branch back into the trunk using the integrated merge option, and this simply doesn’t work with a 1.4x server and repository. Everything needs to be 1.5 for that to work.
We’re currently on 1.4.5 ish, from a previous 1-click Windows/Apache setup with some mods for groups authentication.
I just downloaded the 1.50 server Windows binary and it actually now does a nice thing of asking whether you want to use SvnServe or Apache.
I had some issues originally running Apache 2.2 with 1.4, and ended up with Apache 2.0.x but gave the new 1.5 install a go. The following is how I upgraded my install from 1.4x using the same httpd.conf settings from the previous installation (link above).
Upgrading the Server
- Stop existing services (Apache etc)
- Back up your httpd.conf (my original install was apache 2.0 and went into a different folder) – but you’ll need the settings in any case
- Back up mod_auth_sspi.so from your existing Apache installation (/modules folder). If you were using Apache 2.0 then don’t bother ‘cos it won’t work with 2.2.
- NOTE: If you want to upgrade your repository (required to use new 1.5 merging functionality) you need to first dump out the existing repository using the ‘old’ installation
- Backup the existing repository
- Run svnadmin /repos/path > dumpfile.txt
- You do the rest once you’ve upgraded the server
- Install 1.50 server (choosing Apache and whatever port / repository location you previously had. You’ll replace the repository location later, but make sure your port’s right to save confusion and updates to httpd.conf).
- Edit the new httpd.conf replacing all ‘<Location>‘ sections at the bottom with that from your saved config.
- Paste the following line at the bottom of the LoadModule section
LoadModule sspi_auth_module modules/mod_auth_sspi.so - Copy an Apache 2.2-compatible mod_auth_sspi.so into the /modules folder. As noted above if you take mod_auth_sspi.so that was compiled against Apache 2.0 you’ll get a message along the lines of:
httpd: Syntax error on line 117 of C:/Program Files/CollabNet Subversion Server/httpd/conf/httpd.conf: API module structure ‘sspi_auth_module’ in file C:/Program Files/CollabNet Subversion Server/httpd/modules/mod_auth_sspi.so is garbled – expected signature 41503232 but saw 41503230 – perhaps this is not an Apache module DSO, or was compiled for a different Apache version?
If you go to the home of mod_auth_sspi you’ll only find a module compiled against 2.0 so after hunting around a bit I found a copy compiled against 2.2. Just copy the .so file into your modules folder) - Start her up, and hopefully hey presto, you’ll have 1.50 server. You can verify this easily by loading up the repository url in your browser and the footer should say something like… Powered by Subversion version 1.5.0 (r31699).
Upgrading the repository
- With the new version (1.5) binaries run:
- svnadmin create /temp/repos/path
- svnadmin load /temp/repos/path < dumpfile.txt
- Swap the old and new repository folders (useful to keep the backup)
- You’re all up to date.