Porting a CVS server to a new box

Recently, my team ported their CVS server to a new box. Here’s my story.

Switching over the Dev Boxes

We wanted to move our CVS repository from ‘oldserver’ to ‘newserver’. We copied over the CVS root. The first problem we encountered is that the CVS server version installed on the new server does not support the ‘pserver’ protocol for the version of the CVS client used by Eclipse. Okay, we switched to the ‘extssh’ protocol. Next, we found that CVS on the command-line on our Windows boxes (i.e. the latest version of CVSNT) supports ‘pserver’ fine with the new server…but not ‘extssh’. Okay, so we uninstalled the latest version of CVSNT and installed an older version (i.e. CVSNT 2.0.51d).

Switching over the CVS Server

Next, we found that there were some scripts on the CVS server that were unsuccessfully using ‘pserver’ to login into the CVS repository. Since the scripts were on the same machine as the repository, we switched the protocol to ‘local’ and bypassed the login.

Switching over the Build Boxes

There were about 30 slave boxes in the build process to be switched over to ‘newserver’. Here are the steps we needed to execute:

cd D:\cvslocal
rd /s /q project
cvs -d :extssh:cvsuserid@newserver:/cvsroot login
cvs -d :extssh:cvsuserid@newserver:/cvsroot co project

The problem with the login is that you have to type the password in manually. It turns out you can specify the password after the userid. Also, we can save a line by using the ‘/D’ option with ‘cd’:

cd /D D:\cvslocal
rd /s /q project
cvs -d :extssh:cvsuserid:password@newserver:/cvsroot login
cvs -d :extssh:cvsuserid@newserver:/cvsroot co project

Finally, we can stick this all on one line:

cd /D D:\cvslocal & rd /s /q project & cvs -d :extssh:cvsuserid:password@newserver:/cvsroot login & cvs -d :extssh:cvsuserid@newserver:/cvsroot co project

It's only fair to share...
Share on Facebook
Tweet about this on Twitter
Share on LinkedIn

Leave a Reply