Sign in to follow this  
Sykoi

CVS Servers

Recommended Posts

Sykoi    139
I apologize if this is in the wrong forum, I've spent the past 3 hours trying to get CVS setup on my server and I'm a bit agitated (So figuring out which forum is 'the best' for this, isn't on my top 10 list of things to do right now) That being said, I think I'll get right into why I'm here: CVS Servers are a pain to setup, and I'm about to pull my hair out; I ran into a few errors/problems and am honestly thinking about buying an account at CVSDude (Worth it?). The bugs/errors/problems are: 1) When running 'cvs import -m "Bleh" main sykoi start' - I get "cvs [import aborted]: attempt to import the repository" - that error kind of makes you wonder... What the hell just happened? 2) I can actually start cvs with 'cvs pserver', and it runs fine - the only problem is... It always says 'refused connection' or something similar, when I try to connect. I setup '/CVSROOT/passwd', and used
Quote:
GNU nano 1.2.1 File: cryptout.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, eval $randletter); my $plaintext = shift; my $crypttext = crypt ($plaintext, $salt); print "${crypttext}\n";
The above script (That I got from here), to create the password... But yet, it doesn't work - the password generated every time is different (Obviously since he uses time()). Does this matter at all? I don't know much about how linux handles user's passwords (Which is supposedly what CVS uses too), so I'm a bit lost. -------- Those are pretty much the only two errors left (That have stumped me for 30 minutes). If anyone can help me, It'd be very nice - I'd rather NOT setup a FreeVCS server again, since its Windows-only and isn't that great. Also: Who here has used CVSDude? I was looking through the upgrade plans and the price, features, etc. - all seem pretty nice; is it worth it? I can see a few bonuses from having them host your CVS: 1) You can complain to someone other than yourself if the CVS goes down. 2) They back up your files often 3) It’d be on a fast server 4) A bunch of other goodies already setup and installed (Some of which are a pain to setup) But the negatives out-weight the positives for me right now (Until I've talked to someone who uses them): 1) Its a CVS server that you don't own - someone else has access to all of your files, your code, etc. 2) They could drop everything and run with everyone's code... Well thanks if anyone can help me with any of these problems here, it’d probably save me some frustration.

Share this post


Link to post
Share on other sites
Kwizatz    1392

have you done a cvs init?

if not, you should:

$ cvs init /path/to/your/repository

have you set your CVSROOT enviroment variable?
if not, use -d to specify the cvsroot, this is probably:

:pserver:yourusername@localhost:/path/to/your/repository

for example if you have a directory named "code" which you want to add to CVS:

$ cvs -d:pserver:yourusername@localhost:/path/to/your/repository login <enter>

$ cvs -d:pserver:yourusername@localhost:/path/to/your/repository import -m "my code" /home/yourusername/code code start

have you checked out CVSROOT, added your user to the "writers" file and commited back?
if not, you should, right after you have done a cvs init do:

$ cvs -d:pserver:yourusername@localhost:/path/to/your/repository login <enter>

$ cvs -d:pserver:yourusername@localhost:/path/to/your/repository checkout CVSROOT

find the "writers" and "admin" files inside and modify it so it contains your username, or the usernames for the users you want to allow write access to the repository, then do a commit on the CVSROOT directory.

Share this post


Link to post
Share on other sites
Sykoi    139
Quote:
Original post by igni ferroque
See if this helps. If not, you might want to look into Subversion. Subversion tends to be easier to work with, and a lot of projects are migrating to it from CVS.


Thanks, I'll take a look at that site but I'm probably moving to subversion.

One question, though: One of my programmers is living on campus, and his university doesn't allow the students to install new software; BUT! He already has WinCVS and .NET installed; can he use subversion? I couldn't find anything on their site about backwards compatibility with CVS, so I'm not sure (And I don't want to go through the trouble of installing it if not everyone can use it)

Share this post


Link to post
Share on other sites
Sykoi    139
Quote:
Original post by Kwizatz

have you done a cvs init?

if not, you should:

$ cvs init /path/to/your/repository

have you set your CVSROOT enviroment variable?
if not, use -d to specify the cvsroot, this is probably:

:pserver:yourusername@localhost:/path/to/your/repository

for example if you have a directory named "code" which you want to add to CVS:

$ cvs -d:pserver:yourusername@localhost:/path/to/your/repository login <enter>

$ cvs -d:pserver:yourusername@localhost:/path/to/your/repository import -m "my code" /home/yourusername/code code start

have you checked out CVSROOT, added your user to the "writers" file and commited back?
if not, you should, right after you have done a cvs init do:

$ cvs -d:pserver:yourusername@localhost:/path/to/your/repository login <enter>

$ cvs -d:pserver:yourusername@localhost:/path/to/your/repository checkout CVSROOT

find the "writers" and "admin" files inside and modify it so it contains your username, or the usernames for the users you want to allow write access to the repository, then do a commit on the CVSROOT directory.



Thanks it worked, but I still can't login... I'm using 'cvs -d:pserver:sykoi@localhost:/home/cvs/bin/tatsu/CVSROOT login'

Then of course, typing in my password when asked for it - but it keeps returning:
'cvs [login aborted]: connect to localhost(127.0.0.1):2401 failed: Connection refused'.


I used my perl script to make a password, added it correctly - the user also exists on the machine with a different password, and was added to group 'cvs'; group 'cvs' was given permissions to the CVSROOT folder too - but yet none of the logging in works, at all, no matter what I try.



I'm also very confused on the admin access in WinCVS; how exactly do you grant a user admin access?

Share this post


Link to post
Share on other sites
Kwizatz    1392
Quote:
Original post by Sykoi
Thanks it worked, but I still can't login... I'm using 'cvs -d:pserver:sykoi@localhost:/home/cvs/bin/tatsu/CVSROOT login'


use 'cvs -d:pserver:sykoi@localhost:/home/cvs/bin/tatsu login'

CVSROOT is the "configuration" module for the repository, after successfull login you should be able to do:
'cvs -d:pserver:sykoi@localhost:/home/cvs/bin/tatsu checkout CVSROOT'

Quote:
Original post by Sykoi
Then of course, typing in my password when asked for it - but it keeps returning:
'cvs [login aborted]: connect to localhost(127.0.0.1):2401 failed: Connection refused'.


maybe you have some firewall running which is blocking the 2401 port? is the CVS daemon running?

Quote:
Original post by Sykoi
I used my perl script to make a password, added it correctly - the user also exists on the machine with a different password, and was added to group 'cvs'; group 'cvs' was given permissions to the CVSROOT folder too - but yet none of the logging in works, at all, no matter what I try.


Once you're able to connect as root and checkout the CVSROOT Module, you should be able to modify the "writers" and "admin" files contained within, all you have to do is add the username of the user you want to grant either write access to the repository or admin access to it, one username per line.

Quote:
Original post by Sykoi
I'm also very confused on the admin access in WinCVS; how exactly do you grant a user admin access?


add the user to the admin file under CVSROOT (see above) I am guessing you have a Linux or some other unix flavor CVS server and a Windows client right? or are you running CVSNT on a Windows server?

Share this post


Link to post
Share on other sites
Sykoi    139
Quote:
Original post by Kwizatz
Quote:
Original post by Sykoi
Thanks it worked, but I still can't login... I'm using 'cvs -d:pserver:sykoi@localhost:/home/cvs/bin/tatsu/CVSROOT login'


use 'cvs -d:pserver:sykoi@localhost:/home/cvs/bin/tatsu login'

CVSROOT is the "configuration" module for the repository, after successfull login you should be able to do:
'cvs -d:pserver:sykoi@localhost:/home/cvs/bin/tatsu checkout CVSROOT'

Quote:
Original post by Sykoi
Then of course, typing in my password when asked for it - but it keeps returning:
'cvs [login aborted]: connect to localhost(127.0.0.1):2401 failed: Connection refused'.


maybe you have some firewall running which is blocking the 2401 port? is the CVS daemon running?

Quote:
Original post by Sykoi
I used my perl script to make a password, added it correctly - the user also exists on the machine with a different password, and was added to group 'cvs'; group 'cvs' was given permissions to the CVSROOT folder too - but yet none of the logging in works, at all, no matter what I try.


Once you're able to connect as root and checkout the CVSROOT Module, you should be able to modify the "writers" and "admin" files contained within, all you have to do is add the username of the user you want to grant either write access to the repository or admin access to it, one username per line.

Quote:
Original post by Sykoi
I'm also very confused on the admin access in WinCVS; how exactly do you grant a user admin access?


add the user to the admin file under CVSROOT (see above) I am guessing you have a Linux or some other unix flavor CVS server and a Windows client right? or are you running CVSNT on a Windows server?


I tried everything you listed and nothing works :( - I'm also not running any firewall on my server.

(And yes, Its on linux)



Also, one more thing I noticed... Every time I logout and back into the box (Using putty), the CVSROOT=/directory, and 'cvs init' have to be redefined (It says they don't exist, and I need to define them each time).

Share this post


Link to post
Share on other sites
C-Junkie    1099
Um, to use pserver, you ahve to have the cvsd running (otherwise you should be using ssh access)

Is cvsd running? (or whatever it's called, I haven't worked with it in awhile)

Share this post


Link to post
Share on other sites
Sykoi    139
I've been running it in SSH, and also have 'cvspserver stream tcp nowait root /home/cvs/bin/cvs --allow-root=/home/cvs/bin/tatsu pserver' in inetd.conf (Triggered by port 2401) - so there shouldn't be a problem with running the server :-/.

-----
I just tried runing '/home/cvs/bin/cvs --allow-root=/home/cvs/bin/tatsu pserver -t' and then connecting through SSH on another account, and it spits out 'connection refused' too :( (And there wasn't any debug info on the server-side session either)

Share this post


Link to post
Share on other sites
Kwizatz    1392
well, I am clueless about what might be going on, but to have the CVSROOT variable available every time you log in add the command to /etc/profile or ~/.bash_profile , adding a line like:

export CVSROOT=:pserver:sykoi@localhost:/home/cvs/bin/tatsu

or

CVSROOT=:pserver:sykoi@localhost:/home/cvs/bin/tatsu ; export CVSROOT

Should do the trick

Edit: You know what?, try :ext:sykoi@localhost:/home/cvs/bin/tatsu instead of pserver, that should work.

Share this post


Link to post
Share on other sites
Sykoi    139
Quote:
Original post by Kwizatz
well, I am clueless about what might be going on, but to have the CVSROOT variable available every time you log in add the command to /etc/profile or ~/.bash_profile , adding a line like:

export CVSROOT=:pserver:sykoi@localhost:/home/cvs/bin/tatsu

or

CVSROOT=:pserver:sykoi@localhost:/home/cvs/bin/tatsu ; export CVSROOT

Should do the trick

Edit: You know what?, try :ext:sykoi@localhost:/home/cvs/bin/tatsu instead of pserver, that should work.


:ext: isn't a command, and when I set it to WinCVS's login method, it says 'cvs [login aborted]: The :ext: protocol does not support the login command'; so I have no idea how to connect. Thanks for the help, though.

Share this post


Link to post
Share on other sites
Toolmaker    967
I'm using Subversion. I had a bit of problems setting it up for the 2nd time, but that was because I was trying to do things that I wasn't suppose to do.

SVN runs for me on Windows 2000 with Apache. The most basic setup(Using Basic htpasswd setup) takes around 1 hour to setup, including reading some docs. Might take another 15 minutes for AuthZ setup, and if you want to you link the SVN users to your Windows ADS if you're running a server with ADS enabled.

For Visual Studio.NET I have a plugin called AnkhSVN(Arild Fines is one of the developers off Ankh, and he helped me out quite some times). For all the other stuff, such as initial checkout I use the command line tool.

Toolmaker

Share this post


Link to post
Share on other sites
Sykoi    139
Quote:
Original post by Toolmaker
I'm using Subversion. I had a bit of problems setting it up for the 2nd time, but that was because I was trying to do things that I wasn't suppose to do.

SVN runs for me on Windows 2000 with Apache. The most basic setup(Using Basic htpasswd setup) takes around 1 hour to setup, including reading some docs. Might take another 15 minutes for AuthZ setup, and if you want to you link the SVN users to your Windows ADS if you're running a server with ADS enabled.

For Visual Studio.NET I have a plugin called AnkhSVN(Arild Fines is one of the developers off Ankh, and he helped me out quite some times). For all the other stuff, such as initial checkout I use the command line tool.

Toolmaker



Well I'm fed up with CVS so where do you suggest I get a step-by-step document for svn? I tried the one on their site; its good, but I can't find where it installs to... :-/

Kwizatz: I didn't try to login with :ext:, only tried to check the files out - and it didn't work (Same error) :(

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this