Re: A couple of curly questions.

From: Ed Knowles <ed@dont-contact.us>
Date: Thu, 15 May 1997 22:27:43 -0500

G'day David!

> QUESTIONS:
> ---------
>
> 1) I want a couple of proxies to sit in front of a real proxy that caches
> the information. Like the following situation:
>
> Proxy/Cache
> / | \
> / | \
> / | \
> Proxy 1 Proxy 2 Proxy 3
>
> I do not want Proxy 1, Proxy 2 or Proxy 3 to store anything in their
> local cache. I want them to get all their information from the parent
> Proxy/Cache.
>
> Q: How would I implement this, should I just set the cache_swap to 0 or is
> there a tricky way of doing this? first_level_swap_dir 0,
> second_level_swap_dir 0???

As stated by dunc1@hotmail.com:

cache_host real.proxy.fqdn parent 3128 3130 proxy-only

> 2) Take the following scenario:
>
> Proxy 1 ---------------- Proxy 2
> / \
> / \
> / \
> Proxy A Proxy B
> |
> |
> Browser
>
> If the Browser requests a page, it asks Proxy A for the page, Proxy A
> does not have it. Proxy A then asks parent Proxy 1 for the page, Proxy 1
> does not have the page, so then asks it's sibling Proxy 2. Proxy 2 has
> the page.
>
> Q: What is stored in Proxy A's access.log??
>
> TCP_MISS:FIRST_PARENT_MISS??

Correct.

> I want to know whether the parent fetched it direct or from a sibling,
> is that possible??

Check Proxy 1's logs.

> 3) Take this scenario:
>
> Proxy_1 Proxy_2
> ----------- -------------
> | Page Z | | Page Y |
> | | | |
> ----------- -------------
> \ /
> \ /
> \ /
> ---- Proxy A -----
> |
> |
> Browser
>
> Proxy A has the following configuration:
>
> cache_host Proxy_1 parent 3128 3130
> cache_host Proxy_2 parent 3128 3130
>
> Proxy_1 and Proxy_2 are not siblings.
>
> Q: If the browser requests page Y, which is cached at Proxy_2, how does it
> get it??
> Does Proxy A first query Proxy_1 about the page, and a false value get
> returned. Then it queries Proxy_2 about the page, Proxy_2 has the page so
> returns a true value. The page then gets delivered to Proxy A then to
> Browser.
>
> OR -> Does Proxy A send off concurrent requests to both Proxy_1 and
> Proxy_2, then waits on a true signal from one, and if it gets a true value
> returned, it gets the page from that proxy.

This one.

> Another Q: What if Proxy A receives a false value from both Proxy_1 and
> Proxy_2?? Who retrieves it for Proxy A??

There is a pause of neighbor_timeout seconds to wait for all replies, the first
parent to reply if all replies have returned (the object is fetched when the
last reply arrives if under neighbour_timeout), the first parent to reply if
neighbour_timeout occurs, or DIRECT if no replies by neighbour_timeout seconds.

This assumes your not using mulitcasting :))

> 4) Final Question:
>
> Take this scenario:
>
> Proxy_1 ---------------------- Proxy_2
> ----------- -------------
> | Page Z | | Page Y |
> | | | |
> ----------- -------------
> \ /
> \ /
> \ /
> ---- Proxy A -----
> |
> |
> Browser
>
>
> This time Proxy_1 and Proxy_2 are siblings. Proxy A's configuration is
> the following:
>
> cache_host Proxy_1 parent 3128 3130
> cache_host Proxy_2 parent 3128 3130
>
> Q: If Proxy A requests page Y which is at Proxy_2, will Proxy A firstly
> query Proxy_1, who will then query it's sibling Proxy_2? Proxy_2 has the
> page, Proxy_2 will deliver it to Proxy_1, then to Proxy_1 will deliver it
> to Proxy_A...

Hmmm ... Proxy_2 replies with a HIT. Meanwhile, Proxy_1 is asking it's siblings
if they have the page, and then it will reply with a HIT. Depends on who
answers first as to who gets sent the request to deliver the page.

You may also wish to look at:

http://squid.nlanr.net/Squid/Devel/neighbor-selection-proposal.html

What are you trying to achieve?

Later
Ed

-- 
Ed Knowles aka Jasper                              Phone : +61 2 9385 4962
E-mail: ed@fatboy.geog.unsw.edu.au                 Fax   : +61 2 9313 7878
            What I lack in morals I make up for in principles.
Received on Thu May 15 1997 - 05:30:55 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:35:11 MST