Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 29 Aug 2010 15:07:44 +0200
From:      Polytropon <freebsd@edvax.de>
To:        perryh@pluto.rain.com
Cc:        freebsd-questions@freebsd.org
Subject:   Re: ports database
Message-ID:  <20100829150744.1a29c3d8.freebsd@edvax.de>
In-Reply-To: <4c7994cd.zZBjSuPFSUYKdCmf%perryh@pluto.rain.com>
References:  <874453.45134.qm@web52302.mail.re2.yahoo.com> <20100826215346.7aaba141.freebsd@edvax.de> <20100828170745.GA88025@guilt.hydra> <20100828203618.45fd6be8.freebsd@edvax.de> <4c7994cd.zZBjSuPFSUYKdCmf%perryh@pluto.rain.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 28 Aug 2010 15:59:25 -0700, perryh@pluto.rain.com wrote:
> Polytropon <freebsd@edvax.de> wrote:
> 
> > >     tar -cf ports.tar /usr/port
> >
> > It should be, better suited:
> >
> > 	# cd /usr
> > 	# tar cf ports.tar ports
> >
> > So one could do "tar xf ports.tar" in the target machine's /usr
> > ...
> 
> Better put the created tarfile somewhere other than in the directory
> that is being tarred :)

In thic case, the tarfile is created outside ports/, so it's not
within the directory it is created in. But of course it's right:
the resulting archive can be better picked up from a directory
like /tmp, it should just have enough space available (allthough
a compressed ports tree should be less than 500 MB).



> and it might as well be compressed, something like:
> 
> # cd /usr
> # tar cf - ports | gzip > /var/tmp/ports.tgz

That is possible - if space is an issue (and not time); it is
also possible to do like this:

	# cd /usr
	# tar cjf /tmp/ports.tar.bz2 ports

I think it will even be better compression ratio using the BZip2
algorithm (tar option j instead of z).


One thing worth mentioning: The ports tree should be "clean" before
transfering (which is not a problem if it has just been fetched).
If you have already worked with it, make sure to have been running

	# make clean

in the ports main directory, or simply delete all work/ subdirs
that might contain tons of files not needed. The directories
ports/distfiles/ and ports/packages should also be checked. As
they contain compressed stuff, compressing them won't be much
helpful.



-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20100829150744.1a29c3d8.freebsd>