2008-01-16

I installed CVS on my Ubuntu 7.10

I installed CVS on my Ubuntu 7.10 in order to have the version control for some projects. Especially record the history of the source files I modified. What I did while setting up CVS server as following.

1. Install CVS client:

root@xtrf74:# sudo apt-get install cvs


2. Install CVS server:

root@xtrf74:# sudo apt-get –purge remove cvsd // remove old cvsd from Ubuntu 7.10

root@xtrf74:# sudo apt-get install cvsd

A blue screen will be shown to prompt you enter the location of the repository. Just remove the default value ( /demo:/mycvs or something like that ), and type a new one. E.g. /cvsroot

3. Configure CVS:
build the cvsroot:

root@xtrf74:# cd /var/lib/cvsd
root@xtrf74:# sudo cvsd-buildroot /var/lib/cvsd

create the folder cvsroot under /var/lib/cvsd:

root@xtrf74:# sudo mkdir cvsroot

and then create the repository:

root@xtrf74:# sudo cvs -d /var/lib/cvsd/cvsroot init

it will set up an empty repository in the CVS root specified in the usual way.

root@xtrf74:# sudo chown -R cvsd:cvsd cvsroot

create a user and password:

root@xtrf74:# sudo cvsd-passwd /var/lib/cvsd/cvsroot +

You will be asked to enter new password for the account.

and then change the AUTH type:

root@xtrf74:# sudo chmod 777 /var/lib/cvsd/cvsroot/CVSROOT/config
root@xtrf74:# sudo vim /var/lib/cvsd/cvsroot/CVSROOT/config

uncomment the "SystemAuth=no" line.

4. Check the configuration:
Run the debug info for CVS:

root@xtrf74:# cvsd-buginfo

You will see the following in the middle of the output, make sure that the last one "Repos /cvsroot" is correct, in some cases it might be something like "/decvs" and you cvs server will break, because they don't match with your setup.

...........................
/etc/cvsd/cvsd.conf:
RootJail /var/lib/cvsd
Uid cvsd
Gid cvsd
Nice 1
Umask 027
PidFile /var/run/cvsd.pid
MaxConnections 10
Log syslog info
Listen * 2401
Repos /cvsroot
...............................

5. Test it(Optional):

root@xtrf74:# cvs -d :pserver:@localhost:/cvsroot login

If you login successful, you will see something similar as below:

cvs login: CVS password file /home//.cvspass does not exist - creating a new file

6. Add new files from,for example, /home/xxx/kscope_src

cd /home/xxx/kscope_src/
cvs –import –m “kscope source” /cvsroot kscope initver

No comments: