Re: [users@httpd] Vhosts behind NAT
On Fri, Jan 24, 2014 at 11:07:35AM +0400, mn wrote: > Does it possible to configure the apache so it distinguishes name > abc.* and cde.* (used by clients externally) and returns different > pages (provided two s are configured)? > Which Directives are imlpemented in the case? Or, maybe, the example > of such httpd.conf? Yes, it is possible. This is called "Name-based virtual hosting" and you can read all about it in the Apache documentation: http://httpd.apache.org/docs/2.4/vhosts/name-based.html Pete -- Openstrike - improving business through open source http://www.openstrike.co.uk/ or call 01722 770036 / 07092 020107 pgpIlgr4jfEaq.pgp Description: PGP signature
[users@httpd] cache_disk :
I am seeing the following logged in the apache error log (client IP removed): [cache_disk:warn] [pid 26540:tid 139906663675648] (28)No space left on device: [client xxx.xxx.xxx.xxx:56003] AH00725: could not create header file /usr/local/apache/cache/www_http/aptmpd5MAgM That disk volume (/usr/local/apache/cache) used for the cache is an 80Gb tmpfs disk. The server has 32Gb physical RAM, 100Gb SWAP space. This is running on a RHEL6 server. At the point of the errors only about a quarter of the cache volume was being used: ~20Gb content. The server was reporting 29% memory used, with the remainder all being used for caching/buffering, and 6.5% (6.5Gb) of the swap space being used. My expectation of this configuration was:Apache would be able to cache up to 80Gb of content. Tmpfs would prioritise the most used stuff to be in RAM, and the least used stuff would be swapped out to disk (swap space). Based on this, all my memory / disk usage would seem to be ok. Is there something I'm missing, any other limits imposed by Apache / OS that might be affecting this? Any advice / help would be greatly appreciated. Thanks,Paul
Re: [users@httpd] cache_disk :
On Jan 24, 2014, at 11:30 , Paul Beckett wrote: > I am seeing the following logged in the apache error log (client IP removed): > > [cache_disk:warn] [pid 26540:tid 139906663675648] (28)No space left on > device: [client xxx.xxx.xxx.xxx:56003] AH00725: could not create header file > /usr/local/apache/cache/www_http/aptmpd5MAgM > > That disk volume (/usr/local/apache/cache) used for the cache is an 80Gb > tmpfs disk. The server has 32Gb physical RAM, 100Gb SWAP space. This is > running on a RHEL6 server. > > At the point of the errors only about a quarter of the cache volume was being > used: ~20Gb content. The server was reporting 29% memory used, with the > remainder all being used for caching/buffering, and 6.5% (6.5Gb) of the swap > space being used. > > My expectation of this configuration was: > Apache would be able to cache up to 80Gb of content. Tmpfs would prioritise > the most used stuff to be in RAM, and the least used stuff would be swapped > out to disk (swap space). Based on this, all my memory / disk usage would > seem to be ok. > > Is there something I'm missing, any other limits imposed by Apache / OS that > might be affecting this? Any advice / help would be greatly appreciated. You may be running out of inodes. Check with df -i. https://www.kernel.org/doc/Documentation/filesystems/tmpfs.txt tmpfs has three mount options for sizing: size: The limit of allocated bytes for this tmpfs instance. The default is half of your physical RAM without swap. If you oversize your tmpfs instances the machine will deadlock since the OOM handler will not be able to free that memory. nr_blocks: The same as size, but in blocks of PAGE_CACHE_SIZE. nr_inodes: The maximum number of inodes for this instance. The default is half of the number of your physical RAM pages, or (on a machine with highmem) the number of lowmem RAM pages, whichever is the lower. rainer - To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org For additional commands, e-mail: users-h...@httpd.apache.org
RE: [users@httpd] cache_disk :
Rainer,Thanks for your reply. That's helped me a lot. > You may be running out of inodes. Check with df -i. You are right, I've run out of inodes:Filesystem InodesIUsed IFree IUse% Mounted ontmpfs4104915 4104908 7 100% /usr/local/apache/cache The default number of inodes would seem to be inadequate. Based on using 4 million inodes with 20% of the space, scaling this lineaerly would suggest I need to raise the inode limit to 20million:tmpfs/usr/local/apache/cache tmpfs size=80G,nr_inodes=2000,nr_inodesrw,noexec,nosuid,nodev,uid=1,gid=0,mode=700 0 0 Think I might just wipe the cache for now as this doesn't sound like a great change to implement on a Friday. Thanks,Paul
[users@httpd] unsubscribe
unsubscribe
[users@httpd] Conditional request not honored in Includes
I'm trying to dynamically concatenate a bunch of javascript files into a single file using the INCLUDE filter. The include.shtml.js test script is The virtual server config has both SSIETag and SSILastModified set to On for that file ServerName test.dkt ServerAlias test.com UseCanonicalName Off ErrorLog logs/test.dkt-error_log CustomLog logs/test.dkt-access_log combined LogLevel info FileEtag All AddType application/javascript .js DocumentRoot /var/www/html/test.com Options -Indexes ExpiresActive Off ExpiresDefault "access plus 1 years" Header append Cache-Control "public" Order deny,allow Allow from all SSIETag On SSILastModified On Options +Includes SetOutputFilter INCLUDE It correctly serves the concatenated scripts but is always a full 200 OK in instead of a 304 Not Modified. The Firebug log Response Headers HTTP/1.1 200 OK Date: Fri, 24 Jan 2014 16:57:12 GMT Server: Apache/2.2.15 (CentOS) Last-Modified: Fri, 24 Jan 2014 16:53:32 GMT Etag: "460bbc-5c-4f0ba32b7447d" Accept-Ranges: bytes Vary: Accept-Encoding Content-Encoding: gzip Cache-Control: public Content-Length: 40 Connection: close Content-Type: application/javascript Request Headers GET /static/include.shtml.js HTTP/1.1 Host: test.dkt User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:26.0) Gecko/20100101 Firefox/26.0 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accept-Language: pt-br,en-us;q=0.9,es;q=0.7,en;q=0.6,zh-tw;q=0.4,ar-sa;q=0.3,ar;q=0.1 Accept-Encoding: gzip, deflate DNT: 1 Connection: keep-alive If-Modified-Since: Fri, 24 Jan 2014 16:53:32 GMT If-None-Match: "460bbc-5c-4f0ba32b7447d" Cache-Control: max-age=0 Is there a hard coded restriction on conditional requests for the INCLUDE filter? I'm aware that I should "touch" the including script whenever there is a change in any of the included scripts. The Apache version is 2.2 running in Centos 6
[users@httpd] Re: WebDAV oddness
On 03 Jan 2014, at 14:34 , LuKreme wrote: > On my Apache 2.4.6 (under FreeBSD 8.0-RELEASE) I have two nearly identical > directives setup for webdav. The first is in users/example.com.conf and the > second is in extras/vhosts.conf: Still beating my head against this, nothing I do seems to be able to get webdav to work in apache 2.4. Does anyone have a working config in 2.4 they could post? I could at least plug that in and see if I get any errors. I am wondering if there is something in apache 2.4 that prevents webdav from working properly with a subdomain? -- Stone circles were common enough everywhere in the mountains. Druids built them as weather computers, and since it was always cheaper to build a new 33-Megalith circle than to upgrade an old slow one, there were generally plenty of ancient ones around --Lords and Ladies - To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org For additional commands, e-mail: users-h...@httpd.apache.org
Re: [users@httpd] Re: WebDAV oddness
On Fri, Jan 24, 2014 at 1:13 PM, LuKreme wrote: > > On 03 Jan 2014, at 14:34 , LuKreme wrote: > >> On my Apache 2.4.6 (under FreeBSD 8.0-RELEASE) I have two nearly identical >> directives setup for webdav. The first is in users/example.com.conf and the >> second is in extras/vhosts.conf: > > Still beating my head against this, nothing I do seems to be able to get > webdav to work in apache 2.4. Does anyone have a working config in 2.4 they > could post? I could at least plug that in and see if I get any errors. > > I am wondering if there is something in apache 2.4 that prevents webdav from > working properly with a subdomain? there is some mod_dir thing, can you check the patch in https://issues.apache.org/bugzilla/show_bug.cgi?id=53929 - To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org For additional commands, e-mail: users-h...@httpd.apache.org