1. Detect whether CVS was install. If so, remove it.
#rpm -qa | grep cvs
#rpm -e cvs-xxx.xxx..
2. Install tar.gz
#tar -zxvf cvs-1.xx.x.tar.gz
#cd cvs-1.*
#./configure --prefix=/usr/local/cvs --exec-prefix=/usr
--disable-server-flow-control
#make
#make install
3. Add CVS service
# vi /etc/services
cvspserver 2401/tcp #pserver cvs service
cvspserver 2401/udp #pserver cvs service
4. Enable running at startup.
#cd /etc/xinetd.d
#vi cvspserver
service cvspserver
{
disable = no
flags = REUSE
socket_type = stream
wait = no
user = root
env =
HOME =
server = /usr/bin/cvs
server-args = -f --allow-root=/home/cvsroot # cvsroot location
log_on_failure += USERID
};
Note: --allow-root is the directory of Repository, it can be multiple.
5. Restart xinetd
#/etc/rc.d/init.d/xinetd restart
6. Check whether cvspserver is started successfully.
#netstat -l|grep cvs
7. Initialize the cvs service
#groupadd cvs
#useradd -g cvs -s /sbin/nologin cvsroot
#chown -R cvsroot /home/cvsroot
Initialization:
#cvs -d /home/cvsroot init
#chown -R cvsroot.cvs /home/cvsroot
#chmod -R ug+rwx /home/cvsroot
#chmod 644 /home/cvsroot/CVSROOT/config
vi /home/cvsroot/CVSROOT/config
remove the # at the head of "#SystemAuth = no"
8 Create CVS users
8.1 Create passwdgen.pl to generate password
#vi /passwdgen.pl
#!/usr/bin/perl
srand(time());
my $randletter = "( int(rand(26)) + ( int(rand(1)+.5)%2 ? 65:97) )";
my $salt = sprintf("%c%c", eval $randletter $randletter);
my $plaintext = shift;
my $crypttext = crypt($plaintext, $salt);
print "${crypttext}/n";
#chmod +x /passwdgen.pl
#./passwdgen.pl 123456
#vi passwd
username:password:cvsroot
........
#vi writes
username1
.........
#vi reader
user1
......
#rpm -qa | grep cvs
#rpm -e cvs-xxx.xxx..
2. Install tar.gz
#tar -zxvf cvs-1.xx.x.tar.gz
#cd cvs-1.*
#./configure --prefix=/usr/local/cvs --exec-prefix=/usr
--disable-server-flow-control
#make
#make install
3. Add CVS service
# vi /etc/services
cvspserver 2401/tcp #pserver cvs service
cvspserver 2401/udp #pserver cvs service
4. Enable running at startup.
#cd /etc/xinetd.d
#vi cvspserver
service cvspserver
{
disable = no
flags = REUSE
socket_type = stream
wait = no
user = root
env =
HOME =
server = /usr/bin/cvs
server-args = -f --allow-root=/home/cvsroot # cvsroot location
log_on_failure += USERID
};
Note: --allow-root is the directory of Repository, it can be multiple.
5. Restart xinetd
#/etc/rc.d/init.d/xinetd restart
6. Check whether cvspserver is started successfully.
#netstat -l|grep cvs
7. Initialize the cvs service
#groupadd cvs
#useradd -g cvs -s /sbin/nologin cvsroot
#chown -R cvsroot /home/cvsroot
Initialization:
#cvs -d /home/cvsroot init
#chown -R cvsroot.cvs /home/cvsroot
#chmod -R ug+rwx /home/cvsroot
#chmod 644 /home/cvsroot/CVSROOT/config
vi /home/cvsroot/CVSROOT/config
remove the # at the head of "#SystemAuth = no"
8 Create CVS users
8.1 Create passwdgen.pl to generate password
#vi /passwdgen.pl
#!/usr/bin/perl
srand(time());
my $randletter = "( int(rand(26)) + ( int(rand(1)+.5)%2 ? 65:97) )";
my $salt = sprintf("%c%c", eval $randletter $randletter);
my $plaintext = shift;
my $crypttext = crypt($plaintext, $salt);
print "${crypttext}/n";
#chmod +x /passwdgen.pl
#./passwdgen.pl 123456
#vi passwd
username:password:cvsroot
........
#vi writes
username1
.........
#vi reader
user1
......