Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Apache: Dev

httpd 2.4.1 and mod_slotmem_shm / mod_proxy_balancer (AH01179)

 

 

First page Previous page 1 2 Next page Last page  View All Apache dev RSS feed   Index | Next | Previous | View Threaded


tevans.uk at googlemail

Mar 7, 2012, 3:59 AM

Post #26 of 30 (459 views)
Permalink
Re: httpd 2.4.1 and mod_slotmem_shm / mod_proxy_balancer (AH01179) [In reply to]

2012/3/7 Igor Galić <i.galic [at] brainsware>:
> I knew this is going to be my favourite part of this discussion ;)
>
> So far, DefaultRuntimeDir sounds most reasonable (to me)
>

I'd like it green! But seriously, doesn't this directive change the
runtime directory from the default to something not the default? In
which case, a simple "RuntimeDir" may be better?

Cheers

Tom


jim at jaguNET

Mar 7, 2012, 4:05 AM

Post #27 of 30 (456 views)
Permalink
Re: httpd 2.4.1 and mod_slotmem_shm / mod_proxy_balancer (AH01179) [In reply to]

Yeah, it's pretty ez actually... ap_scratch_space (or whatever) which is
an extern. And then the changes from DEFAULT_REL_RUNTIMEDIR to
ap_scratch_space except for the initial setting of ap_scratch_space
to it. Some places will need a strcat instead of using cpp string
concat, but not too bad at all...

On Mar 7, 2012, at 6:54 AM, Jeff Trawick wrote:

> On Wed, Mar 7, 2012 at 6:37 AM, Jim Jagielski <jim [at] jagunet> wrote:
>> I'll work on it... I already have a version for slotmem, but
>> a generic solution it best, I agree. But what do we call it?
>> DefaultDir?
>
> As I mentioned yesterday, I have thrown together the code for the API
> and directive and need to test it.
>
>
>>
>> On Mar 7, 2012, at 5:17 AM, Igor Galić wrote:
>>
>>>
>>> [snip]
>>>> So to sum up: all uses of DEFAULT_REL_RUNTIMEDIR I can see at the
>>>> moment
>>>> are overwritable by configuration. A runtime configurable runtime
>>>> directory would not be a critical feature but make it easy to move
>>>> all
>>>> these objects in a common directory not known at build time.
>>> [snip]
>>>
>>> This is such a common use-case that it would make a lot of sense
>>> to provide such a directive.
>>>
>>> See next mail in this thread for a reference.
>>>
>>> i
>>>
>>> --
>>> Igor Galić
>>>
>>> Tel: +43 (0) 664 886 22 883
>>> Mail: i.galic [at] brainsware
>>> URL: http://brainsware.org/
>>> GPG: 6880 4155 74BD FD7C B515 2EA5 4B1D 9E08 A097 C9AE
>>>
>>
>
>
>
> --
> Born in Roswell... married an alien...
>


trawick at gmail

Mar 7, 2012, 4:07 AM

Post #28 of 30 (464 views)
Permalink
Re: httpd 2.4.1 and mod_slotmem_shm / mod_proxy_balancer (AH01179) [In reply to]

On Wed, Mar 7, 2012 at 6:59 AM, Tom Evans <tevans.uk [at] googlemail> wrote:
> 2012/3/7 Igor Galić <i.galic [at] brainsware>:
>> I knew this is going to be my favourite part of this discussion ;)
>>
>> So far, DefaultRuntimeDir sounds most reasonable (to me)

That's what I have (along with ap_runtime_dir_relative()).

>>
>
> I'd like it green! But seriously, doesn't this directive change the
> runtime directory from the default to something not the default? In
> which case, a simple "RuntimeDir" may be better?
>
> Cheers
>
> Tom



--
Born in Roswell... married an alien...


Zisis.Lianas at consol

Apr 18, 2012, 7:28 AM

Post #29 of 30 (401 views)
Permalink
Re: httpd 2.4.1 and mod_slotmem_shm / mod_proxy_balancer (AH01179) [In reply to]

Hi Jim (et all),

did you get any other feedback on the slotmem (directory) override?

Writing all the slotmem-shm files (for mod_proxy_balancer) in the
logs directory looks quite "unlovely", e.g. in my configuration with
two balancer and shared logs directory:

# ls -F1 logs/
error/
access/
slotmem-shm-s45fb3af_default.shm
slotmem-shm-s45fb3af_my_second_balancer.shm
slotmem-shm-s45fb3af.shm
slotmem-shm-s463b4ab_default.shm
slotmem-shm-s463b4ab_my_second_balancer.shm
slotmem-shm-s463b4ab.shm

It would be nice to have a customizable slotmem-prefix and/or target
directory for shm files. What do you think?



Best regards,
Zisis

----- Original Message -----
From: "Jim Jagielski" <jim [at] jaguNET>
To: dev [at] httpd
Sent: Tuesday, March 6, 2012 7:26:19 PM
Subject: Re: httpd 2.4.1 and mod_slotmem_shm / mod_proxy_balancer (AH01179)

My plan is 2 pronged... to see if r1297560 is enough and if
allowing a slotmem override is even needed (or wanted) ... ;)

On Mar 6, 2012, at 12:35 PM, Zisis Lianas wrote:

> Thanks Jim, that works fine for the default-rel-runtimedir configuration.
> Slotmem file is created as <serverroot>/logs/slotmem-shm-sxxxxxxxx.shm.
>
> Now if also the slotmem-file-target-location directive gets available,
> this thread is done for me.
>
>
> Regards,
> Zisis
>
> ----- Original Message -----
> From: "Jim Jagielski" <jim [at] jaguNET>
> To: dev [at] httpd
> Sent: Tuesday, March 6, 2012 5:21:22 PM
> Subject: Re: httpd 2.4.1 and mod_slotmem_shm / mod_proxy_balancer (AH01179)
>
> http://svn.apache.org/viewvc?rev=1297560&view=rev
>
> On Mar 6, 2012, at 10:39 AM, Jeff Trawick wrote:
>
>> On Tue, Mar 6, 2012 at 10:33 AM, Jim Jagielski <jim [at] jagunet> wrote:
>>> Yeah, that seems better, ala ./modules/cache/mod_socache_dbm.c
>>
>> On behalf of anyone else reading this thread, here's the idiom from
>> mod_socache_dbm.c:
>>
>> #define DEFAULT_DBM_PREFIX DEFAULT_REL_RUNTIMEDIR "/socache-dbm-"
>> ...
>> const char *path = apr_pstrcat(p, DEFAULT_DBM_PREFIX, namespace,
>> NULL);
>>
>> ctx->data_file = ap_server_root_relative(p, path);
>>
>>
>>>
>>> On Mar 6, 2012, at 8:36 AM, Jeff Trawick wrote:
>>>
>>>> On Tue, Mar 6, 2012 at 7:56 AM, Jim Jagielski <jim [at] jagunet> wrote:
>>>>> OK... What I'll do is add a directive which provides a
>>>>> "default" location for slotmem file...
>>>>
>>>> Uhh, that seems as endless as per-mutex directives.
>>>>
>>>> Is slotmem not using DEFAULT_REL_RUNTIMEDIR already? (not perfect,
>>>> but a good start)
>>>> Directive to specify runtime directory (API returns serverroot +
>>>> DEFAULT_REL_RUNTIMEDIR if not configured).
>>>> Directive like Mutex but for shmem?
>>>>
>>>
>>
>>
>>
>> --
>> Born in Roswell... married an alien...
>>
>


jim at jaguNET

Apr 18, 2012, 12:27 PM

Post #30 of 30 (404 views)
Permalink
Re: httpd 2.4.1 and mod_slotmem_shm / mod_proxy_balancer (AH01179) [In reply to]

Yeppers... see 2.4.2 :)

On Apr 18, 2012, at 10:28 AM, Zisis Lianas wrote:

> Hi Jim (et all),
>
> did you get any other feedback on the slotmem (directory) override?
>
> Writing all the slotmem-shm files (for mod_proxy_balancer) in the
> logs directory looks quite "unlovely", e.g. in my configuration with
> two balancer and shared logs directory:
>
> # ls -F1 logs/
> error/
> access/
> slotmem-shm-s45fb3af_default.shm
> slotmem-shm-s45fb3af_my_second_balancer.shm
> slotmem-shm-s45fb3af.shm
> slotmem-shm-s463b4ab_default.shm
> slotmem-shm-s463b4ab_my_second_balancer.shm
> slotmem-shm-s463b4ab.shm
>
> It would be nice to have a customizable slotmem-prefix and/or target
> directory for shm files. What do you think?
>
>
>
> Best regards,
> Zisis
>
> ----- Original Message -----
> From: "Jim Jagielski" <jim [at] jaguNET>
> To: dev [at] httpd
> Sent: Tuesday, March 6, 2012 7:26:19 PM
> Subject: Re: httpd 2.4.1 and mod_slotmem_shm / mod_proxy_balancer (AH01179)
>
> My plan is 2 pronged... to see if r1297560 is enough and if
> allowing a slotmem override is even needed (or wanted) ... ;)
>
> On Mar 6, 2012, at 12:35 PM, Zisis Lianas wrote:
>
>> Thanks Jim, that works fine for the default-rel-runtimedir configuration.
>> Slotmem file is created as <serverroot>/logs/slotmem-shm-sxxxxxxxx.shm.
>>
>> Now if also the slotmem-file-target-location directive gets available,
>> this thread is done for me.
>>
>>
>> Regards,
>> Zisis
>>
>> ----- Original Message -----
>> From: "Jim Jagielski" <jim [at] jaguNET>
>> To: dev [at] httpd
>> Sent: Tuesday, March 6, 2012 5:21:22 PM
>> Subject: Re: httpd 2.4.1 and mod_slotmem_shm / mod_proxy_balancer (AH01179)
>>
>> http://svn.apache.org/viewvc?rev=1297560&view=rev
>>
>> On Mar 6, 2012, at 10:39 AM, Jeff Trawick wrote:
>>
>>> On Tue, Mar 6, 2012 at 10:33 AM, Jim Jagielski <jim [at] jagunet> wrote:
>>>> Yeah, that seems better, ala ./modules/cache/mod_socache_dbm.c
>>>
>>> On behalf of anyone else reading this thread, here's the idiom from
>>> mod_socache_dbm.c:
>>>
>>> #define DEFAULT_DBM_PREFIX DEFAULT_REL_RUNTIMEDIR "/socache-dbm-"
>>> ...
>>> const char *path = apr_pstrcat(p, DEFAULT_DBM_PREFIX, namespace,
>>> NULL);
>>>
>>> ctx->data_file = ap_server_root_relative(p, path);
>>>
>>>
>>>>
>>>> On Mar 6, 2012, at 8:36 AM, Jeff Trawick wrote:
>>>>
>>>>> On Tue, Mar 6, 2012 at 7:56 AM, Jim Jagielski <jim [at] jagunet> wrote:
>>>>>> OK... What I'll do is add a directive which provides a
>>>>>> "default" location for slotmem file...
>>>>>
>>>>> Uhh, that seems as endless as per-mutex directives.
>>>>>
>>>>> Is slotmem not using DEFAULT_REL_RUNTIMEDIR already? (not perfect,
>>>>> but a good start)
>>>>> Directive to specify runtime directory (API returns serverroot +
>>>>> DEFAULT_REL_RUNTIMEDIR if not configured).
>>>>> Directive like Mutex but for shmem?
>>>>>
>>>>
>>>
>>>
>>>
>>> --
>>> Born in Roswell... married an alien...
>>>
>>
>

First page Previous page 1 2 Next page Last page  View All Apache dev RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.