What does the following command give you:
erl_call -name zotonic09@localhost -a "zotonic status"; echo $?
The output should be: ok0
Hi, all!Try to create new site:cd bin
./zotonic addsiteZotonic is not running. You need to start zotonic first to use this command.
Butps -fe | grep zotoniczotonic 28767 1 1 21:34 ? 00:00:03 /usr/lib/erlang/erts-5.8/bin/beam -- -root /usr/lib/erlang -progname erl -- -home /home/zotonic -- -pa /home/zotonic/zotonic/0.9.0/ebin /home/zotonic/zotonic/0.9.0/deps/bert.erl/ebin /home/zotonic/zotonic/0.9.0/deps/dh_date/ebin /home/zotonic/zotonic/0.9.0/deps/gen_smtp/ebin /home/zotonic/zotonic/0.9.0/deps/iconv/ebin /home/zotonic/zotonic/0.9.0/deps/lager/ebin /home/zotonic/zotonic/0.9.0/deps/mimetypes/ebin /home/zotonic/zotonic/0.9.0/deps/mochiweb/ebin /home/zotonic/zotonic/0.9.0/deps/ua_classifier/ebin /home/zotonic/zotonic/0.9.0/deps/webzmachine/ebin /home/zotonic/zotonic/0.9.0/modules/mod_oauth/deps/erlang-oauth/ebin /home/zotonic/zotonic/0.9.0/priv/modules/*/deps/*/ebin /home/zotonic/zotonic/0.9.0/priv/sites/*/modules/*/deps/*/ebin -name zotonic09@localhost -boot start_sasl -heart -noshell -noinput -s zotonic
zotonic 28768 28767 0 21:34 ? 00:00:00 heart -pid 28767
First of all check what "host YOURIP" returns. It should return the hostname. You can also try "nslookup YOURIP", e.g.:
host 192.168.1.68
or
nslookup 192.168.1.68
In Erlang shell, after starting Zotonic, you can try net_adm:localhost(). and inet:gethostname().
One thing I see is that your Erlang version is too old...
You need r14b03 or newer.
Cheers, Arjan
One thing I see is that your Erlang version is too old...
You need r14b03 or newer.
Cheers, Arjan
zotonic@helentana-dev:~/zotonic/mainline$ ./start.shErlang R14A (erts-5.8) [source] [64-bit] [rq:1] [async-threads:0] [hipe] [kernel-poll:true]Eshell V5.8 (abort with ^G)
(zotonic001@helentana-dev.local)1> ** Found 0 name clashes in code paths
** Found 0 name clashes in code paths
21:53:38.908 [info] Application lager started on node 'zotonic001@helentana-dev.local'21:53:38.972 [info] Application mnesia started on node 'zotonic001@helentana-dev.local'21:53:38.978 [info] Application public_key started on node 'zotonic001@helentana-dev.local'21:53:38.986 [info] Application ssl started on node 'zotonic001@helentana-dev.local'21:53:39.013 [info] Application inets started on node 'zotonic001@helentana-dev.local'
** Found 0 name clashes in code paths
21:53:39.098 [info] Application mimetypes started on node 'zotonic001@helentana-dev.local'21:53:39.139 [info] gen_smtp_server starting at 'zotonic001@helentana-dev.local'
21:53:39.139 [info] listening on {0,0,0,0}:2525 via tcp
21:53:39.181 [info] Application zotonic started on node 'zotonic001@helentana-dev.local'inet:gethostname().{ok,"helentana-dev"}(zotonic001@helentana-dev.local)2> net_adm:localhost().
I still think this is a problem with the domain name of the Erlang node. Specifically the script says that you started the node on zoton...@helentana-dev.local whereas net_adm:localhost(). returns helentana-dev.ru. Where does the .ru come from?
Could you please do a quick test and run this command:
erl_call -name zoton...@helentana-dev.local
and
erl_call -name zoton...@helentana-dev.ru
If erl_call can connect to the node then it doesn't return anything, and it returns an error if it can't.
And also, can you temporary edit zotonic/src/scripts/helpers/zotonic-debug script and add echo in front of the command, e.g.:
echo $ERL -env (...)
Then try to call ./start.sh as usually. This time instead of starting the node it will print to the terminal the command and its parameters that it's using to start the node.
In my case erl_call could be found in this path:
/usr/local/lib/erlang/lib/erl_interface-3.7.5/bin/erl_call
whereas all other erlang binaries are in this path:
/usr/local/bin/
I think location of erl_call may be system specific. Did you compile Erlang yourself or downloaded as a package? I would try something like:
cd /
find . | grep erl_call
You could also try "man erl_call" to see if the system knows anything about it.
So, the hostname is now OK. But as I understood from previous emails addsite does work for you now, doesn't it?
The lack of pictures is probably due to the fact that module Bootstrap isn't enabled by default. At least that was the reason for me.
You can enable modules under System | Modules in Admin. It is also accessible at http://example.com/admin/modules where example.com is your domain name :)
Do you have the module for your site activated? For me it is simply called "blog zotonic site". If this is deactivated, you will not get a functional site.
Do you also have Zotonic Base activated?
I hope you don't mind the trial and error approach. It can be quite difficult to know the specific issue sometimes :)
Hi, all!
Try to create new site:
cd bin
./zotonic addsite
Zotonic is not running. You need to start zotonic first to use this command.
Butps -fe | grep zotoniczotonic 28767 1 1 21:34 ? 00:00:03 /usr/lib/erlang/erts-5.8/bin/beam -- -root /usr/lib/erlang -progname erl -- -home /home/zotonic -- -pa /home/zotonic/zotonic/0.9.0/ebin /home/zotonic/zotonic/0.9.0/deps/bert.erl/ebin /home/zotonic/zotonic/0.9.0/deps/dh_date/ebin /home/zotonic/zotonic/0.9.0/deps/gen_smtp/ebin /home/zotonic/zotonic/0.9.0/deps/iconv/ebin /home/zotonic/zotonic/0.9.0/deps/lager/ebin /home/zotonic/zotonic/0.9.0/deps/mimetypes/ebin /home/zotonic/zotonic/0.9.0/deps/mochiweb/ebin /home/zotonic/zotonic/0.9.0/deps/ua_classifier/ebin /home/zotonic/zotonic/0.9.0/deps/webzmachine/ebin /home/zotonic/zotonic/0.9.0/modules/mod_oauth/deps/erlang-oauth/ebin /home/zotonic/zotonic/0.9.0/priv/modules/*/deps/*/ebin /home/zotonic/zotonic/0.9.0/priv/sites/*/modules/*/deps/*/ebin -name zotonic09@localhost -boot start_sasl -heart -noshell -noinput -s zotoniczotonic 28768 28767 0 21:34 ? 00:00:00 heart -pid 28767
What I do wrong?
PS. Sorry for my bad English :)
core: Make configurable whether we run with -name or with -sname
This fixes the fact that Zotonic always required a FQDN and the "zotonic shell" command was not working reliably. Zotonic now defaults to running with "-sname". To use "-name", set the envirnoment variable ZOTONIC_DISTRIBUTED=true. Distributed mode *really* requires a proper FQDN as returned by "hostname -f". A better way to determine if Zotonic is running has also been added, using "erl_call", and we determine more reliably where the "erl_call" binary is located.
Makes the Erlang runtime system into a distributed node, similar to -name, but the host name portion of the node name Name@Host will be the short name, not fully qualified.
This is sometimes the only way to run distributed Erlang if the DNS (Domain Name System) is not running. There can be no communication between nodes running with the -sname flag and those running with the -name flag, as node names must be unique in distributed Erlang systems.
Makes the Erlang runtime system into a distributed node. This flag invokes all network servers necessary for a node to become distributed. See net_kernel(3). It is also ensured that epmd runs on the current host before Erlang is started. See epmd(1).
The name of the node will be Name@Host, where Host is the fully qualified host name of the current host. For short names, use the -sname flag instead.
$ ZOTONIC_DISTRIBUTED=true bin/zotonic debug
--
---
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.