[indiana-discuss] how to create a fully functional mirror of pkg.opensolaris.org
Shawn Walker
swalker at opensolaris.org
Fri Feb 6 14:08:58 PST 2009
vinz meier wrote:
> hello
> as I've been trying to get a working IPS mirror including the metadata for quite some time, I thought I would post it how to do it if someone needs to do this as well
>
> mkdir pkg
> cd pkg
> pkgrecv -s http://pkg.opensolaris.org -n > opensol.index
> for i in `cat opensol.index`; do pkgrecv -s http://pkg.opensolaris.org $i; done
>
> for i in `cat opensol.index`
> do
> pkg=`echo $i|awk -F/ '{print $2}' |awk -F@ '{print $1}'`
> echo import $pkg $i
> trans=`pkgsend -s http://localhost:10000 open $i`
> $trans
> pkgsend -s http://localhost:10000 include -d $pkg $pkg/manifest
> pkgsend -s http://localhost:10000 close
> done
>
>
> credits go to Karthik S S for the fetching part
It is preferred that you not do this for a number of reasons:
1) the existing package servers are not provisioned for mass retrievals
in this fashion
2) this process will *not* give you a true *mirror* of the contents of
pkg.opensolaris.org since re-publishing the packages to a local
repository will give them a new timestamp
3) it's a large waste of bandwidth as you'll be retrieving every version
of every package (for example, you'll be getting a copy of each package
for every build; .86, .89, .97, .100, .101, etc.).
3) the officially supported method for mirroring can be found here:
http://opensolaris.org/os/project/pkg/Mirroring/
If you still choose to do this, I would ask that you do so at 0200 your
time in consideration of others.
Thank you,
--
Shawn Walker
More information about the indiana-discuss
mailing list