[erlang-questions] tracing process in a file

Surindar Sivanesan surindar.shanthi@REDACTED
Sat Nov 18 09:26:46 CET 2006


Thanks a lot for your suggestion Bengt.
I'll try your suggestion


On 11/15/06, Bengt Kleberg <bengt.kleberg@REDACTED> wrote:
>
> On 2006-11-10 07:35, Surindar Sivanesan wrote:
> >
> > Dear all,
> > I would like to trace  a process to a file when it starts at the
> background.
> > Which module can help in achieving the above.
>
> i never saw an answer to this question, so here is my suggestion:
>
> dbg:tracer( process, fun(P, {fun{ok, Pid}) -> io:fwrite(Pid, "~p", [P]),
> {ok, Pid} end}, file:open( "afile", [write] )} )
>
> the you should be able to do
> dbg:tp(your_module, []).
>
> or have a look at the dbg module for better granularity of traceing.
>
>
> bengt
> --
>    EPO guidelines 1978: "If the contribution to the known art resides
>    solely in a computer program then the subject matter is not
>    patentable in whatever manner it may be presented in the claims."
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://www.erlang.org/mailman/listinfo/erlang-questions
>



-- 
with regards,
S.Surindar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20061118/8ef72322/attachment.htm>


More information about the erlang-questions mailing list