Mock tests, Interview questions, Tutorials and Tech news
 
 
Home > Technology > Comparing SVN and CVS

Comparing SVN and CVS

When starting with a new project , first question which would come to your mind is which VCS to chose. Given a  lot of options in market like CVS,  SVN ,  Mercurial  and Microsoft VSS  , you have to look at you requirements.

If you are looking for something popular , easy to use , low cost and working with distributed teams, you should go either with CVS or SVN.

Here is quick comparison of various VCS used . This is a result of survey done in 2008 by finalbuilder.

SVN or CVS

Soucre control surver

Looking at the results, you would surely go with SVN but one should look at why SVN is getting more popular and is taking over CVS.  SVN was created to fix some problems in CVS.  

Here are some major differences :

1. Repository basis

CVS is based on RCS files of versions control. Each file connected to CVS is an ordinary file containing some additional information. It is quite natural that the tree of these files repeats the file tree in the local directory. Thus, with CVS you should not be anxious about data loss, and you can easily correct RCS files if necessary.

The basis of SVN is a relational database (BerkleyDB) either set of binary files (FS_FS). On one hand, this settles many problems (for example, concurrent access through the file share) and enables new functionalities (for example, transactions at operations performance). However, on the other hand, data storage now is not transparent, or at least is not available for user interference. That is why the utilities for “curing” and “recovering” of the repository (database) are provided.

What does this mean ?

CVS repository files are rcs-format files that you can easily understand and manipulate with a text editor. SVN repository files appear to me to be opaque blobs. If the file system gets partially corrupted, you may well be better off with CVS.

2. Tracking history

CVS only tracks modification file by file while SVN tracks a whole commit as a new revision, which means that it is easier to follow the history of your project. Add the fact that all modern source control software use the concept of revision so it is far easier to migrate from SVN than it is from CVS

3. SVN supports versioning of binary files

4. SVN adds transactional commit (all or nothing)

5. Subversion doesn’t distinguish between file system space and “branch” space; branches and tags are ordinary directories within the filesystem.

In CVS, branches and tags are different things. A tag is a label for a revision. They are pretty useful for things like marking a RELASE tag for files to sync to your webserver.

Branches live in the same ‘namespace’ as the main file — it’s easy to track down all the mods of a particular file.

6.  Subversion can’t look at a file and tell you at what point someone created a branch or tag from it. Tools like CVSGraph can use this information to draw a tree of a file’s history. To do that with Subversion, you’d need to search all the branch/tags directories, and I haven’t seen any tools that do this well

7. You can move or rename files or directories cleanly in SVN

7. Commits are change sets on the whole tree (not just histories on individual files)

This post Subversion for CVS users can help answer your questions

Here is another link in wiki comparing CVS and SVN.

Updated : Subversion named sole leader in the Forrester 2007 Wave Report for standalone SCM
http://www.collab.net/forrester_wave_report/index.html
“Subversion’s strengths are scalability, administration, and geographical distribution. Subversion’s ability to scale to meet enterprise needs is well established, with single instances managing 7,500 users… Subversion is also easy to implement and administer: Subversion customer references reported initial implementation times of less than a month and administrator-to-user ratios of better than 1:1,000”, writes Carey Schwaber, Senior Analyst at Forrester Research, The Forrester Wave: Software Change and Configuration Management, Q2 2007

Be Sociable, Share!
Categories: Technology Tags: , ,
  1. Corba D. Geek
    September 21st, 2010 at 19:01 | #1

    @Corba D. Geek
    Another point I wanted to make is that this survey may not show Git and Bazaar development that uses Subversion as their central repository, which then under-represents the adoption of the distributed version control systems.

  2. Corba D. Geek
    September 21st, 2010 at 18:59 | #2

    One of the things that their survey probably can’t show is one of the niftier features of adopting Subversion. You can use distributed version control systems like Git and Bazaar as the front-end to a Subversion repository. That makes for an easy transition for teams wanting to migrate from central repositories to distributed ones. (There are probably other DVCSes that can use Subversion as their central repository, but I know from experience that Git and Bazaar work well with it. Of those two I prefer Bazaar. It’s easier to use. Git reminds me of Corba… too many exposed wires.)

    My previous job involved using CVS. I hadn’t used it in several years, so it was quite a flashback to use it again. I had forgotten how often CVS would lose its mind (and my commit). After you’ve encountered a few “no repository version” messages when you go to commit your changes, you’ll run screaming for the exits.

    Regarding the survey, it’s my impression that the graph reflects the number of repositories used by FinalBuilder users. Probably the reason CVS still shows up on the survey is the number of older repositories that haven’t yet been converted to something more modern. The migrations are relatively easy. Unfortunately, switching all the build and deploy scripts from one VCS to another is non-trivial.

  3. Simon
    September 21st, 2010 at 18:41 | #3

    If the file system gets partially corrupted, you may well be better off with CVS.

    Oh, that’s wonderful advice. Here’s a hint – if file system corruption in your repository is a common enough problem to influence your choice of source control system, you have far bigger problems than your choice of source control system.

  4. Simon
    September 21st, 2010 at 18:37 | #4

    Like others have said, who cares about CVS vs SVN these days? CVS is dead, it’s remaining user base hanging on through inertia. And while SVN was the big thing five years ago, it’s on the way out itself, in favour of modern tools supporting a distributed model – Git, Hg, Bz.

    You’re quoting reports and surveys from two or three years ago. They’re meaningless – they might as well be ten, twenty years ago for all the relevance to developers 2010.

  5. Lazy Anonymous Coward
    September 21st, 2010 at 18:15 | #5

    CVS in 2010? You must be joking. Didn’t eve bother to read your article, I just clicked the link because I couldn’t believe someone would actually post something like this in 2010.

  6. SteveP
    September 21st, 2010 at 16:10 | #6

    I agree CVS is not really in the evaluation nowadays. SVN still is though. I’d like to see the survey question that generated this. I suspect it was “which SCMs are in use at your company?” or something similar. I don’t believe anyone is voluntarily using VSS for any new projects. One legacy project somewhere is still using it though in Microsoft shops.

  7. brian
    September 21st, 2010 at 15:50 | #7

    This article should really be taken with a gigantic grain of salt. I actually question the worth of something that only evaluated SVN vs. CVS in this day and age. Is there really anyone out there picking CVS for any new project?

    Showing a Forrester report for 2007 just makes the issue funnier. I have an article from 1956 that talks about how awesome Ford Motor Company is.

    This doesn’t seem like it was written by a “skill guru” at all, just someone trying to write an article for class. (an old timey class).

  8. September 10th, 2010 at 13:44 | #8

    And for all those of you you had been talking against SVN
    Subversion named sole leader in the Forrester 2007 Wave Report for standalone SCM
    http://www.collab.net/forrester_wave_report/index.html
    “Subversion’s strengths are scalability, administration, and geographical distribution. Subversion’s ability to scale to meet enterprise needs is well established, with single instances managing 7,500 users… Subversion is also easy to implement and administer: Subversion customer references reported initial implementation times of less than a month and administrator-to-user ratios of better than 1:1,000”, writes Carey Schwaber, Senior Analyst at Forrester Research, The Forrester Wave: Software Change and Configuration Management, Q2 2007

  9. September 10th, 2010 at 13:34 | #9

    Some other comments of users were
    enachd – Why anyone in their right mind would even consider CVS (released in 1990) for a new project is beyond me.

    miki – RCS is still in use for local file versioning, but CVS isn’t even maintained anymore. The only thing it had going for it were server-side validation or pretty-formatting plugins (whereas SVN always saves as-is).

    Worth to point out are DVCS newcommers. Git/Mercurial/Bazaar are difficult to set up for Windows users, but Fossil SCM is cross-plattform and simple and easy enoughto set up for most tasks. (Less features than SVN makes it actually more usable.)

    My response was
    Thanks you for your comments.
    1. if Git/Mercurial/Bazaar are difficult to set up in windows , what choices are the users left with ?
    2. If you are working in remote teams, the cheapest options you get for source control is CVS or SVN not gilt or mercurial.

  10. Laurent
    August 30th, 2010 at 02:39 | #10

    As Clovis said, I can’t either believe it’s an article of 2010. It’s difficult to understand that git is not mentioned in this article. The world of version control has evolved a lot in the last few years.

  11. August 28th, 2010 at 17:46 | #11

    @Alex @Clovis I have not yet looked into gilt or mercurial but reading your comments I think I need to find more about them.

  12. Clóvis Valadares
    August 28th, 2010 at 12:28 | #12

    Can’t believe that post is from 2010. I was thinking it is from 2006. Please, use git, mercurial or fossil. Forget cvs and svn for future projects.

  13. Alex
    August 27th, 2010 at 20:09 | #13

    CVS vs. SVN? Is it 2005?

  14. August 27th, 2010 at 15:03 | #14

    Thanks for your comment Madth3.
    Referring to your point 5, I am not sure what is meant do you mean by cheap copy.
    From svn docs
    http://svnbook.red-bean.com/en/1.1/ch04s02.html#svn-ch-4-sect-2.3
    The Key Concepts Behind Branches

    There are two important lessons that you should remember from this section.

    1. Unlike many other version control systems, Subversion’s branches exist as normal filesystem directories in the repository, not in an extra dimension. These directories just happen to carry some extra historical information.
    2. Subversion has no internal concept of a branch—only copies. When you copy a directory, the resulting directory is only a “branch” because you attach that meaning to it. You may think of the directory differently, or treat it differently, but to Subversion it’s just an ordinary directory that happens to have been created by copying.

  15. Madth3
    August 27th, 2010 at 14:45 | #15

    Interesting points but I got some comments:
    Point 1: I’ve seen this argument before but I think people need to carefully plan backups and let go. :)
    Point 3: CVS also supports binary files. (Of course, I’d agree if want to to call SVN binary support better, or proper)
    Point 5 is not completely accurate since, in the server, a branch (tag) is just a cheap copy.

    Finally, IMHO, points 6, 7, 3 (ammended) and cheap copies make the choice of CVS over SVN a much harder one.

  16. August 26th, 2010 at 15:39 | #16

    Thanks you Glenn.

  17. Glenn
    August 26th, 2010 at 09:41 | #17

    very informative!
    Most of us use these two but these are very specific comparison.
    thanks.

  1. October 2nd, 2010 at 11:33 | #1
  2. November 8th, 2010 at 20:03 | #2
  3. December 28th, 2010 at 06:55 | #3

Get Adobe Flash playerPlugin by wpburn.com wordpress themes