Clearcase vs. CVS?
briany asks: "I have been asked to evaluate Clearcase vs. CVS. I am wondering what kind of experiences people have had (good and bad) with either product, or if there are other products that should be considered.
The projects that will be stored are rather large (10+ GB) and need to be accessible from Solaris, Linux, and NT/Win2k." Of course, it should be mentioned that Clearcase is available for Linux, as well as other unix clones.
Clearcase cost a LOT of money and takes quite a bit more administration. For your trouble, you get file locking. Yes, that is sarcasm. No one on the team who was using it at the time liked it.
cvs simply requires a little more developer time to do file merging. I personally really like it.
I've used CVS a lot, but never in big projects. I was told I had to use clearcase once, and the sysadmin botched the install so bad I dumped it and they backed off when I threatened to quit. (I was on a separate project with only a few programmers who were all happy with CVS, so the rest of the dev staff could use punched cards and it wouldn't have bothered us.)
For what it's worth, I understand one big difference is that clearcase automates things like tracking the compiler and lib versions, so you could go back a long long ways to reproduce a really old version byte for byte. Another difference is that it eliminates dup copies of source and object files among the staff, potentially saving space and time. How well this works in practice, I don't know, and I've never felt any need for it.
The other comment about needing more sysadmin work is certainly true. In addition to the loon who clobbered my system with the bad install (Sun OS, early 90s), a different sysadmin, purportedly her boss, twice erased the entire clearcase repository. Apparently it was too tricky for the average bear. I see that as two strikes against clearcase just from the point of not being very maintainable, and hope to never see it again.
CVS is good. Text files you can edit in an emergency or just in readonly mode to see when things happened, as opposed to SCCS, and it is just plain good. Be happy with CVS. Your repository is valuable -- don't give up control.
--
Infuriate left and right
I'm working in such an environment myself, Linux server (actually a NetApp filer hosts our repository now, but pserver still runs on the Linux box for NT clients) and NT, Linux and Solaris clients. As a startup, we could not afford a pricey, commercial VCS, and with what we do, CVS was a perfect fit (yes, I have used a number of different, "pricey" systems before). We are a fabless semiconductor firm, so we often have large, textual files (as well as small). CVS works very well for us, and is easy to administer once you get familiar with it. There is no issues with NT and UNIX clients, CVS handles them all of them from the server side, assuming you run CVS in pserver client/server mode (from at least for the NT clients).
Your sole documentation for CVS (other than the occassional Google search) will probably only need to be the Cederdqvist CVS Manual (here in HTML). If you aren't too familiar with CVS yet, you'll want to play around with a test repository while reading this manual for a month. Trust me, that is what I did the first time around.
In a nutshell, here are my recommendations for a CVS setup, with large files and a both NT and UNIX clients:
[ Note, there is a TkCVS client for UNIX, but it is _way_outta_date_. So don't use it except for possibly looking a work file status as well. In the case of both WinCVS and TkCVS, there is a _lot_ to be said about sticking with the CLI CVS client when checking in/out files -- I don't trust the GUIs to be flexible enough with anything but "browsing" the working files, but that's me. ]
[ Side note: If your setup and workflow is anything like mine (e.g., either NT or dual-boot NT/Linux on desktop, Solaris workstations in a lab), and an X-Server for NT is too expensive, you'll probably want to investiage Virtual Network Computing (VNC). VNC on a UNIX server (as compared to just using it as a simple pcAnywhere type setup on Windows servers, as most people do), is powerful. It is how we have ~10 different engineers running full GUIs on a single Solaris or Linux workstation, each with their own X-session (:1, :2, etc...). Then you simply connect from the Windows client and tada, a full X-session -- that even stays up when NT crashes! Or can be "shared" by Microsoft NetMeeting. Just thought I'd mention VNC since you probably have the same situation/setup I do. ]
-- Bryan "TheBS" Smith
-- Bryan "TheBS" Smith
Independent Author, Consultant and Trainer
But it is so much more elegant than CVS if your use of version control is at all sophisticated! (Which, if your development effort is even medium size, I would argue it should be--this is stuff that pays off. But that is a separate discussion.)
For starters, there are some simple correctness issues. Clearcase tracks files across renames, which I gather CVS does not. Moreover, it versions directories, so if you look at an old view of the repository, you see the old names. This allows everything from corrections to badly chosen filenames, up to reorganization of the repository, without any fuss.
Clearcase also has a "findmerge" command with "common ancestor" support. This basically means, when it's time to merge, you always know exactly what you need to merge, with previous merges taken into account. I honestly don't know how you could live without this. (Note this is distinct the tool that actually performs merges, which is nothing special--I just use GNU diff3, myself.)
Second, clearcase has (to me) a killer feature, filesystem support. This means that that you get an ordinary-looking unix filesystem that automatically gives you the latest versions that you're interested in. Further, using an "extended" filename syntax, you can look at any version right from the filesystem. So if you want to see what's going on in the foo branch, you just vim code.c@@/main/foo/LATEST, or if you want to figure out which mainline versions use the fooble API, grep fooble code.c@@/main/*. This is addictive. NB: the filesystem support is not available in Linux :-(
Third, clearcase is very unix-friendly. While this is not a major difference with CVS, it is still worth pointing out (since many commercial products "don't get" unix). Most clearcase commands are close to their unix analogs (or in the same spirit, when there is no analog), and the documentation is in man pages. For me, this made learning clearcase easy, and adds a significant comfort factor.
To me, version control is not just about making sure I can work on my stuff without getting stepped on by anyone else. (CVS is fine for that.) It's also about expressing, understanding and managing the relationships between various versions and branches. This is a conceptually more difficult activity, and I frankly think many posters here don't see its value (it takes a while). But if you do, clearcase wins hands-down.
I admit that, while I have used CVS, I have only had day-to-day experience with clearcase (and Visual SourceSafe--bleh!), so I don't have a good sense of the "CVS routine". It perhaps includes some practices that mitigate the lacks I've cited. But, as long as someone else is taking care of the cost and administration and resources (under these circumstances, I have found clearcase reliable, if still a bit pokey), and I don't have to interoperate with outside developers who don't have clearcase, I would take clearcase in a second.
The evaluation of an action as 'practical' . . . depends on what it is that one wishes to practice.
I've used CVS, PVCS, VSS, (but not ClearCase), and Perforce is the best system I've ever used, bar none. Let me go through some of the key points:
- Quality of Support. I put this first becuase I think it's that important. I get same-day turnaround whenever I contact them and it's not a weekend (and I've gotten turnaround within an hour at 1am on sunday, so even then you often do), their tech support people know what they're doing and are willing to go the extra mile.
- The Model's Like CVS. I think this is actually important. To get all the "advantages" of clearcase, you have to be using the ClearCase file system, which basically means that your compiles are over NFS. Do you really want that? P4 gives you a local copy of all the files, just like CVS.
- Server Centric Model. While this can impose some difficulties for fully disconnected access, it saves your ass in a lot of places. Thinking of deleting a file and want to know if someone's working on it? You can see. Thinking of doing a branch and want to see the status of the branch on people's current machines? You can see. This can save you quite a few times.
- Multi-Platform Support Rocks. I've NEVER found a platform which P4 doesn't support. Mac, Win, Linux (we're using it on Intel and Alpha), Solaris, even IA-64 if you've got one, they run on everything. Very nice.
- Ease of Use. If you've got people who are familiar with ANY local-file based source control, they can be up to speed extremely quickly. I've got people who are familiar with CVS who are working extremely well in like 2 hours with P4, rather than weeks of training in CVS. So your training costs are virtually nil with P4 if your people already know CVS or VCC.
- Speed. It's FAST. REALLY fast. Because of the server-centric model, it's able to determine extremely easily what you need to download and what you don't. It uses things like MD5 digests to determine whether you're actually in sync, it uses its database of what you've stored, etc. And then it just downloads a compressed delta of the file and modifies it locally. If you've got people working over not-so-fast links, this will save your ass.
- It's TRANSACTIONAL. The basic unit of transactions is the Changelist. When you check stuff in, it's completely atomic. Either everything's submitted, or nothing is. That's it. So at any time you have, without labelling, a complete, transactional history of everyting that you've ever done, and it means that you can never download in inconsistent states. Everyone is consistent all the time. This also means that you don't have to constantly label everything, because the transaction ID acts as a unique identifier for the state of the database at any given point in time.
- Branching/Merging Rocks. I've never had a case where P4's branching/merging support didn't work perfectly. They detect three way merges, they detect multiple lines of integration/development, it all just WORKS. I can't stress how important this is for quality development, and it's infinitely better than the support in CVS.
- Ease of Administration. I administer 2 perforce servers. I spend, on average, about 2 minutes doing administration. The thing just works perfectly.
- Cheap Hardware. Unlike Clearcase, you can get a fairly cheap box for P4. We're running 25 users with about 70 clients on a $5k box (and most of that is RAM and RAID array), and it's so fast that most people never even notice, because its downloads are about as fast as a filecopy on the network.
- Stores in digested RCS files. So it gets around the corruption issue with some tweaking, but the core files are basically RCS files, which means that if you decide to give it the boot for whatever reason, you can integrate them into another source control system very easily. CVS will have the same issues with corruption that VSS does, because they dont' attempt to deal with the problems that RCS file corruption can incur.
I'm a little partial, but it's an amazing system that you really should evaluate. I think that if you're looking at CVS and ClearCase, P4 gives you the happy medium: faster and cheaper than ClearCase, more enterprise-friendly than CVS.