Daniel,

I changed the timeouts as per your suggestion. When I send the message from JAM -> WM I still get no messages (the ngrep output is below). First off, there is obviously a duplicate message being send there. Then, the 400 comes back from WM client. What gives?

    Igor

U 144.14.255.145:5060 -> 144.14.62.75:12157
  MESSAGE sip:144.14.62.75:12157 SIP/2.0..Record-Route: <sip:igorb@144.14.255.145;ftag=a5a3ce0e783e6e6de506638e4c2bc736-20
  4a;lr>..Via: SIP/2.0/UDP 144.14.255.145;branch=z9hG4bK8dcb.214ce0e2.0..Via: SIP/2.0/UDP 144.14.255.145;branch=z9hG4bK7e1
  7.0bd7c7b5.0..To: sip:igorb@piias12.ms.com..From: <sip:igorb*jamny1@sait661>;tag=a5a3ce0e783e6e6de506638e4c2bc736-204a..
  CSeq: 10 MESSAGE..Call-ID: 5fbc9eb5-11089@144.14.255.145..Content-Length: 3..User-Agent: Sip EXpress router(0.8.12dev-t1
  1 (i386/linux))..Content-Type: text/plain..Contact: <sip:igorb*jamny1@sait661>....zxc
#
U 144.14.255.145:5060 -> 144.14.62.75:12157
  MESSAGE sip:144.14.62.75:12157 SIP/2.0..Record-Route: <sip:igorb@144.14.255.145;ftag=a5a3ce0e783e6e6de506638e4c2bc736-20
  4a;lr>..Via: SIP/2.0/UDP 144.14.255.145;branch=z9hG4bK8dcb.214ce0e2.0..Via: SIP/2.0/UDP 144.14.255.145;branch=z9hG4bK7e1
  7.0bd7c7b5.0..To: sip:igorb@piias12.ms.com..From: <sip:igorb*jamny1@sait661>;tag=a5a3ce0e783e6e6de506638e4c2bc736-204a..
  CSeq: 10 MESSAGE..Call-ID: 5fbc9eb5-11089@144.14.255.145..Content-Length: 3..User-Agent: Sip EXpress router(0.8.12dev-t1
  1 (i386/linux))..Content-Type: text/plain..Contact: <sip:igorb*jamny1@sait661>....zxc
#
U 144.14.62.75:1555 -> 144.14.255.145:5060
  SIP/2.0 400 Bad Request..Via: SIP/2.0/UDP 144.14.255.145;branch=z9hG4bK8dcb.214ce0e2.0..Via: SIP/2.0/UDP 144.14.255.145;
  branch=z9hG4bK7e17.0bd7c7b5.0..From: <sip:igorb*jamny1@sait661>;tag=a5a3ce0e783e6e6de506638e4c2bc736-204a..To: sip:igorb
  @piias12.ms.com;tag=6810f81b-2264-4a2a-8c11-f4002710fb62..Call-ID: 5fbc9eb5-11089@144.14.255.145..CSeq: 10 MESSAGE..User
  -Agent: Windows RTC/1.0..Content-Length: 0....
 

Daniel-Constantin Mierla wrote:

When that value is 1 the Jabber connection is going to be closed, it has
expired. The cache_time specifies the time to keep a jabber connection
open if there is no traffic through it, when that time expires the
connection is closed. Otherwise, if a message is not successfully
delivered to SIP user then the jabber connection is closed, too. Watch
your network traffic (using ngrep, tcpdump or ethereal) to see if any
SIP request from Jabber gateway is launched on wire and whether it gets
a non 2xx reply code or not.

Best regards,
Daniel

Igor Boguslavsky wrote:

> I think I have just created that version myself :) This is what I get
> with more debug on (note the cbp value: xj_send_sip_msg() craps out
> since it's non-zero - is that the way it should be?)
>
>  0(10655) XJAB:xj_worker:10668: something is coming
>  0(10655) XJAB:xj_worker:10668: checking socket <8> ...
>  0(10655) XJAB:xj_worker:10668: received: 121bytes Err:0/EA:11
>  0(10655) XJAB: xj_jcon_update [sip:igorb@piias12.ms.com] 200
>  0(10655) XJAB:xj_worker: JMSG START ----------
> <message to='igorb@sait661/serXjab' from='igorb@jamny1/Office' id='19'
> type='chat'><body>;lkdfgdfgdfgdfg</body></message>
>  JABBER: JMSGL:121 END ----------
>  0(10655) XJAB:xj_parse_jab: XODE ret:0 pos:121
>  0(10655) XJAB:xj_manage_jab: jabber [message] received
>  0(10655) XJAB:xj_address_translation:10668: - checking aliases
>  0(10655) XJAB:xj_address_translation:10668: - domain is [jamny1/Office]
>  0(10655) XJAB:xj_address_translation:10668: - doing address correction
>  0(10655) XJAB:xj_send_sip_msg: to = sip:igorb@piias12.ms.com
>  0(10655) XJAB:xj_send_sip_msg: from = igorb*jamny1@sait661
>  0(10655) XJAB:xj_send_sip_msg: msg = ;lkdfgdfgdfgdfg
>  0(10655) XJAB:xj_send_sip_msg: cbp = 1
>  0(10655) XJAB:xj_manage_jab: ERROR SIP MESSAGE was not sent ...
>  0(10655) XJAB:xj_worker:10668: msgs from socket <8> parsed ...
>
>     Thank you,
>     Igor
>
> Daniel-Constantin Mierla wrote:
>
>> Hello,
>> it seems that one of the parameters for sending messages (i.e., from,
>> to, body) is null or the connection to jabber is going to be closed. The
>> second seems more viable so please set cache_time parameter greater than
>> sleep_time (at least two times) and try again. If it does not work I
>> will send you a version of the module with more debug messages to track
>> what happens there.
>>
>> Thanks,
>> Daniel
>>
>> Igor Boguslavsky wrote:
>>
>> > Daniel,
>> >
>> >     Thanks a lot for getting back with me on this - I did grab the
>> > latest snapshot and it fixed the problem COMPLETELY! No more duplicate
>> > processes, and the gateway actually works. Now, I've managed to set
>> > the config file up so I can see presence in both directions (from
>> > WMessenger side, as well as Jabber) and I can send messages from WM ->
>> > Jabber just fine, but not in the opposite direction! I'm attaching the
>> > config below (as well as some errors I see in the logs while sending
>> > messages). I would greatly appreciate your help with this.
>> >
>> >     You guys are doing an amazing job,
>> >     Igor
>> >
>> >
>> > error log while sending messages Jabber -> WM:
>> >
>> > 0(9428) XJAB:xj_worker:9441: something is coming
>> >  0(9428) XJAB:xj_worker:9441: checking socket <8> ...
>> >  0(9428) XJAB:xj_worker:9441: received: 174bytes Err:0/EA:11
>> >  0(9428) XJAB: xj_jcon_update [sip:igorb@piias12.ms.com] 200
>> >  0(9428) XJAB:xj_worker: JMSG START ----------
>> > <message to='igorb@sait661/serXjab' from='igorb@jamny1/Office' id='5'
>> > type='chat'><body>%%composing reply</body><x
>> > xmlns='jabber:x:event'><id>0</id><composing/></x></message>
>> >  JABBER: JMSGL:174 END ----------
>> >  0(9428) XJAB:xj_parse_jab: XODE ret:0 pos:174
>> >  0(9428) XJAB:xj_manage_jab: jabber [message] received
>> >  0(9428) XJAB:xj_address_translation:9441: - checking aliases
>> >  0(9428) XJAB:xj_address_translation:9441: - domain is [jamny1/Office]
>> >  0(9428) XJAB:xj_address_translation:9441: - doing address correction
>> >  0(9428) XJAB:xj_manage_jab: ERROR SIP MESSAGE was not sent ...
>> >  0(9428) XJAB:xj_worker:9441: msgs from socket <8> parsed ...
>> >
>> > 0(9428) XJAB:xj_worker:9441: something is coming
>> >  0(9428) XJAB:xj_worker:9441: checking socket <8> ...
>> >  0(9428) XJAB:xj_worker:9441: received: 107bytes Err:0/EA:11
>> >  0(9428) XJAB: xj_jcon_update [sip:igorb@piias12.ms.com] 200
>> >  0(9428) XJAB:xj_worker: JMSG START ----------
>> > <message to='igorb@sait661/serXjab' from='igorb@jamny1/Office' id='6'
>> > type='chat'><body>df</body></message>
>> >  JABBER: JMSGL:107 END ----------
>> >  0(9428) XJAB:xj_parse_jab: XODE ret:0 pos:107
>> >  0(9428) XJAB:xj_manage_jab: jabber [message] received
>> >  0(9428) XJAB:xj_address_translation:9441: - checking aliases
>> >  0(9428) XJAB:xj_address_translation:9441: - domain is [jamny1/Office]
>> >  0(9428) XJAB:xj_address_translation:9441: - doing address correction
>> >  0(9428) XJAB:xj_manage_jab: ERROR SIP MESSAGE was not sent ...
>> >  0(9428) XJAB:xj_worker:9441: msgs from socket <8> parsed ...
>> >
>> >
>> >
>> >
>> > Daniel-Constantin Mierla wrote:
>> >
>> >> Hello,
>> >> do you still have the problem with the latest CVS?
>> >>
>> >> Best regards,
>> >> Daniel
>> >>
>> >> Daniel-Constantin Mierla wrote:
>> >>
>> >> > Hello,
>> >> > please take the last CVS version (stable branch) and try again.
>> I am
>> >> > traveling now, I will be back in office next week and I will check
>> >> > carefully your problem. We have been reported about this problem
>> and
>> >> > the CVS version should fix it. If not, please tell us.
>> >> >
>> >> > Best regards,
>> >> > Daniel
>> >> >
>> >> >
>> >> > Igor Boguslavsky wrote:
>> >> >
>> >> >> All,
>> >> >>
>> >> >>     I've been playing with jabber module and having problems
>> someone
>> >> >> had  mentioned here earlier: first, the number of ser processes
>> >> >> increases constantly . This is due to the fact that XJAB
>> threads seem
>> >> >> to be dying (or so waitpid() code thinks in jabber.c), and keeps
>> >> >> spawning more threads. The proble is that ser threads are still
>> >> >> around when that happens, contributing to a number of processes.
>> >> >>
>> >> >>     Second, and most troubling, is that jabber module doesn't even
>> >> >> try to connect to jabber server (conformed by running ngrep and
>> >> >> tcpdump on a jabber box, which runs on a separate box). This
>> may or
>> >> >> may not be due to the error described above (any chance that
>> jabber
>> >> >> threads that are supposed to connect are not around anymore?).
>> I even
>> >> >> tried disabling TCP and recompiling (commented -DUSE_TCP in
>> >> >> Makefile.def)
>> >> >>
>> >> >>     The rest of ser functionality is fine. I can log in tp the
>> server
>> >> >> easily, mysql gets updated acorrdingly, etc.
>> >> >>
>> >> >>     The setup: ser-0.8.11pre29 on Linux 2.4.9 (host name piias12),
>> >> >> compiled with gcc 3.2.2. Jabber runs on a server "sait661".
>> >> >>
>> >> >>     The jusers looks like this:
>> >> >>
>> >> >> mysql>  select * from jusers;
>> >> >> +------+--------+------------+----------------------+------+
>> >> >> | juid | jab_id | jab_passwd | sip_id               | type |
>> >> >> +------+--------+------------+----------------------+------+
>> >> >> |    1 | igorb  | ***        | igorb@piias12.ms.com |    0 |
>> >> >> +------+--------+------------+----------------------+------+
>> >> >> 1 row in set (0.00 sec)
>> >> >>
>> >> >>
>> >> >> =================== ser.conf: (Experimental; just to illustrate
>> >> >> Jabber login)
>> ======================================================
>> >> >> #
>> >> >> # $Id: ser.cfg,v 1.20 2003/05/31 21:12:19 jiri Exp $
>> >> >> #
>> >> >> # simple quick-start config script
>> >> >> #
>> >> >>
>> >> >> # ----------- global configuration parameters
>> >> ------------------------
>> >> >>
>> >> >>
>> >> >> debug=3         # debug level (cmd line: -dddddddddd)
>> >> >> fork=yes
>> >> >> log_stderror=no # (cmd line: -E)
>> >> >>
>> >> >> # Uncomment these lines to enter debugging mode
>> >> >> /*
>> >> >> debug=7
>> >> >> fork=no
>> >> >> log_stderror=yes
>> >> >> */
>> >> >>
>> >> >> check_via=no    # (cmd. line: -v)
>> >> >> dns=no           # (cmd. line: -r)
>> >> >> rev_dns=no      # (cmd. line: -R)
>> >> >> port=5060
>> >> >> children=4
>> >> >> fifo="/tmp/ser_fifo"
>> >> >>
>> >> >> # ------------------ module loading
>> >> ----------------------------------
>> >> >>
>> >> >> # Uncomment this if you want to use SQL database
>> >> >> loadmodule "/var/ser/lib/ser/modules/mysql.so"
>> >> >>
>> >> >> loadmodule "/var/ser/lib/ser/modules/sl.so"
>> >> >> loadmodule "/var/ser/lib/ser/modules/tm.so"
>> >> >> loadmodule "/var/ser/lib/ser/modules/rr.so"
>> >> >> loadmodule "/var/ser/lib/ser/modules/maxfwd.so"
>> >> >> loadmodule "/var/ser/lib/ser/modules/usrloc.so"
>> >> >> loadmodule "/var/ser/lib/ser/modules/registrar.so"
>> >> >>
>> >> >> # Uncomment this if you want digest authentication
>> >> >> # mysql.so must be loaded !
>> >> >> loadmodule "/var/ser/lib/ser/modules/auth.so"
>> >> >> loadmodule "/var/ser/lib/ser/modules/auth_db.so"
>> >> >>
>> >> >> ######## JABBER <-> SIMPLE
>> >> >> loadmodule "/var/ser/lib/ser/modules/print.so"
>> >> >> loadmodule "/var/ser/lib/ser/modules/textops.so"
>> >> >> loadmodule "/var/ser/lib/ser/modules/jabber.so"
>> >> >> loadmodule "/var/ser/lib/ser/modules/pa.so"
>> >> >>
>> >> >> modparam("jabber","db_url","sql://ser:heslo@127.0.0.1/sip_jab")
>> >> >> modparam("jabber","jaddress","sait661.ms.com")
>> >> >> modparam("jabber","jport",5222)
>> >> >> modparam("jabber","workers",2)
>> >> >> modparam("jabber","max_jobs",2)
>> >> >> modparam("jabber","aliases","1;yahoo.sait661;")
>> >> >> modparam("jabber","jdomain","sait661")
>> >> >> modparam("jabber","delay_time",5)
>> >> >> modparam("jabber","cache_time",200)
>> >> >> modparam("jabber","sleep_time",60)
>> >> >> modparam("jabber","check_time",60)
>> >> >> ################
>> >> >> # ----------------- setting module-specific parameters
>> >> ---------------
>> >> >>
>> >> >> # -- usrloc params --
>> >> >>
>> >> >> # modparam("usrloc", "db_mode",   0)
>> >> >>
>> >> >> # Uncomment this if you want to use SQL database
>> >> >> # for persistent storage and comment the previous line
>> >> >> modparam("usrloc", "db_mode", 2)
>> >> >>
>> >> >> # -- auth params --
>> >> >> # Uncomment if you are using auth module
>> >> >> #
>> >> >> modparam("auth_db", "calculate_ha1", yes)
>> >> >> #
>> >> >> # If you set "calculate_ha1" parameter to yes (which true in this
>> >> >> config),
>> >> >> # uncomment also the following parameter)
>> >> >> #
>> >> >> modparam("auth_db", "password_column", "password")
>> >> >>
>> >> >> # -------------------------  request routing logic
>> >> -------------------
>> >> >> alias="ms.com"
>> >> >> alias="piias12.ms.com"
>> >> >>
>> >> >> # main routing logic
>> >> >>
>> >> >> route{
>> >> >>
>> >> >>         # initial sanity checks -- messages with
>> >> >>         # max_forwards==0, or excessively long requests
>> >> >>         if (!mf_process_maxfwd_header("10")) {
>> >> >>                 sl_send_reply("483","Too Many Hops");
>> >> >>                 break;
>> >> >>         };
>> >> >>         if (len_gt( max_len )) {
>> >> >>                 sl_send_reply("513", "Message too big");
>> >> >>                 break;
>> >> >>         };
>> >> >>
>> >> >>         # we record-route all messages -- to make sure that
>> >> >>         # subsequent messages will go through our proxy; that's
>> >> >>         # particularly good if upstream and downstream entities
>> >> >>         # use different transport protocol
>> >> >>         record_route();
>> >> >>         # loose-route processing
>> >> >>         if (loose_route()) {
>> >> >>                 t_relay();
>> >> >>                 break;
>> >> >>         };
>> >> >>
>> >> >>         # if the request is for other domain use UsrLoc
>> >> >>         # (in case, it does not work, use the following command
>> >> >>         # with proper names and addresses in it)
>> >> >>         if (uri==myself) {
>> >> >>
>> >> >>                 if (method=="REGISTER") {
>> >> >>
>> >> >>                    if (!www_authorize("piias12.ms.com",
>> >> "subscriber")) {
>> >> >>                         www_challenge("piias12.ms.com", "0");
>> >> >>                         break;
>> >> >>                    };
>> >> >>
>> >> >>                 save("location");
>> >> >>
>> >> >>                    log (1, "Are we registering?");
>> >> >>                    if(search("egistration")) {
>> >> >>
>> >> >>                      log (1, "XJAB: Going ONline in Jabber
>> >> >> network!!!\n");
>> >> >>
>> >> >>                      if (jab_go_online()) {
>> >> >>                        sl_send_reply("200", "Accepted");
>> >> >>                      }
>> >> >>                      else {
>> >> >>                        sl_send_reply("404","Not found");
>> >> >>                      };
>> >> >>                    };
>> >> >>
>> >> >>                    break;
>> >> >>                 };
>> >> >>
>> >> >>
>> >> >>                 # native SIP destinations are handled using our
>> >> >> USRLOC DB
>> >> >>                 if (!lookup("location")) {
>> >> >>                         sl_send_reply("404", "Not Found");
>> >> >>                         break;
>> >> >>                 };
>> >> >>         };
>> >> >>         # forward to current uri now; use stateful forwarding;
>> that
>> >> >>         # works reliably even if we forward from TCP to UDP
>> >> >>         if (!t_relay()) {
>> >> >>                 sl_reply_error();
>> >> >>         };
>> >> >>
>> >> >> }
>> >> >>
>> >> >> ========== Relevant portions of daemon.log
>> >> >> ===============================================================
>> >> >> Jul  9 15:20:11 piias12 ./ser[23832]: XJAB:xjab_check_workers:
>> >> >> worker[0][pid=23965] has exited - status=0 err=-1 errno=10
>> >> >> Jul  9 15:20:11 piias12 ./ser[23832]: XJAB:xjab_check_workers:
>> >> >> worker[1][pid=23966] has exited - status=0 err=-1 errno=10
>> >> >> Jul  9 15:20:11 piias12 ./ser[23851]: XJAB:xjab_check_workers:
>> >> >> worker[0][pid=23975] has exited - status=0 err=-1 errno=10
>> >> >> Jul  9 15:20:11 piias12 ./ser[23851]: XJAB:xjab_check_workers:
>> >> >> worker[1][pid=23976] has exited - status=0 err=-1 errno=10
>> >> >> Jul  9 15:20:51 piias12 ./ser[23829]: Are we registering?
>> >> >> Jul  9 15:20:51 piias12 ./ser[23829]: XJAB: Going ONline in Jabber
>> >> >> network!!!
>> >> >> Jul  9 15:21:11 piias12 ./ser[23832]: XJAB:xjab_check_workers:
>> >> >> worker[0][pid=23977] has exited - status=0 err=-1 errno=10
>> >> >>
>> >> >>
>> >> >>
>> >> >>
>> >> >> --
>> >> >> NOTICE: If received in error, please destroy and notify sender.
>> >> >> Sender does not waive confidentiality or privilege, and use is
>> >> >> prohibited.
>> >> >>
>> >> >>
>> >> >>
>> >> >>
>> >>
>> ------------------------------------------------------------------------
>> >> >>
>> >> >> _______________________________________________
>> >> >> Serusers mailing list
>> >> >> serusers@lists.iptel.org
>> >> >> http://lists.iptel.org/mailman/listinfo/serusers
>> >> >>
>> >> >>
>> >> >
>> >> > _______________________________________________
>> >> > Serusers mailing list
>> >> > serusers@lists.iptel.org
>> >> > http://lists.iptel.org/mailman/listinfo/serusers
>> >> >
>> >>
>> > --
>> > NOTICE: If received in error, please destroy and notify sender.
>> > Sender does not waive confidentiality or privilege, and use is
>> > prohibited.
>> >
>> >
>> >------------------------------------------------------------------------
>>
>> >
>> >_______________________________________________
>> >Serusers mailing list
>> >serusers@lists.iptel.org
>> >http://lists.iptel.org/mailman/listinfo/serusers
>> >
>> >
>>
> --
> NOTICE: If received in error, please destroy and notify sender.
> Sender does not waive confidentiality or privilege, and use is
> prohibited.
>
>
>------------------------------------------------------------------------
>
>_______________________________________________
>Serusers mailing list
>serusers@lists.iptel.org
>http://lists.iptel.org/mailman/listinfo/serusers
>
>

--
NOTICE: If received in error, please destroy and notify sender.  Sender does not waive confidentiality or privilege, and use is prohibited.