Zotonic CLI cannot connect to running instance

16 views
Skip to first unread message

Rudi Angela

unread,
Feb 16, 2017, 3:10:23 AM2/16/17
to Zotonic users
Hi there,
When trying to create a new web site with 'zotonic addsite' I get the following error:

erl_call: failed to connect to node zotonic001@localhost

Zotonic is not running. You need to start Zotonic first to use this command.


I've had this error in the past, but cannot remember how to solve it. Recall it's something with the host name, so I checked:

[admin@zotonic /opt/local/zotonic]$ cat /etc/hosts

::1             localhost

127.0.0.1       localhost localhost.local loghost zotonic.olmeca.nl zotonic

[admin@zotonic /opt/local/zotonic]$ hostname 

zotonic.olmeca.nl


AFAICS it all seems fine. Any clues anyone?

Rudi

Mikael Karlsson

unread,
Feb 16, 2017, 3:45:18 AM2/16/17
to zotoni...@googlegroups.com
What is the node name of the zotonic node that you have started:
zotonic@zotonic, zotonic@localhost or zot...@zotonic.olmeca.nl?
I think Zotonic setup scripts uses "hostname -f" to detect fully qualified name.
If you use this do you get zotonic.olmeca.nl or localhost.local ?

I get different answers on my machine
$ hostname
creado-se-2
$ hostname -f
localhost.localdomain
> --
>
> ---
> You received this message because you are subscribed to the Google Groups
> "Zotonic users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to zotonic-user...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

Rudi Angela

unread,
Feb 16, 2017, 3:37:21 PM2/16/17
to Zotonic users
My problem disappeared after restarting epmd, but to answer your questions, the node name was 'zot...@zotonic.olmeca.nl' which corresponds to the hostname (which is 'zotonic.olmeca.nl'). 
I'm running on Solaris, so the hostname command has no -f option.
Thanks anyway for helping.

Rudi
Reply all
Reply to author
Forward
0 new messages