I am trying to send a message from one user 'A' to other 'B' using the syntax eg:
<message from='abhi@XXXX.com' to='amogh@XXXX.com' xml:lang='en' id='ab232' type="chat">
<subject></subject>
<body>Today is Thursday</body>
</message>
The message was successfully entered into the database but when I checked the error log in putty, I got following errors :
2017-02-02 06:39:56.738 [error] <0.6865.0>@ejabberd_hooks:run_fold1:371 {badarg,[{erlang,list_to_binary,[["from=",<<"abhi">>,"&",ok,"to=",<<"amogh">>,"&",ok,"body=","Today is Thursday","&",ok,"type=","chat","&",ok,"chat_sent=",[],"&",ok,"subject=",[],"&",ok,"message_id=","ab232","&",ok,"xml=",<<"<message from='abhi@XXXX' type='chat' to='amogh@XXXX.com' xml:lang='en' id='ab232'>\n <subject/>\n <body>Today is Thursday</body> \n</message>">>,"&",ok,"done=11"]],[]},{mod_post_log,post_xml,3,[{file,"src/mod_post_log.erl"},{line,181}]},{mod_post_log,log_chat_with_body,3,[{file,"src/mod_post_log.erl"},{line,81}]},{mod_post_log,log_packet,3,[{file,"src/mod_post_log.erl"},{line,49}]},{mod_post_log,log_user_send,4,[{file,"src/mod_post_log.erl"},{line,37}]},{ejabberd_hooks,safe_apply,3,[{file,"src/ejabberd_hooks.erl"},{line,386}]},{ejabberd_hooks,run_fold1,4,[{file,"src/ejabberd_hooks.erl"},{line,367}]},{ejabberd_c2s,session_established2,2,[{file,"src/ejabberd_c2s.erl"},{line,1298}]}]}
running hook: {user_send_packet,[{state,{socket_state,p1_tls,{tlssock,#Port<0.5939>,#Port<0.5940>},<0.6864.0>},ejabberd_socket,#Ref<0.0.0.84028>,false,<<"3676775281">>,undefined,c2s,c2s_shaper,false,true,false,true,[verify_none,compression_none,{protocol_options,<<"no_sslv3">>},{certfile,<<"/opt/ejabberd-15.11/conf/server.pem">>}],true,{jid,<<"abhi">>,<<"XXXX.com">>,<<"XXXX-PC">>,<<"abhi">>,<<"XXXX.com">>,<<"XXXX-PC">>},<<"abhi">>,<<"XXXX.com">>,<<"XXXX-PC">>,{{1486,15801,481569},<0.6865.0>},{4,{{<<"abhi">>,<<"XXXX.com">>,<<>>},{{<<"919987769983">>,<<"XXXX.com">>,<<>>},{{<<"919685088011">>,<<"XXXX.com">>,<<>>},nil,nil},nil},{{<<"amogh">>,<<"XXXX.com">>,<<>>},nil,nil}}},{4,{{<<"abhi">>,<<"XXXX.com">>,<<>>},{{<<"919987769983">>,<<"XXXX.com">>,<<>>},{{<<"919685088011">>,<<"XXXX.com">>,<<>>},nil,nil},nil},{{<<"amogh">>,<<"XXXX.com">>,<<>>},nil,nil}}},{4,{{<<"919685088011">>,<<"XXXX.com">>,<<>>},nil,{{<<"919987769983">>,<<"XXXX.com">>,<<>>},nil,{{<<"abhi">>,<<"XXXX.com">>,<<>>},nil,{{<<"amogh">>,<<"XXXX.com">>,<<>>},nil,nil}}}}},{xmlel,<<"presence">>,[{<<"xml:lang">>,<<"en">>}],[{xmlcdata,<<"\n">>},{xmlel,<<"priority">>,[],[{xmlcdata,<<"5">>}]},{xmlcdata,<<"\n">>},{xmlel,<<"c">>,[{<<"xmlns">>,<<"http://jabber.org/protocol/caps">>},{<<"node">>,<<"http://psi-im.org/caps">>},{<<"ver">>,<<"caps-b75d8d2b25">>},{<<"ext">>,<<"ca cs ep-notify-2 html">>}],[]},{xmlcdata,<<"\n">>}]},{1486,15806,893116},{userlist,none,[],false},c2s_tls,ejabberd_auth_odbc,{{183,87,126,235},49324},[{caps_resources,{2,{{<<"amogh">>,<<"XXXX.com">>,<<"XXXX-PC">>},{caps,<<"http://psi-im.org/caps">>,<<"caps-b75d8d2b25">>,<<>>,[<<"ca">>,<<"cs">>,<<"ep-notify-2">>,<<"html">>]},{{<<"abhi">>,<<"XXXX.com">>,<<"XXXX-PC">>},{caps,<<"http://psi-im.org/caps">>,<<"caps-b75d8d2b25">>,<<>>,[<<"ca">>,<<"cs">>,<<"ep-notify-2">>,<<"html">>]},nil,nil},nil}}}],active,[],inactive,undefined,undefined,1000,undefined,300,300,false,0,0,<<"en">>},{jid,<<"abhi">>,<<"XXXX.com">>,<<"XXXX-PC">>,<<"abhi">>,<<"XXX.com">>,<<"XXXX-PC">>},{jid,<<"amogh">>,<<"XXXX.com">>,<<>>,<<"amogh">>,<<"XXXX.com">>,<<>>}]}
2017-02-02 06:56:32.553 [error] <0.6865.0>@ejabberd_hooks:run_fold1:371 {badarg,[{erlang,list_to_binary,[["from=",<<"abhi">>,"&",ok,"to=",<<"amogh">>,"&",ok,"body=","xyxyxyxy","&",ok,"type=","chat","&",ok,"chat_sent=","2017-02-2T12:20:35.519Z","&",ok,"subject=",[],"&",ok,"message_id=","ab232","&",ok,"xml=",<<"<message from='abhi@XXXX.com/XXX-PC' to='amogh@XXXX.com' xml:lang='en' id='ab232' type='chat' chat_sent='2017-02-2T12:20:35.519Z'>\n <subject/>\n <body>xyxyxyxy</body> \n</message>">>,"&",ok,"done=11"]],[]},{mod_post_log,post_xml,3,[{file,"src/mod_post_log.erl"},{line,181}]},{mod_post_log,log_chat_with_body,3,[{file,"src/mod_post_log.erl"},{line,81}]},{mod_post_log,log_packet,3,[{file,"src/mod_post_log.erl"},{line,49}]},{mod_post_log,log_user_send,4,[{file,"src/mod_post_log.erl"},{line,37}]},{ejabberd_hooks,safe_apply,3,[{file,"src/ejabberd_hooks.erl"},{line,386}]},{ejabberd_hooks,run_fold1,4,[{file,"src/ejabberd_hooks.erl"},{line,367}]},{ejabberd_c2s,session_established2,2,[{file,"src/ejabberd_c2s.erl"},{line,1298}]}]}
I am totally confused about what exactly the error is and where exactly to search for the error . Please help me to identify the error and to solve it or at least give me some good hint to solve it.
What ejabberd version? Did
What ejabberd version? Did that work previously, or you just recently installed mod_post_log?