# A trick to using cvsup?



## mcgee (Sep 17, 2011)

I have a 8.2R amd64 box I want to use to track -STABLE, having never done this before I'm pretty dumb about it. Starting with a basic -RELEASE install with "All" distributions, I installed the cvsup-without-gui port, made a copy of /usr/share/examples/cvsup/stable-supfile and customized the "*default host" bit, then invoked it thus:
[CMD="cvsup"]-g -L 2 stable-supfile[/CMD]
But it doesn't actually *do* anything. What I get (after waiting for several minutes) is:

```
[test64/root]# cvsup  -g -L 2 stable-supfile
Parsing supfile "stable-supfile"
Connecting to cvsup.us.FreeBSD.org
Connected to cvsup.us.FreeBSD.org
Server software version: SNAP_16_1h
Negotiating file attribute support
Exchanging collection information
Establishing multiplexed-mode data connection
Running
Detailer failed: Network write failure: Connection closed
Will retry at 20:27:07
```
Not just once, I've tried several different cvsup servers and this is always what happens (with the ones that don't immediately kick me off with "access limit exceeded" anyway).

My test box is behind a firewall and NATted as well, preventing any incoming connections, but I'm given to understand that cvsup's "multiplexed" mode should still work (I've verified that I can telnet to port 5999 on the server, no problems there).

What sort of horribly obvious things am I missing here?


----------



## wblock@ (Sep 17, 2011)

You're following old instructions.  csup(1) is a replacement for cvsup, and already in the base system.  Upgrading FreeBSD To -STABLE covers some of the details in an abbreviated way.


----------



## mcgee (Sep 17, 2011)

Mmmkay, awesome part 1 is that the existing (presumably) up-to-date handbook info is "old". That's nice. Where do I go for valid, current documentation about FreeBSD if not freebsd.org?

Awesome part 2 is that using csup(1) produces exactly the same errors and lack of useful progress.


----------



## drhowarddrfine (Sep 17, 2011)

Because cvsup still works just fine, it's just that csup is better and faster. For csup, the handbook is current and 1) explains the difference and 2) shows how to do it.


----------



## wblock@ (Sep 17, 2011)

mcgee said:
			
		

> Mmmkay, awesome part 1 is that the existing (presumably) up-to-date handbook info is "old". That's nice. Where do I go for valid, current documentation about FreeBSD if not freebsd.org?



The Handbook should be up to date.  Please post a link to the part you're seeing.



> Awesome part 2 is that using csup(1) produces exactly the same errors and lack of useful progress.



Try a primary mirror rather than the central server.


----------



## mcgee (Sep 17, 2011)

wblock said:
			
		

> The Handbook should be up to date.  Please post a link to the part you're seeing.



http://www.freebsd.org/doc/handbook/cvsup.html, and looking at it this morning, I see the little inset where csup is mentioned. I missed that yesterday.



> Try a primary mirror rather than the central server.



As I said, I tried several different cvsup servers, the main one being the last. Just now I tried again with cvsup[9,10,13].us.freebsd.org, none worked (same pattern: connect, long delay while nothing happens, then a closed connection and retry in 5min). Then, randomly, I tried cvsup5,us, and that one is working, for now. I was using the fastest_cvsup port to select servers, maybe the trick is to pick one that isn't in the top three.


```
*default host=cvsup5.us.FreeBSD.org
*default base=/var/db
*default prefix=/usr
*default release=cvs tag=RELENG_8
*default delete use-rel-suffix
*default compress
src-all
```

So, c[v]sup's lack of diagnostic error messages. I can't tell why it doesn't work, so I don't know why it does work. Using it feels like gambling.


----------



## da1 (Sep 17, 2011)

Interesting. I never had problems with cvsup. If it helps in any way, here is my kernel-supfile:

```
*default base=/var/db
*default prefix=/usr
*default tag=RELENG_8_2
*default release=cvs delete use-rel-suffix compress
*default host=cvsup2.freebsd.org

src-all
```
.

As a side note, I for one, use svn to keep track of 8.2-STABLE. If you cannot get cvsup to work, you could have a look at it.


----------



## drhowarddrfine (Sep 17, 2011)

Install sysutils/fastest_cvsup to find the best server for you. I've never had problems with cvsup or csup either. We also use the 9 server.


----------



## wblock@ (Sep 17, 2011)

Any of the mirrors ought to work.  Since they all have similar problems, I'd suspect network/firewall/proxy problems.


----------



## linuxunix (Nov 11, 2011)

Well, I am also using cvsup10 and believe me..its too slow..and it has been 3 days since I am waiting for this to complete..still going on interrupting in between..seems like my network is too slow. Is there any other alternative (if I have already FreeBSD 8.2 CD, any tweak with offline?


----------



## SirDice (Nov 11, 2011)

linuxunix said:
			
		

> Well, I am also using cvsup10 and believe me..its too slow..and it has been 3 days since I am waiting for this to complete..


It shouldn't take that long. Even if you had to pull down the entire tree from scratch on a 64Kbit line using a very old computer.


----------



## linuxunix (Nov 12, 2011)

I can see that it's taking a long time retrieving everything from cvsup10.us.freebsd.org like src/, ports/ etc. Whenever I run the *cvsup* command it updates everytime from the branch it stopped.


----------



## kpa (Nov 12, 2011)

Please post your supfile, it sounds like you're fetching way too much stuff in one go.


----------



## linuxunix (Nov 13, 2011)

```
*default host=cvsup10.freebsd.org
*default base=/var/db
*default prefix=/usr/home/ncvs
*default release=cvs
*default delete use-rel-suffix

# If you seem to be limited by CPU rather than network or disk bandwidth, try
# commenting out the following line.  (Normally, today's CPUs are fast enough
# that you want to run compression.)
*default compress

## Ports Collection.
#
# The easiest way to get the ports tree is to use the "ports-all"
# mega-collection.  It includes all of the individual "ports-*"
# collections,
ports-all

# These are the individual collections that make up "ports-all".  If you
# use these, be sure to comment out "ports-all" above.
#
# Be sure to ALWAYS cvsup the ports-base collection if you use any of the
# other individual collections below. ports-base is a mandatory collection
# for the ports collection, and your ports may not build correctly if it
# is not kept up to date.
#ports-base
#ports-accessibility
#ports-arabic
#ports-archivers
#ports-astro
#ports-audio
#ports-benchmarks
#ports-biology
#ports-cad
#ports-chinese
#ports-comms
#ports-converters
#ports-databases
#ports-deskutils
#ports-devel
#ports-dns
#ports-editors
#ports-emulators
#ports-finance
#ports-french
#ports-ftp
#ports-games
#ports-german
#ports-graphics
#ports-hebrew
#ports-hungarian
#ports-irc
#ports-japanese
#ports-java
#ports-korean
#ports-lang
#ports-mail
#ports-math
#ports-mbone
#ports-misc
#ports-multimedia
#ports-net
#ports-net-im
#ports-net-mgmt
#ports-net-p2p
#ports-news
#ports-palm
#ports-polish
#ports-ports-mgmt
#ports-portuguese
#ports-print
#ports-russian
#ports-science
#ports-security
#ports-shells
#ports-sysutils
#ports-textproc
#ports-ukrainian
#ports-vietnamese
#ports-www
#ports-x11
#ports-x11-clocks
#ports-x11-drivers
#ports-x11-fm
#ports-x11-fonts
#ports-x11-servers
#ports-x11-themes
#ports-x11-toolkits
#ports-x11-wm
src-all
ports-all
doc-all
cvsroot-all
```


----------



## wblock@ (Nov 13, 2011)

linuxunix said:
			
		

> ```
> *default host=cvsup10.freebsd.org
> *default base=/var/db
> *default prefix=/usr/home/ncvs
> ...



With comments removed, it's easy to see two problems.  The less important one is that ports-all is entered twice.  The bigger problem is combining all of those into one supfile.  Don't mix them, use one supfile for ports, one for doc, one for src.  They are not identical.  ports has tag=., which most people should not use for src.

cvsroot-all is probably what is taking so long.  It's very unlikely you need that, it's certainly not needed for 8-STABLE.

For 8-STABLE, use this:

```
*default host=cvsup10.FreeBSD.org
*default base=/var/db
*default prefix=/usr
*default release=cvs tag=RELENG_8
*default delete use-rel-suffix
*default compress
src-all
```


----------

