Apache Directory Project - Use of Proxy on directory.apache.org

This is Interesting: Free IT Magazines  
Home > Archive > Apache Directory Project > March 2007 > Use of Proxy on directory.apache.org





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Use of Proxy on directory.apache.org
Paul Querna

2007-02-27, 1:11 am

Hello dev@directory;

Us over in infrastructure noticed something different about
http://directory.apache.org/ this morning. Well, first thing was, that
it was down. (And people noticed, and told us!)

But when we looked into it, we thought it was pretty odd, since eos (the
T2000 that all of the main websites are currently hosted on) was doing
fine, and all the other TLP sites seemed up.

What we found was a cute series of RewriteRules in the main
directory.apache.org .htaccess file:
$ cat /x1/www/directory.apache.org/.htaccess
.....
RewriteRule ^(.*)$ http://cwiki.apache.org/DIRxSITE/$1 [P,L]


So, most of the content on directory.apache.org is being proxied to
cwiki.apache.org aka brutus.apache.org.

From an infrastructure perspective, this creates an unacceptable
dependency between services. brutus.apache.org (and CWiki) will go
down. They just aren't setup to be redundant right now.

In comparison, the (static) content under /x1/www is mirrored to
multiple machines in multiple data centers, and in the case of a failure
we can quickly (and relatively painlessly) switch it to another machine.

The preferred method is to export the static files from brutus, onto
people.apache.org, into your /x1/www/directory.apache.org/ directory.
Many other TLPs do this via a crontab on people.apache.org. If you need
help setting this up, we would be happy to help get you started.

Thanks,

-Paul

Trustin Lee

2007-03-15, 7:11 am

Hi infra team,

Sorry for late response. I must confess that this issue also affects
mina.apache.org, and it was me who started to use RewriteRule.

On 2/27/07, Paul Querna <pquerna-1oDqGaOF3Lkdnm+yROfE0A@public.gmane.org> wrote:
> Ersin Er wrote:
>
> Doesn't matter to me...
>
> The content from brutus is already copied over by jefft to this location
> on people.apache.org:
> /x1/home/jefft/public_html/confluence
>
> All you need to do is on people.apache.org, add a crontab to copy the
> content you want from /x1/home/jefft/public_html/confluence to
> /x1/www/directory.apache.org/


If it's already being rsync'd to people.apache.org, we could modify
our rewrite rule like the following instead of using a crontab:

RewriteRule ^(.*) http://people.apache.org/~jefft/confluence/MINA/$1 [P]

WDYT?

Anyways, how often is Jeff's directory being rsync'd?

Trustin
--
what we call human nature is actually human habit
--
http://gleamynode.net/
--
PGP Key ID: 0x0255ECA6

Joshua Slive

2007-03-15, 1:11 pm

[Fixing reply-to.]

On 3/15/07, Trustin Lee <trustin-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:

> If it's already being rsync'd to people.apache.org, we could modify
> our rewrite rule like the following instead of using a crontab:
>
> RewriteRule ^(.*) http://people.apache.org/~jefft/confluence/MINA/$1 [P]
>
> WDYT?


No.

That doesn't help at all, in fact, since www.apache.org and
people.apache.org are not served from the same machine.

Simply take the content that jefft has rsynced, and use a cron job to
put it in your directory under minotaur:/www/

Alex Karasulu

2007-03-15, 1:11 pm

On 3/15/07, Upayavira <uv-Dt0fvG0bBmj10XsdtD+oqA@public.gmane.org> wrote:
>
> Joshua Slive wrote:
>
> The big deal is that to set up an rsync you need to do that in a user's
> crontab. That ties control of the process down to a single user, which
> is far from preferable.



Yes I would have to agree with Upayavira here. It's not a good idea to
depend on a single user account for this. Plus that person must be hunted
down and contacted any time there needs to be some modification done.


The fact that we now have /x1/www/confluence-exports sorts half of the
> picture. If symlinks work, that sorts the other half.
>
> Reasonable?



+1

Alex

Ersin Er

2007-03-15, 7:11 pm

Hi all,

Well, a few infra folks and I tried to set this up as suggested during
an IRC session but we did not succeed. BTW they helped me to write a
cron job to sync all of our spaces from cwiki to d.a.o/cwiki (you
cannot see this via your browser). We currently have all the content
under Directory site but we need some local rewrite rules to make them
match our current name space. We have made some progress but as the
Directory project uses many wiki spaces bound to different name spaces
(under d.a.o) we had trouble with configuring the ReWrite plugin. A
suggestion was to us the Alias plugin (for httpd) but infra folks
realized that it was not allowed to use it in .htaccess files. So we
suspended the migration. I hope we can do one more attempt soon to fix
the problem. BTW, I think it's quite easy for MINA to migrate to that
suggested model.

Cheers,

On 3/15/07, Alex Karasulu <akarasulu-1oDqGaOF3Lkdnm+yROfE0A@public.gmane.org> wrote:
>
>
>
> On 3/15/07, Upayavira <uv-Dt0fvG0bBmj10XsdtD+oqA@public.gmane.org> wrote:
>
>
> Yes I would have to agree with Upayavira here. It's not a good idea to
> depend on a single user account for this. Plus that person must be hunted
> down and contacted any time there needs to be some modification done.
>
>
>
>
> +1
>
> Alex
>
>
>



--
Ersin

Emmanuel Lecharny

2007-03-15, 7:11 pm

Thanks a lot Ersin for those explanations. I hope that soon we will find a
better solution. Sorry if I can't help, but I think it's better that the
started effort be continued by people who know what it's all about !

Emmanuel

On 3/15/07, Ersin Er <ersin.er-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
>
> Hi all,
>
> Well, a few infra folks and I tried to set this up as suggested during
> an IRC session but we did not succeed. BTW they helped me to write a
> cron job to sync all of our spaces from cwiki to d.a.o/cwiki (you
> cannot see this via your browser). We currently have all the content
> under Directory site but we need some local rewrite rules to make them
> match our current name space. We have made some progress but as the
> Directory project uses many wiki spaces bound to different name spaces
> (under d.a.o) we had trouble with configuring the ReWrite plugin. A
> suggestion was to us the Alias plugin (for httpd) but infra folks
> realized that it was not allowed to use it in .htaccess files. So we
> suspended the migration. I hope we can do one more attempt soon to fix
> the problem. BTW, I think it's quite easy for MINA to migrate to that
> suggested model.
>
> Cheers,
>
> On 3/15/07, Alex Karasulu <akarasulu-1oDqGaOF3Lkdnm+yROfE0A@public.gmane.org> wrote:
> actually
> to
> user's
> hunted
>
>
> --
> Ersin
>




--
Cordialement,
Emmanuel Lécharny
www.iktek.com

Joshua Slive

2007-03-15, 7:11 pm

On 3/15/07, Ersin Er <ersin.er-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> Hi all,
>
> Well, a few infra folks and I tried to set this up as suggested during
> an IRC session but we did not succeed. BTW they helped me to write a
> cron job to sync all of our spaces from cwiki to d.a.o/cwiki (you
> cannot see this via your browser). We currently have all the content
> under Directory site but we need some local rewrite rules to make them
> match our current name space. We have made some progress but as the
> Directory project uses many wiki spaces bound to different name spaces
> (under d.a.o) we had trouble with configuring the ReWrite plugin. A
> suggestion was to us the Alias plugin (for httpd) but infra folks
> realized that it was not allowed to use it in .htaccess files. So we
> suspended the migration. I hope we can do one more attempt soon to fix
> the problem. BTW, I think it's quite easy for MINA to migrate to that
> suggested model.


Anything that can be done with an Alias can also be done with a
RewriteRule. From peeking into your .htaccess, you can, for example,
replace
Alias /apacheds/1.0 /x1/www/directory.apache.org/cwiki/DIRxSRVx10
with
RewriteRule ^apacheds/1\.0(.*) /x1/www/directory.apache.org/cwiki/DIRxSRVx10$1

But that looks like an over-complex nightmare to me. Why don't you
just change the directory names when you do the rsync copy. In other
words, rsync DIRxSRVx10 directly into
/www/directory.apache.org/apacheds/1.0/.

Joshua.

Joshua Slive

2007-03-15, 7:11 pm

On 3/15/07, Ersin Er <ersin.er-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> On 3/15/07, Joshua Slive <joshua-AVhz+iU2c88@public.gmane.org> wrote:


>
> The solution is not that simple. (Or I was not able to solve as a more
> possible option.) To be able to do that we need to change our name
> space organization. If we directly rsync to final destinations we'll
> loose control of manually added content (like d.a.o/staticresources or
> d.a.o/ldapstudio/update).


This is easy enough to solve by either omitting the --delete option of
rsync (which will cause it to leave existing content untouched) and
then manually cleaning old stuff occasionally, or using the --exclude
option of rsync to exclude those directories.

Joshua.

Ersin Er

2007-03-15, 7:11 pm

On 3/15/07, Joshua Slive <joshua-AVhz+iU2c88@public.gmane.org> wrote:
> On 3/15/07, Ersin Er <ersin.er-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
>
>
> This is easy enough to solve by either omitting the --delete option of
> rsync (which will cause it to leave existing content untouched) and
> then manually cleaning old stuff occasionally, or using the --exclude
> option of rsync to exclude those directories.
>
> Joshua.
>


OK, we'll give it a try. Thanks for the suggestion.

--
Ersin

Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com