On Thu, Feb 09, 2012 at 01:16:10PM +0100, Jan Stary wrote:
> > Otto Moerbeek wrote [2012-02-03 12:47+0100]:
> > > I like to say that long delays I have seen when using cvs had to do
> > > with multiple different values of CVS/Root files in my local tree.
>
> Otto, could you please elaborate?
> How does this slow down a cvs update?
>
> Is it really due to the fact that there are multiple different *values*
> stored in the CVS/Root files? So that cvs needs to consult multiple
> cvs servers, and *that* is what gets slow?
>
> I just checked, and I have three different servers mentioned
> in my CVS/Root files; a cvs update is slow, but when I have
> just one server mentioned in the CVS/Root files, it is not faster.
>
> Also, specifying 'cvs -d mirror' explicitly should get rid of this
> problem then (right?), and speed things up, which it doesn't.
>
> Or is the slowdown possibly due to the sheer *number* of CVS/Root
> files that are consulted? Would that be remedied by cvs -d too?
I have no idea, I just observerd the slowdown multiple times.
-Otto
>
> Actually, cvs(1) says:
>
> -d CVS_root_directory
> Use CVS_root_directory as the root directory pathname of
> the master source repository. Overrides the setting of the
> CVSROOT environment variable. This value should be specified
> as an absolute pathname.
>
> CVS/Root
> Pathname to the repository ( CVSROOT ) location at the
> time of checkout. This file is used instead of the CVSROOT
> environment variable if the environment variable is not
> set. A warning message will be issued when the contents
> of this file and the CVSROOT environment variable differ.
> The file may be over- ridden by the presence of the
> CVS_IGNORE_REMOTE_ROOT environment variable.
>
> It doesn't state explicitly whether 'cvs -d'
> makes the CVS/Root files ignored. Does it?
>
> Also, the wording for 'CVS/Root' doesn't seem to be entirely correct:
> If I untar, say, sys.tar.gz, then my local tree contains no CVS/Root
> files, and if I later do a 'cvs -d mirror up -Pd', the tree gets
> populated with CVS/Root files (mentioning mirror) -- that's not
> a "time of checkout", that's an update. Also, having
> CVS_IGNORE_REMOTE_ROOT doesn't "override" CVS/Root,
> it just makes it ignored, right?
>
> > > Those different entries can be created when doing a cvs up -d that
> > > creates a new dir.
>
> Not only. A 'cvs -d mirror up -d' of a freshly untared sys.tar.gz creates
> CVS/Root files all over the place, *not* just in the new directories
> (that got created due to the 'up -d'). For example it creates
> ./sys/arch/i386/CVS/Root, while the directory /sys/arch/i386/
> definitely was there before (so it didn't get created with 'up -d').
>
> > If a cvs -d option is used at the same time, the
> > > CVS/Root entry for tht dir wil be different than the other's.
>
> Yes, but it will also change the content of CVS/Root
> in directories that existed before.
>
> > > The exact cause of the slowdown is not known to me. But when you are
> > > switch repositories once in a while it's easy to get this case.
> > >
> > > I repair this by find . -name Root | xargs rm and using a explicit cvs
> > > root.
>
> So, using an explicit cvs root does not ignore the CVS/Root files?
> Because if it does, then the 'find | xargs rm' should make no difference,
> right?
>
> > Now this is really another important issue of scattered
> > information, is it, and it's not noted in anoncvs.html!
> > I've slightly modified your command, i think my version is more
> > secure for use on a webpage.
> >
> > > -Otto
> >
> > --steffen
> >
> > Index: anoncvs.html
> > ===================================================================
> > RCS file: /cvs/www/anoncvs.html,v
> > retrieving revision 1.363
> > diff -a -p -u -r1.363 anoncvs.html
> > --- anoncvs.html 24 Jan 2012 09:57:35 -0000 1.363
> > +++ anoncvs.html 3 Feb 2012 13:33:28 -0000
> > @@ -542,6 +542,15 @@ add the <em>-d [email protected]
> > # <strong>cd /usr/src</strong>
> > # <strong>cvs -d [email protected]:/cvs -q up -Pd</strong>
> > </pre>
> > +
> > +<p> And because cvs(1) stores the name of the server which is in use once
> > +a directory gets created in the file CVS/Root inside this new directory,
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ^^^
>
> (not only)
>
> > +it maybe wise to issue a command sequence like the following:
> > +<pre>
> > + # <strong>cd /usr/src</strong>
> > + # <strong>find . -path '*CVS/Root' | xargs rm</strong>
> > + # <strong>cvs -d [email protected]:/cvs -q up -Pd</strong>
> > +</pre>
> > </ul>
> >
>
> I think this is blind typing without understanding what is going on
> (not that I know), contrary to the ways of our brilliant FAQ.
> Let's understand it first.
>
> Can someone with internal knowledge of cvs
> shed some light on this please?
>
> Thank you for your time
>
> Jan