[erlang-questions] running release handler from -eval or -run

Michael McDaniel erlangy@REDACTED
Thu May 21 02:06:48 CEST 2009


   correction ...


mmcdanie@REDACTED:~/misc/src/erlang$ erl
Erlang R13B (erts-5.7.1) [rq:1] [async-threads:0] [hipe] [kernel-poll:false]

Eshell V5.7.1  (abort with ^G)
1> release_handler:which_releases().
** exception exit: {noproc,{gen_server,call,[release_handler,which_releases]}}
     in function  gen_server:call/2
2> 



On Wed, May 20, 2009 at 04:50:21PM -0700, Michael McDaniel wrote:
> 
> If it is working for you from an erlang command line, sasl has already
> been started (not by default, though, as you can see below).
> 
> 
> mmcdanie@REDACTED:~/misc/src/erlang$ erl
> Erlang R13B (erts-5.7.1) [rq:1] [async-threads:0] [hipe] [kernel-poll:false]
> 
> Eshell V5.7.1  (abort with ^G)
> 1> release_handler:which_release().
> ** exception error: undefined function release_handler:which_release/0
> 2> 
> 
> 
> ~M
> 
> 
> 
> On Wed, May 20, 2009 at 03:57:25PM -0700, Joe Williams wrote:
> > That works for me, thanks guys. I assume when you use the erlang 
> > terminal sasl gets started up but using eval it doesn't start until 
> > after the directives are evaluated?
> > 
> > Thanks.
> > 
> > -Joe
> > 
> > 
> > Michael McDaniel wrote:
> > > try ...
> > >
> > > erl -eval 'application:start(sasl) , release_handler:which_releases(), init:st
> > > op()'
> > >
> > > The clue is in the release_handler documentation where it says it is
> > > a process belonging to the SASL application.  And the error message
> > > below saying there is noproc, {gen_server ... .
> > >
> > > ~M
> > >
> > >
> > > On Wed, May 20, 2009 at 02:34:37PM -0700, Joe Williams wrote:
> > >   
> > >> I am attempting to run release handler commands using -eval (or -run) 
> > >> and receive the following error. Running the commands in the erlang 
> > >> terminal work fine.
> > >>
> > >>     
> > >>> $ erl -eval 'release_handler:which_releases()'
> > >>> Erlang R13B (erts-5.7.1) [source] [64-bit] [smp:2:2] [rq:2] 
> > >>> [async-threads:0] [hipe] [kernel-poll:false]
> > >>>
> > >>> Eshell V5.7.1  (abort with ^G)
> > >>> 1> {"init terminating in 
> > >>> do_boot",{noproc,{gen_server,call,[release_handler,which_releases]}}}
> > >>>
> > >>> Crash dump was written to: erl_crash.dump
> > >>> init terminating in do_boot ()
> > >>>       
> > >> Running something like inets:start or application:which_applications 
> > >> works as expected:
> > >>
> > >>     
> > >>> $ erl -eval 'inets:start()'
> > >>> Erlang R13B (erts-5.7.1) [source] [64-bit] [smp:2:2] [rq:2] 
> > >>> [async-threads:0] [hipe] [kernel-poll:false]
> > >>>
> > >>> Eshell V5.7.1  (abort with ^G)
> > >>> 1>
> > >>>       
> > >> Any idea what might be causing this?
> > >>
> > >>
> > >> Thanks.
> > >>
> > >> -Joe
> > >>
> > >> -- 
> > >> Name: Joseph A. Williams
> > >> Email: joe@REDACTED
> > >> Blog: http://www.joeandmotorboat.com/
> > >>
> > >> _______________________________________________
> > >> erlang-questions mailing list
> > >> erlang-questions@REDACTED
> > >> http://www.erlang.org/mailman/listinfo/erlang-questions
> > >>     
> > >
> > >   
> > 
> > -- 
> > Name: Joseph A. Williams
> > Email: joe@REDACTED
> > Blog: http://www.joeandmotorboat.com/
> > 
> > _______________________________________________
> > erlang-questions mailing list
> > erlang-questions@REDACTED
> > http://www.erlang.org/mailman/listinfo/erlang-questions
> 
> -- 
> Michael McDaniel
> Portland, Oregon, USA
> http://trip.autosys.us
> http://autosys.us



More information about the erlang-questions mailing list