nginx Digest, Vol 27, Issue 33
tavo astuet
xpoke07 at hotmail.com
Fri Jan 13 14:30:35 UTC 2012
alguien habla castellano??hello, which is the number of processes to host a site in nginx?You can have a server on site, which serves to re-send requests within the local network??
> From: nginx-request at nginx.org
> Subject: nginx Digest, Vol 27, Issue 33
> To: nginx at nginx.org
> Date: Fri, 13 Jan 2012 13:57:52 +0000
>
> Send nginx mailing list submissions to
> nginx at nginx.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
> http://mailman.nginx.org/mailman/listinfo/nginx
> or, via email, send a message with subject or body 'help' to
> nginx-request at nginx.org
>
> You can reach the person managing the list at
> nginx-owner at nginx.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of nginx digest..."
>
>
> Today's Topics:
>
> 1. Re: alias, regex and try_files am i doing it wrong, or is
> this a bug? (Maxim Dounin)
> 2. Re: mod_aclr2 (Martin Loy)
> 3. Re: [PATCH 2 of 2] add support for setting worker processes
> and CPU affinity automatically (Joshua Zhu)
> 4. Re: [PATCH 2 of 2] add support for setting worker processes
> and CPU affinity automatically (Maxim Konovalov)
> 5. Limit robots (double)
> 6. help with replacing chars "_" to "." in a $variable (andres-m77)
> 7. Re: Limit robots (Ant?nio P. P. Almeida)
> 8. Re: Programmatic access to Nginx fcgi/proxy cache? (Martin Loy)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Fri, 13 Jan 2012 16:52:18 +0400
> From: Maxim Dounin <mdounin at mdounin.ru>
> To: nginx at nginx.org
> Subject: Re: alias, regex and try_files am i doing it wrong, or is
> this a bug?
> Message-ID: <20120113125218.GC67687 at mdounin.ru>
> Content-Type: text/plain; charset=us-ascii
>
> Hello!
>
> On Thu, Jan 12, 2012 at 11:36:41PM -0500, takigama wrote:
>
> > Ok, i was trying to do drupal as a subdirectory on my site, but i've hit
> > a problem and I think its a bug. Im using 10.04 ubuntu, the nginx ppa
> > with 1.0.11 nginx.
> >
> > If i have the following config's and i try to retrieve the file
> > http://mysite/drupal/somefile:
> >
> > location ~ /drupal(.*) {
> > index index.php;
> > alias /local_config/$1;
> > try_files $uri @drupalrewrite;
> > }
> >
> > The file nginx is apparently trying retrieve
> > "/local_config//somefile/drupal/somefile" rather then
> > "/local_config//somefile", which leads me to believe $uri isnt being set
> > correctly by nginx.
>
> Yes, this looks like a bug for me.
>
> (Internally, the problem is a bit complex, and I event tend to
> think that behaviour of try_files with alias in a regexp location
> is inherently undefined, but the example above should certainly
> work as expected.)
>
> > If instead, i have this as a config:
> >
> > location /drupal/ {
> > index index.php;
> > alias /local_config/;
> > try_files $uri @drupalrewrite;
> > }
> >
> > it does the right thing, and try files will attempt to get
> > "/local_config/somefile", so im really confused as to why it happens.
>
> This works as expected.
>
> The difference is that in a regexp location the "alias" directive
> specifies full path to a file to use, and try_files isn't
> currently able to handle this.
>
> Maxim Dounin
>
>
>
> ------------------------------
>
> Message: 2
> Date: Fri, 13 Jan 2012 10:55:00 -0200
> From: Martin Loy <martinloy.uy at gmail.com>
> To: nginx at nginx.org
> Subject: Re: mod_aclr2
> Message-ID:
> <CAHbGeW7vqP1_yK-y6CqKJzcE94BUhS8mORr1kgoyj2peESZrUQ at mail.gmail.com>
> Content-Type: text/plain; charset="utf-8"
>
> Andrey
>
> thanks for your response and great nice work!!
>
> Regards
>
> M
>
> On Wed, Jan 11, 2012 at 4:09 PM, Andrey Belov <defan at nginx.com> wrote:
>
> > Martin,
> >
> > On Jan 11, 2012, at 7:31 PM, Martin Loy wrote:
> >
> > Would you explain the main difference between using your module and using
> > nginx as a reverse proxy and caching static content ?
> >
> >
> > In some situations, mod_aclr2 helps to avoid excessive disk I/O,
> > especially for big static responses.
> >
> > When nginx is used as a local reverse proxy and proxy_buffering is
> > enabled, every upstream reponse which can not fit into proxy buffers
> > may be temporarily saved on disk:
> >
> > http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_buffering
> > http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_temp_path
> >
> > For example, we have to process the request for 700mb video file,
> > without mod_aclr2:
> >
> > 1) nginx sends the request to apache
> > 2) apache sends 700mb file back to nginx
> > 3) nginx saves received file on disk (proxy_temp_path) and
> > starts sending it back to the client
> >
> > and with mod_aclr2:
> >
> > 1) nginx sends the request to apache
> > 2) apache sends a few bytes header with X-Accel-Redirect back to nginx
> > 3) nginx starts sending the file directly from disk
> >
> > You save your time and your disk at step #2.
> >
> > Of course, you also may use proxy_cache along with mod_aclr2,
> > but if your disks are fast enough, probably you won't need
> > to do any caching at all.
> >
> > Hope this helps.
> >
> >
> >
> > Regards
> >
> > M
> >
> > On Wed, Jan 11, 2012 at 11:54 AM, Ant?nio P. P. Almeida <appa at perusio.net>wrote:
> >
> >> On 11 Jan 2012 13h17 WET, defan at nginx.com wrote:
> >>
> >> > Hello!
> >> >
> >> > Ever wondered how to set up NGINX as a local proxy for Apache 2.x
> >> > with minimum efforts?
> >>
> >> Nice work Andrey. Opens up Nginx as a possibility for shared hosting
> >> (keep using .htaccess) and voids any resistance people might have trying
> >> Nginx out. It's sooo easy now :)
> >>
> >> Thanks,
> >> --- appa
> >>
> >> _______________________________________________
> >> nginx mailing list
> >> nginx at nginx.org
> >> http://mailman.nginx.org/mailman/listinfo/nginx
> >>
> >
> >
> >
> > --
> > *Nunca hubo un amigo que hiciese un favor a un enano, ni un enemigo que
> > le hiciese un mal, que no se viese recompensado por entero.*
> > _______________________________________________
> > nginx mailing list
> > nginx at nginx.org
> > http://mailman.nginx.org/mailman/listinfo/nginx
> >
> >
> >
> > _______________________________________________
> > nginx mailing list
> > nginx at nginx.org
> > http://mailman.nginx.org/mailman/listinfo/nginx
> >
>
>
>
> --
> *Nunca hubo un amigo que hiciese un favor a un enano, ni un enemigo que le
> hiciese un mal, que no se viese recompensado por entero.*
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20120113/615c8118/attachment-0001.html>
>
> ------------------------------
>
> Message: 3
> Date: Fri, 13 Jan 2012 21:08:25 +0800
> From: Joshua Zhu <zhuzhaoyuan at gmail.com>
> To: nginx at nginx.org
> Subject: Re: [PATCH 2 of 2] add support for setting worker processes
> and CPU affinity automatically
> Message-ID:
> <CAOKiq2ADiejbL4SF7DDTqrMHntpf0tD2R1A_-fxJWNQs0O+j_g at mail.gmail.com>
> Content-Type: text/plain; charset="iso-8859-1"
>
> Hi,
>
> On Fri, Jan 13, 2012 at 6:33 PM, Valentin V. Bartenev <ne at vbart.ru> wrote:
>
> > On Friday 13 January 2012 14:04:11 Joshua Zhu wrote:
> >
>
> [snip]
>
>
> > So, when you need some automation for configuration and deployment, the
> > better
> > solution would be using proper software for that task, isn't it? Like
> > Puppet,
> > for example.
> >
> >
> OK.
> If this patch would not be accepted, could you please also review the first
> one?
> Thank you.
>
> Regards,
>
> --
> Joshua Zhu
> Senior Software Engineer
> Server Platforms Team at Taobao
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20120113/f130682d/attachment-0001.html>
>
> ------------------------------
>
> Message: 4
> Date: Fri, 13 Jan 2012 17:18:51 +0400
> From: Maxim Konovalov <maxim at nginx.com>
> To: nginx at nginx.org
> Subject: Re: [PATCH 2 of 2] add support for setting worker processes
> and CPU affinity automatically
> Message-ID: <4F102F3B.5050506 at nginx.com>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> On 1/13/12 2:27 PM, Piotr Sikora wrote:
> > Hi,
> >
> >>> Setting CPU affinity is available on Linux systems only. Please
> >>> correct me if I'm wrong.
> >>
> >> That's wrong.
> >
> > I believe that Joshua meant that workers CPU affinity _in nginx_
> > works only on Linux right now (which is true).
> >
> Ah, I see, thanks.
>
> I just wonder how useful this option in real environment.
>
> --
> Maxim Konovalov
> +7 (910) 4293178
> http://nginx.com/
>
>
>
> ------------------------------
>
> Message: 5
> Date: Fri, 13 Jan 2012 08:36:20 -0500
> From: "double" <nginx-forum at nginx.us>
> To: nginx at nginx.org
> Subject: Limit robots
> Message-ID:
> <6300b8a589bb337813f7df86d393d332.NginxMailingListEnglish at forum.nginx.org>
>
> Content-Type: text/plain; charset=UTF-8
>
> Hello,
>
> Is there a chance to limit robots to 1 request per second?
> The down below does not work: [emerg] "limit_req" directive is not
> allowed here
>
> Thanks a lot
> Markus
>
>
> http {
> limit_req_zone $http_user_agent zone=useragenttrack:1m
> rate=1r/s;
> server {
> listen 80;
> location / {
> if ($http_user_agent ~* "[a-z]bot[^a-z]") {
> limit_req zone=useragenttrack burst=100 nodelay;
> }
> }
> }
> }
>
> Posted at Nginx Forum: http://forum.nginx.org/read.php?2,221162,221162#msg-221162
>
>
>
> ------------------------------
>
> Message: 6
> Date: Fri, 13 Jan 2012 08:44:13 -0500
> From: "andres-m77" <nginx-forum at nginx.us>
> To: nginx at nginx.org
> Subject: help with replacing chars "_" to "." in a $variable
> Message-ID:
> <7770f2f8745407086920bd36c17248d1.NginxMailingListEnglish at forum.nginx.org>
>
> Content-Type: text/plain; charset=UTF-8
>
> I would appreciate your help
>
> I have to do the following request
>
> http://subdomain_domain_extension_tdl.domain.com/
>
> Where .domain.com must be deleted and subdomain_domain_extension_tdl
> must be converted to subdomain.domain.extension.tdl
>
>
> I did this:
>
> set $subdomain "";
>
> if ($host ~* "^(.+)\.domain\.com$") {
> set $subdomain $1;
> break;
> }
>
> resolver 8.8.8.8;
> proxy_pass http://$subdomain;
> proxy_set_header X-Real-IP $remote_addr;
>
>
> Then i get $subdomain as: subdomain_domain_extension_tdl but i need to
> transform it into subdomain.domain.extension.tdl
>
> Could you please help me determining how could i do this? i would like
> to serve as proxy in this way:
>
>
> If you want to get inside any blocked website like www.facebook.com be
> able to do it throug www_facebook_com.domain.com
>
> Also i know that perhaps sometimes subdomain_domain_extension_tdl could
> be domain_extension_tdl,
>
>
> Thanks in advance!
> Andr?s
>
> Posted at Nginx Forum: http://forum.nginx.org/read.php?2,221176,221176#msg-221176
>
>
>
> ------------------------------
>
> Message: 7
> Date: Fri, 13 Jan 2012 13:50:48 +0000
> From: Ant?nio P. P. Almeida <appa at perusio.net>
> To: nginx at nginx.org
> Subject: Re: Limit robots
> Message-ID: <874nvzyamf.wl%appa at perusio.net>
> Content-Type: text/plain; charset=US-ASCII
>
> On 13 Jan 2012 13h36 WET, nginx-forum at nginx.us wrote:
>
> > Hello,
> >
> > Is there a chance to limit robots to 1 request per second?
> > The down below does not work: [emerg] "limit_req" directive is not
> > allowed here
>
> Yes. Try:
>
> At the *http* level:
>
> limit_req_zone $http_user_agent zone=useragenttrack:1m rate=1r/s;
>
> map $http_user_agent $is_bot {
> default 0;
> ~[a-z]bot[^a-z] 1;
> }
>
> At the server level:
>
> location / {
> error_page 418 @bots;
>
> if ($is_bot) {
> return 418;
> }
> ...
> }
>
> location @bots {
> limit_req zone=useragenttrack burst=100 nodelay;
> ...
> }
>
> Cf: http://wiki.nginx.org/HttpLimitReqModule
>
> --- appa
>
>
>
> ------------------------------
>
> Message: 8
> Date: Fri, 13 Jan 2012 11:57:30 -0200
> From: Martin Loy <martinloy.uy at gmail.com>
> To: nginx at nginx.org
> Subject: Re: Programmatic access to Nginx fcgi/proxy cache?
> Message-ID:
> <CAHbGeW6f0xq6AyeZxGjcRb=p-5aMWdFP5Y7sBVUTSdQ3M5EZ3A at mail.gmail.com>
> Content-Type: text/plain; charset="utf-8"
>
> Ben
>
> Why not use memcached/redis/etc as cache backend instead of file based
> cache, nginx works with them great and you just need to populate the cache
> at application level :)
>
> http://wiki.nginx.org/HttpMemcachedModule
> http://wiki.nginx.org/HttpRedis
>
> Regards
>
> M
>
>
> On Thu, Jan 12, 2012 at 4:56 PM, Piotr Sikora <piotr.sikora at frickle.com>wrote:
>
> > Hi,
> >
> >
> > There's also a 3rd party module for cache purging. AFAIK doesn't
> >> support wildcards:
> >>
> >> https://github.com/FRiCKLE/**ngx_cache_purge<https://github.com/FRiCKLE/ngx_cache_purge>
> >>
> >
> > It doesn't, but because of that it's the only one of those mentioned that
> > works at scale.
> >
> > Best regards,
> > Piotr Sikora < piotr.sikora at frickle.com >
> >
> >
> > ______________________________**_________________
> > nginx mailing list
> > nginx at nginx.org
> > http://mailman.nginx.org/**mailman/listinfo/nginx<http://mailman.nginx.org/mailman/listinfo/nginx>
> >
>
>
>
> --
> *Nunca hubo un amigo que hiciese un favor a un enano, ni un enemigo que le
> hiciese un mal, que no se viese recompensado por entero.*
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20120113/8eaa408c/attachment.html>
>
> ------------------------------
>
> _______________________________________________
> nginx mailing list
> nginx at nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx
>
> End of nginx Digest, Vol 27, Issue 33
> *************************************
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20120113/550168dc/attachment-0001.html>
More information about the nginx
mailing list