Is there a method to host a pkg-mirror for my internal usage?

建博廖 jbliao at cs.nctu.edu.tw
Sat Jul 13 15:03:46 UTC 2019


Hi,

I was finding a method to host a pkg mirror, so that it can provide a repo
to my FreeBSD servers through LAN.
I found a page that told me to use pkg-fetch to do such things
https://www.freebsd.org/doc/zh_TW.UTF-8/articles/hubs/mirror-howto.html

I have used 'pkg fetch -o /path/to/repo -r FreeBSD -y -a' to create my
repo, and that just succeed.
But when I want to update the repo, use the same command, daily. I got the
messages that says the package's checksum was mismatch. The previously
fetched package had been deleted and the process was exited. I tried to
update the repo again and succeed, but failed at another checksum mismatch.

That means I need to update 30k packages one by one which is such a stupid
thing, or recreate the repo at another empty directory and fetch almost
90GB packages everyday which waste time and network bandwidth.

There are someone having the same problem:
https://forums.freebsd.org/threads/problems-with-pkg-fetch-a-to-create-local-mirror.70959/


I wonder to know if there is a better way to host a pkg-mirror, or I could
only use http proxy to do that.

Sorry for my poor English :P

Regards,
Jian-Bo Liao
Teaching Assistant
Computer Center, Department of Computer Science,
National Chiao Tung University, Taiwan.
1001 University Road, Hsinchu, Taiwan 300, ROC.


More information about the freebsd-pkg mailing list