freebsd-update "mirror" howto

Simon L. B. Nielsen simon at FreeBSD.org
Thu Sep 13 10:38:38 UTC 2012


On Wed, Sep 12, 2012 at 2:23 PM, Mathieu Arnold <mat at freebsd.org> wrote:
> +--On 12 septembre 2012 13:57:34 +0100 "Simon L. B. Nielsen"
> <simon at FreeBSD.org> wrote:
> | On Wed, Sep 12, 2012 at 12:42 PM, Mathieu Arnold <mat at freebsd.org> wrote:
> |
> |> It's not really a hubs thing, but anyway, I thought I'd share my few
> |> bits...
> |>
> |> For a long time, I pondered about upgrading my 300+ freebsd servers, and
> |> a few months back freebsd-update seemed like the way to go...
> |
> | Very interesting for information like this to be shared. Even better
> | if somebody could be tricked into putting it in the handbook :-).
>
> Hum, I see where you're going with that ;-)

:-)

> The thing is, I wanted a bit of feedback to see if I wasn't doing something
> stupid before committing myself into doing that.

Sure. I don't see any fundamental problem doing it that way, though I
recall reading in the past that you shouldn't use varnish as a forward
cache - but I never looked into why.

One thing which may or may not be a problem is support for HTTP
pipelining. At least using squid I found the lack of pipelining
support to really slow down freebsd-update (and portsnap). Can be that
varnish is enough faster than squid that this becomes less of an
issue.

> I have not written doc for a long time, I'll try to see if I can coerce
> myself into doing that next week while I'm vacationing in Corsica.

Great :-). I'm sure the freebsd-doc people would be happy to help with
extra markup etc.

> |> Now, I did not want all those servers to hit the main freebsd-update
> |> servers, so I setup a nice local "mirror" using varnish.
> |
> | Why did you decide to go with Varnish instead of a program designed as
> | a forward cache?
>
> Because Varnish is *cool*. :-p

OK :-).

> |> Varnish's configuration is there https://gist.github.com/2637602 and it
> |> would be even better if varnish could use SRV records to define it's
> |> backends by itself, but for now, there are a couple of shell that I have
> |> to run whenever I feel like it to update the list.
> |
> | Evil workaround thing would be to just parse the SRV records in a
> | script and then generate the varnish config wrt. backend based on
> | that... not pretty though :-).
>
> Well, that's almost already what's there, when I feel the need to update, I
> edit the file with vim, I remove the old lines, copy the shell line in the
> script, remove the # and type "V!bash" ;-)

Ah, right. I hadn't yet looked at the varnish config file.

-- 
Simon L. B. Nielsen


More information about the freebsd-hubs mailing list