Wednesday, January 17 - Un-Good Things & CVS Experiments
As many of you no doubt already know, Tom Syroid and family are having a very bad week. The Daynotes Gang and the Netwidows are both doing what they can to help out, but more emails and cards and well-wishes can't hurt.
CVS, for those who are unclear, is "Concurrent Versions System". It's a version control system, designed for developers, but really with a lot of uses for almost anyone. I've used it several times for various things, both as a client to a server (for example, a lot of the Open Source projects make their CVS repository publicly available, so that you can grab the latest versions of their code) and as a stand-alone system. CVS is rapidly becoming the standard low-budget version control system; high-end commercial systems like ClearCase still have their definite advantages, but most of us can't afford the time and hardware needed to support it.
At any rate, several of the developers here at Siebel want to use CVS for some of their projects. Hmm. Strangely, setting up a public (well, OK, shared) CVS server is something I've never done. I'm going to keep track of my thoughts here, and hopefully, someone will be able to make use of it.
Step one; find a server. That's easy, we've got a server handy that isn't doing anything much, running RedHat 6.1. Good enough. Next, disk space... uh. Not really enough, although there's plenty of free space on the drive. OK, so let's create a special partition just for the CVS respository.
- Create a new partition. The easiest way (under Linux) is with "cfdisk".
- 'su' to root
- run "/sbin/cfdisk /dev/sdb" (or whatever drive you're creating the partition on)
- select any entry labeled "free space" and select "Create"
- Enter the size in MB for the partition
- Create the filesystem type by selecting the new partition and selecting "Type"
The one we want is most likely "85", "Linux Extended", although it doesn't HAVE to be
- Select "Write" to write the new partition table to the disk
- If necessary (cfdisk will give you a message if it is) reboot the system with "shutdown -r now"
- Now, we need to format the new partition.
- 'su' to root
- run "/sbin/mke2fs /dev/sdb6" (substituting the name of the partition you created above, of course)
- check the filesystem to make sure it's ok with "/sbin/fsck /dev/sdb6"
- Finally, we need to mount the partition so the system can access it.
- 'su' to root (catching a theme here? <G>)
- Use your favorite editor to modify the "/etc/fstab" file
- The line I added was "/dev/sdb6 /cvs ext2 defaults 1 1" at the end of the file. That means I told fstab of the existence of /dev/sdb6 - my new partition, told it the name I wanted it to use (the "mount point" - /cvs), the filesystem type (ext2). The last three columns define the permissions, more or less, that the new partition uses by default. Play it safe and copy one of the existing permissions, in this case, the permissions for /.
- Mount the partition; "mount /cvs"
So now we have our partition ready for use. Time to put it to use by installing CVS. Since this is a RedHat based system, I can use an rpm.
- Download the latest CVS rpm from their website.
- 'su' to root... again
- "rpm -ivh cvs-1.11-1.i386.rpm" or, if you already have an older version installed, "rpm -Uvh cvs-1.11-1.i386.rpm"
That was easy, wasn't it? The rest gets more complicated, but I'm going to have to continue it later; if you're interested, the documentation is at the CVS website. Some excellent documentation, too. Why do I need to finish this later? Well, you see, my Internet access is suddenly seriously curtailed. California has instituted rolling blackouts which are affecting the San Mateo offices of Siebel. That means the network which Siebel still insists on running in a centralized formation with San Mateo at the center is now down, including our DNS server, among other things. I can fix that relatively quickly, but I need to go do it. Ciao.