How to find out what's going on

Sean Hinde <>
Wed Jan 4 02:13:29 CET 2006


On 4 Jan 2006, at 00:46, Joel Reymont wrote:

> Why would throughput be better with synchronous logging as opposed  
> to asynchronous?

Because it prevents the message queue to the disklog server growing  
and hence the CPU thrashing through the message queue every time a  
message is added to it.

>
> I'm afraid of tracing becoming a bottleneck if I make it  
> synchronous, sort of like a lock that only lets one process  
> through. Maybe my fears are unfounded, though.

The whole system won't go faster than the disk logging, that is true.  
You could buy a faster disk array, or write a custom logger which  
aggregates say 100 messages then writes them to disk on one chunk.

All other processes can run (the ones not waiting for the disk) if  
you have enabled the thread pool.

>
> Also, how do I get hold of the disk_log pid to inspect the message  
> queue length? I found pid2name(Pid) -> {ok, Log} | undefined but  
> don't see a name2pid(Name) -> {ok, Pid}.

do i(). and look to see if there are any processes with large message  
queues. If there are none then you do not have this problem.

>
> On Jan 4, 2006, at 12:10 AM, Sean Hinde wrote:
>
>> Try with disk_log:log instead and see if you get the same result.  
>> From what I have seen in the past the throughput under full load  
>> will increase dramatically - especially if combined with emulator  
>> thread pool (erl +A 10).
>>
>
> --
> http://wagerlabs.com/
>
>
>
>
>




More information about the erlang-questions mailing list