[erlang-questions] question about node spawning

Michael McDaniel <>
Wed Sep 12 21:57:24 CEST 2007


On Wed, Sep 12, 2007 at 03:14:30PM -0300, Josh Noble wrote:
> Hi, please let me know if this is off-topic or could be handled
> somewhere else better, but I figured I'd throw it up here and see what
> happens. When I initialize a process like:
> 
> erl -sname base
> 
> I get this:
> 
> ()
> 
> which throws errors when I try to run the "multiple processes on
> localhost" example from ch. 10 of the Programming Erlang book because
> the rpc chokes on the 'cpe-190-55-115-44'. I'm not sure why this is
> happening, but if anyone has any advice on how to configure processes
> when they're spawned a little better. I can of course just do
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

 I guess that 'cpe-109-55-115-44' (with single quotes) would work fine, 
 since it is an atom.  However, cpe-109-55-115-44 is not an atom and, 
 with the minus sign, is not a valid expression, either.

 1> cpe-109-55-115-44.
 =ERROR REPORT==== <snip>
 <snip>
 ** exited: {badarith,[{erl_eval,eval_op,3},
 <snip>

 It appears that your computer's hostname is getting set to the ISP's
 name for your location.  "Customer Premise Equipment ..." with your IP.
                          ^^^^^^^^^^^^^^^^^^^^^^
                          cpe-190-blah blah

 If you change your hostname to a valid erlang expression, then your
 "erl -sname base" should work fine.

~Michael

> 
> erl -sname 
> 
> and it's fine. I'm just wondering why the default spawning is a little
> strange. Thanks,
> 
> Josh
> 
> -- 
> Joshua Noble
> http://thefactoryfactory.com
> _______________________________________________
> erlang-questions mailing list
> 
> http://www.erlang.org/mailman/listinfo/erlang-questions
> 
> !DSPAM:52,46e82cae73321194299324!
> 
> 

-- 
Michael McDaniel
Portland, Oregon, USA
http://autosys.us
+1 503 283 5284



More information about the erlang-questions mailing list