To access the most up-to-date ejabberd documentation, please visit docs.ejabberd.im »
ejabberd 2.0.0 with OLPC mods on FC7; cant' login in to web interface
Submitted by kbakalar on Wed, 2008-04-09 21:09
I have forwarded 5222 and 5280 through my router to the machine running ejabberd. I can talk to it (on my local net) using Psi from my Windows machine (addressing it as jabber.homelinux.net, my dyndns address). I can't talk to it using Pidgin, either from Windows or from the same machine it is installed on. And I can't get the web interface to work at all. I tried 192.168.0.4 (the local address) I tried jabber.homelinux.net, I tried local..local.
Here is the config file:
[root@localhost kbakalar]# cd /etc/ejabberd [root@localhost ejabberd]# ls ejabberd.cfg ejabberdctl.cfg ejabberd.inetrc [root@localhost ejabberd]# cat *d.cfg %%% %%% ejabberd configuration file %%%
%%% The parameters used in this configuration file are explained in more detail %%% in the ejabberd Installation and Operation Guide. %%% Please consult the Guide in case of doubts, it is included in %%% your copy of ejabberd, and is also available online at %%% http://www.process-one.net/en/ejabberd/docs/
%%% This configuration file contains Erlang terms. %%% In case you want to understand the syntax, here are the concepts: %%% %%% - The character to comment a line is % %%% %%% - Each term ends in a dot, for example: %%% override_global. %%% %%% - A tuple has a fixed definition, its elements are %%% enclosed in {}, and separated with commas: %%% {loglevel, 4}. %%% %%% - A list can have as many elements as you want, %%% and is enclosed in [], for example: %%% [http_poll, web_admin, tls] %%% %%% - A keyword of ejabberd is a word in lowercase. %%% The strings are enclosed in "" and can have spaces, dots... %%% {language, "en"}. %%% {ldap_rootdn, "dc=example,dc=com"}. %%% %%% - This term includes a tuple, a keyword, a list and two strings: %%% {hosts, ["jabber.example.net", "im.example.com"]}. %%%
%% %% Override the old values stored in the database. %%
%% %% Override global options (shared by all ejabberd nodes in a cluster). %% override_global.
%% %% Override local options (specific for this particular ejabberd node). %% override_local.
%% %% Remove the Access Control Lists before new ones are added. %% override_acls.
%%% ========= %%% DEBUGGING
%% %% loglevel: Verbosity of log files generated by ejabberd. %% 0: No ejabberd log at all (not recommended) %% 1: Critical %% 2: Error %% 3: Warning %% 4: Info %% 5: Debug %% {loglevel, 4}.
%% %% watchdog_admins: If an ejabberd process consumes too much memory, %% send live notifications to those Jabber accounts. %% %%{watchdog_admins, ["bob@example.com"]}.
%%% ================ %%% SERVED HOSTNAMES
%% %% hosts: Domains served by ejabberd. %% You can define one or several, for example: %% {hosts, ["example.net", "example.com", "example.org"]}. %% {hosts, ["jabber.homelinux.net"]}.
%% %% route_subdomains: Delegate subdomains to other Jabber server. %% For example, if this ejabberd serves example.org and you want %% to allow communication with a Jabber server called im.example.org. %% %%{route_subdomains, s2s}.
%%% =============== %%% LISTENING PORTS
%% %% listen: Which ports will ejabberd listen, which service handles it %% and what options to start it with. %% {listen, [
{5222, ejabberd_c2s, [
%% %% If TLS is compiled and you installed a SSL %% certificate, put the correct path to the %% file and uncomment this line: %% %%{certfile, "/path/t/etc/ejabberd/ejabberd.pem"}, starttls,
%% %% s2s_use_starttls: Enable STARTTLS + Dialback for S2S connections. %% Allowed values are: true or false. %% You must specify a certificate file. %% %%{s2s_use_starttls, true}.
%% %% s2s_certfile: Specify a certificate file. %% %%{s2s_certfile, "/path/t/etc/ejabberd/ejabberd.pem"}.
%% %% domain_certfile: Specify a different certificate for each served hostname. %% %%{domain_certfile, "example.org", "/path/to/example_org.pem"}. %%{domain_certfile, "example.com", "/path/to/example_com.pem"}.
%% %% S2S whitelist or blacklist %% %% Default s2s policy for undefined hosts. %% %%{s2s_default_policy, allow}.
%% %% Allow or deny communication with specific servers. %% %%{{s2s_host, "goodhost.org"}, allow}. %%{{s2s_host, "badhost.org"}, deny}.
%%% ============== %%% AUTHENTICATION
%% %% auth_method: Method used to authenticate the users. %% The default method is the internal. %% If you want to use a different method, %% comment this line and enable the correct ones. %% {auth_method, internal}.
%% %% Authentication using external script %% Make sure the script is executable by ejabberd. %% %%{auth_method, external}. %%{extauth_program, "/path/to/authentication/script"}.
%% %% Authentication using ODBC %% Remember to setup a database in the next section. %% %%{auth_method, odbc}.
%% %% Authentication using PAM %% %%{auth_method, pam}. %%{pam_service, "pamservicename"}.
%% %% Authentication using LDAP %% %%{auth_method, ldap}. %% %% List of LDAP servers: %%{ldap_servers, ["localhost"]}. %% %% LDAP attribute that holds user ID: %%{ldap_uids, [{"mail", "%u@mail.example.org"}]}. %% %% Search base of LDAP directory: %%{ldap_base, "dc=example,dc=com"}. %% %% LDAP manager: %%{ldap_rootdn, "dc=example,dc=com"}. %% %% Password to LDAP manager: %%{ldap_password, "******"}.
%% %% Anonymous login support: %% auth_method: anonymous %% anonymous_protocol: sasl_anon | login_anon | both %% allow_multiple_connections: true | false %% %%{host_config, "public.example.org", [{auth_method, anonymous}, %% {allow_multiple_connections, false}, %% {anonymous_protocol, sasl_anon}]}. %% %% To use both anonymous and internal authentication: %% %%{host_config, "public.example.org", [{auth_method, [internal, anonymous]}]}.
%%% ============== %%% DATABASE SETUP
%% ejabberd uses by default the internal Mnesia database, %% so you can avoid this section. %% This section provides configuration examples in case %% you want to use other database backends. %% Please consult the ejabberd Guide for details about database creation.
%% %% MySQL server: %% %%{odbc_server, {mysql, "server", "database", "username", "password"}}. %% %% If you want to specify the port: %%{odbc_server, {mysql, "server", 1234, "database", "username", "password"}}.
%% %% PostgreSQL server: %% %%{odbc_server, {pgsql, "server", "database", "username", "password"}}. %% %% If you want to specify the port: %%{odbc_server, {pgsql, "server", 1234, "database", "username", "password"}}. %% %% If you use PostgreSQL, have a large database, and need a %% faster but inexact replacement for "select count(*) from users" %% %%{pgsql_users_number_estimate, true}.
%% %% ODBC compatible or MSSQL server: %% %%{odbc_server, "DSN=ejabberd;UID=ejabberd;PWD=ejabberd"}.
%%% =============== %%% TRAFFIC SHAPERS
%% %% The "normal" shaper limits traffic speed to 1.000 B/s %% {shaper, normal, {maxrate, 1000}}.
%% %% The "fast" shaper limits traffic speed to 50.000 B/s %% {shaper, fast, {maxrate, 50000}}.
%%% ==================== %%% ACCESS CONTROL LISTS
%% %% The 'admin' ACL grants administrative privileges to Jabber accounts. %% You can put as many accounts as you want. %% {acl, admin, {user, "kbakalar", "jabber.homelinux.net"}}. %%{acl, admin, {user, "ermine", "example.org"}}.
%% Define the maximum number of time a single user is allowed to connect: {access, max_user_sessions, [{10, all}]}.
%% This rule allows access only for local users: %% {access, local, [{allow, local}]}.
%% Only non-blocked users can use c2s connections: {access, c2s, [{deny, blocked}, {allow, all}]}.
%% For all users except admins used "normal" shaper {access, c2s_shaper, [{none, admin}, {normal, all}]}.
%% For all S2S connections used "fast" shaper {access, s2s_shaper, [{fast, all}]}.
%% Only admins can send announcement messages: {access, announce, [{allow, admin}]}.
%% Only admins can use configuration interface: {access, configure, [{allow, admin}]}.
%% Admins of this server are also admins of MUC service: {access, muc_admin, [{allow, admin}]}.
%% All users are allowed to use MUC service: {access, muc, [{allow, all}]}.
%% Every username can be registered via in-band registration: %% To disable in-band registration, replace 'allow' with 'deny'. {access, register, [{allow, all}]}.
%% Everybody can create pubsub nodes {access, pubsub_createnode, [{allow, all}]}.
%%% ================ %%% DEFAULT LANGUAGE
%% %% language: Default language used for server messages. %% {language, "en"}.
%%% ======= %%% MODULES
%% %% Modules enabled in all ejabberd virtual hosts. %% {modules, [ {mod_adhoc, []}, {mod_announce, [{access, announce}]}, % requires mod_adhoc {mod_caps, []}, {mod_configure,[]}, % requires mod_adhoc {mod_disco, []}, %%{mod_echo, [{host, "echo.localhost"}]}, {mod_irc, []}, {mod_last, []}, {mod_muc, [ %%{host, "conference.@HOST@"}, {access, muc}, {access_create, muc}, {access_persistent, muc}, {access_admin, muc_admin} ]}, %%{mod_muc_log,[]}, {mod_offline, []}, {mod_privacy, []}, {mod_private, []}, %%{mod_proxy65,[]}, {mod_pubsub, [ % requires mod_caps {access_createnode, pubsub_createnode}, {plugins, ["default", "pep"]} ]}, {mod_register, [ %% %% After successful registration, the user receives %% a message with this subject and body. %% {welcome_message, {"Welcome!", "Welcome to this Jabber server."}},
%% %% When a user registers, send a notification to %% these Jabber accounts. %% %%{registration_watchers, ["admin1@example.org"]},
there is no process running named ejabbard
telnet to 5222 connection refused.
telnet to 80 or 8080 (my http server) produces the expected garbage
there is no ejabbard.log
sasl.log contains a crash report for an
exception exit: {bad return, {{ejabbard_app, start, [normal,[]]},
and so on for a while. I will post the full sasl.log, if it can help
I posted the .cfg twice because I was unfamiliar with this posting software. It was a mistake. I promise I won't do it again.
So you found the first error message reported by ejabberd when starting. It says the 'stringprep' C dirver is of incorrect version. It means the file stringprep_drv.so
Maybe the ejabberd you use is compiled for 32bits kernel, and you are using a 64 bit kernel?
You can experiment to load the file manually. Check where the file is in your system, and try this:
$ erl
Erlang (BEAM) emulator version 5.6.2 [source] [smp:2] [async-threads:0] [kernel-poll:false]
Eshell V5.6.2 (abort with ^G)
1> erl_ddll:load_driver("/var/lib/ejabberd/priv/lib", stringprep_drv).
ok
2> q().
I downloaded the sources, applied the OLPC patches, compiled and installed with no errors (a few warnings)according to http://wiki.laptop.org/go/Installing_ejabberd. I get the same error message as I got with 1.1.3. in sasl.log when I start with the "System->Services" control panel in GNOME.
Why did you post your full
Why did you post your full config twice?
Check ejabberd.log and sasl.log.
Check if ejabberd listens in port 5222. For example: telnet 127.0.0.1 5222
ejabberd is not listening on 5222
there is no process running named ejabbard
telnet to 5222 connection refused.
telnet to 80 or 8080 (my http server) produces the expected garbage
there is no ejabbard.log
sasl.log contains a crash report for an
exception exit: {bad return, {{ejabbard_app, start, [normal,[]]},
and so on for a while. I will post the full sasl.log, if it can help
I posted the .cfg twice because I was unfamiliar with this posting software. It was a mistake. I promise I won't do it again.
sasl.log shows "driver_incorrect_version" crash report
I misread the log. I think it is crashing earlier. The question is, which driver is of the incorrect version??
=PROGRESS REPORT==== 11-Apr-2008::22:17:46 ===
supervisor: {local,ssl_sup}
started: [{pid,<0.113.0>},
{name,ssl_connection},
{mfa,{ssl_connection_sup,start_link,[]}},
{restart_type,permanent},
{shutdown,4000},
{child_type,supervisor}]
=PROGRESS REPORT==== 11-Apr-2008::22:17:46 ===
application: ssl
started_at: ejabberd@jabber
=CRASH REPORT==== 11-Apr-2008::22:17:46 ===
crasher:
pid: <0.115.0>
registered_name: stringprep
exception exit: {{case_clause,{error,driver_incorrect_version}},
[{stringprep,init,1},
{gen_server,init_it,6},
{proc_lib,init_p,5}]}
in function gen_server:init_it/6
initial call: gen:init_it(gen_server,<0.114.0>,<0.114.0>,
{local,stringprep},
stringprep,[],[])
ancestors: [stringprep_sup,<0.37.0>]
messages: []
links: [<0.114.0>]
dictionary: []
trap_exit: false
status: running
heap_size: 233
stack_size: 23
reductions: 209
neighbours:
=SUPERVISOR REPORT==== 11-Apr-2008::22:17:46 ===
Supervisor: {local,stringprep_sup}
Context: start_error
Reason: {{case_clause,{error,driver_incorrect_version}},
[{stringprep,init,1},
{gen_server,init_it,6},
{proc_lib,init_p,5}]}
Offender: [{pid,undefined},
{name,stringprep},
{mfa,{stringprep,start_link,[]}},
{restart_type,permanent},
{shutdown,brutal_kill},
{child_type,worker}]
=CRASH REPORT==== 11-Apr-2008::22:17:49 ===
crasher:
pid: <0.36.0>
registered_name: []
exception exit: {bad_return,
{{ejabberd_app,start,[normal,[]]},
{'EXIT',
{badarg,
[{erlang,port_control,
[stringprep_port,2,
"jabber.homelinux.net"]},
{stringprep,control,2},
{jlib,nodeprep,1},
{ejabberd_config,normalize_hosts,2},
{ejabberd_config,add_hosts_to_option,2},
{lists,foldl,3},
{ejabberd_config,load_file,1},
{ejabberd_app,start,2}]}}}}
in function application_master:init/4
initial call: application_master:init(<0.5.0>,<0.35.0>,
{appl_data,ejabberd,
[ejabberd,ejabberd_sup,
ejabberd_auth,ejabberd_router,
ejabberd_sm,ejabberd_s2s,
ejabberd_local,ejabberd_listeners,
ejabberd_iq_sup,
ejabberd_service_sup,
ejabberd_s2s_out_sup,
ejabberd_s2s_in_sup,
ejabberd_c2s_sup,
ejabberd_mod_roster,
ejabberd_mod_echo,
ejabberd_mod_pubsub,
ejabberd_mod_irc,ejabberd_mod_muc,
ejabberd_offline,random_generator],
undefined,
{ejabberd_app,[]},
[acl,adhoc,configure,
cyrsasl_anonymous,cyrsasl,
cyrsasl_digest,cyrsasl_plain,
ejabberd_admin,ejabberd_app,
ejabberd_auth_anonymous,
ejabberd_auth,
ejabberd_auth_external,
ejabberd_auth_internal,
ejabberd_auth_ldap,
ejabberd_auth_odbc,
ejabberd_auth_pam,ejabberd,
ejabberd_c2s,ejabberd_c2s_config,
ejabberd_config,ejabberd_ctl,
ejabberd_frontend_socket,
ejabberd_hooks,ejabberd_http,
ejabberd_http_bind,
ejabberd_http_poll,
[trunctated]
Maybe stringprep_drv compiled for a differentarchitecture
I misread the log. I think it is crashing earlier. The question is, which driver is of the incorrect version??
So you found the first error message reported by ejabberd when starting. It says the 'stringprep' C dirver is of incorrect version. It means the file stringprep_drv.so
Maybe the ejabberd you use is compiled for 32bits kernel, and you are using a 64 bit kernel?
You can experiment to load the file manually. Check where the file is in your system, and try this:
stringprep_drv is the problem; what next?
Well, so it is. I am on a 32 bit architecture-- an old one, dual processor 300 Mz Pentiums in an HP Kayak SU. I got ejabberd fromhttp://wiki.laptop.org/go/Installing_ejabberd -> http://people.collabora.co.uk/~robot101/olpc-ejabberd/ejabberd-2.0.0-0.1... http://wiki.laptop.org/go/Installing_ejabberd ?
Could it be that this is broken?
Should I try to compile from the Collabra sources according to
# locate stringprep
/usr/lib/ejabberd-2.0.0/ebin/stringprep.beam
/usr/lib/ejabberd-2.0.0/ebin/stringprep_sup.beam
/usr/lib/ejabberd-2.0.0/priv/lib/stringprep_drv.so
/usr/lib/python2.5/stringprep.py
/usr/lib/python2.5/stringprep.pyc
/usr/lib/python2.5/stringprep.pyo
[root@jabber ejabberd]# erl
Erlang (BEAM) emulator version 5.6.1 [source] [smp:2] [async-threads:0] [hipe] [kernel-poll:false]
Eshell V5.6.1 (abort with ^G)
1> erl_ddll:load_driver("/usr/lib/ejabberd-2.0.0/priv/lib"), stringprep_drv).
* 1: syntax error before: ')'
1> erl_ddll:load_driver("/usr/lib/ejabberd-2.0.0/priv/lib", stringprep_drv).
{error,driver_incorrect_version}
2>
ejabbard-1-.1.3-1.olpc gives different crash
I reverted to the previous version of the OLPC ejabberd -- ejabberd-1.1.3-1.olpc.i386.rpm Now I get a different crash:
=PROGRESS REPORT==== 12-Apr-2008::12:11:45 ===
application: ssl
started_at: ejabberd@jabber
=CRASH REPORT==== 12-Apr-2008::12:11:47 ===
crasher:
pid: <0.36.0>
registered_name: []
exception exit: {bad_return,
{{ejabberd_app,start,[normal,[]]},
{'EXIT',
{{badmatch,{aborted,{no_exists,config}}},
[{ejabberd_config,set_opts,1},
{ejabberd_app,start,2},
{application_master,start_it_old,4}]}}}}
in function application_master:init/4
initial call: application_master:init(<0.5.0>,<0.35.0>,
{appl_data,ejabberd,
[ejabberd,ejabberd_sup,
ejabberd_auth,ejabberd_router,
ejabberd_sm,ejabberd_s2s,
ejabberd_local,ejabberd_listeners,
ejabberd_iq_sup,
ejabberd_service_sup,
ejabberd_s2s_out_sup,
ejabberd_s2s_in_sup,
ejabberd_c2s_sup,
ejabberd_mod_roster,
ejabberd_mod_echo,
ejabberd_mod_pubsub,
ejabberd_mod_irc,ejabberd_mod_muc,
ejabberd_offline,random_generator],
undefined,
{ejabberd_app,[]},
[acl,configure,cyrsasl,
cyrsasl_digest,cyrsasl_plain,
ejabberd,ejabberd_app,
ejabberd_auth,ejabberd_c2s,
ejabberd_config,ejabberd_listener,
ejabberd_logger_h,ejabberd_local,
ejabberd_router,ejabberd_s2s,
ejabberd_s2s_in,ejabberd_s2s_out,
ejabberd_service,ejabberd_sm,
ejabberd_sup,ejabberd_tmp_sup,
gen_iq_handler,gen_mod,jd2ejd,
jlib,mod_caps,mod_configure,
mod_ctlextra,mod_disco,mod_echo,
mod_last,mod_offline,mod_private,
mod_register,mod_roster,mod_stats,
mod_time,mod_vcard,mod_version,
randoms,sha,shaper,translate,xml,
xml_stream],
[],infinity,infinity},
normal)
ancestors: [<0.35.0>]
messages: [{'EXIT',<0.37.0>,normal}]
links: [<0.35.0>,<0.5.0>]
dictionary: []
trap_exit: true
status: running
heap_size: 610
stack_size: 23
reductions: 123
neighbours:
ejabberd 2.0.0 from source w/olpc patches gives same error
I downloaded the sources, applied the OLPC patches, compiled and installed with no errors (a few warnings)according tohttp://wiki.laptop.org/go/Installing_ejabberd . I get the same error message as I got with 1.1.3. in sasl.log when I start with the "System->Services" control panel in GNOME.
Any advice would be appreciated.
Check this FAQ page
I reverted to the previous version of the OLPC ejabberd -- ejabberd-1.1.3-1.olpc.i386.rpm Now I get a different crash:
=CRASH REPORT==== 12-Apr-2008::12:11:47 ===
crasher:
pid: <0.36.0>
registered_name: []
exception exit: {bad_return,
{{ejabberd_app,start,[normal,[]]},
{'EXIT',
{{badmatch,{aborted,{no_exists,config}}},
[{ejabberd_config,set_opts,1},
Check this FAQ page:
aborted,{no_exists,config}
Ah, then ejabberd can't start
there is no process running named ejabberd
telnet to 5222 connection refused.
If telnet fails, then you are sure ejabberd couldn't start correctly.
BTW, the system process you want to search for ejabberd is called 'beam'.