Messages stuck in the queue (continued from "concat messages proble...

Messages stuck in the queue (continued from "concat messages proble... SearchSearch
Author Message
ashot shahbazian
New member
Username: Animatele

Post Number: 20
Registered: 06-2004
Posted on Thursday, July 09, 2009 - 05:01 am:   

Hi Bryce,

Just noticed 11 .req files hanging in the \q folder, two are with one retry attempt, this one is almost 12 hours old:

[SMS]
SubmittedBy=127.0.0.1
SubmitUser=xxxxxx
Sender=+xxxxxxxxx
PhoneNumber=+xxxxxxxxx
Data=Tati te amo estas son la mejor manana k he tenido
pid=00
dcs=00
Binary=0
ReceiptRequested=Yes
[ErrorDetail]
RetryCount=1
LastRetryTime=20090708193205
LastErrorInfo=ERROR: Timeout waiting for response from server or lost connection -- SMPP - pecur1_com:xxxxx

Time at the server now is 07:06, July 9th.

The second was dated 19:32, one minute later than this one, and it had no indication of a retry.

The pecur1_com uplink is fine, accepting messages:

2009-07-09 07:08:32,755CB769.req,127.0.0.1,+xxxxxxxx,OK -- SMPP - pecur1_com:xxxxx,SubmitUser=xxxxxx;Sender=+xxxxxxxxx;SMSCMsgId=298837635;Text="M i amorcito.ahora mismo te pase tu correo.estoy ahora haciendo peliculas.cuanto necesito un masajito tuyo.te amo mucho.te mando un besote grande.eres mi chochua"

The SMSC upstream was stopped for a couple of minutes for a route refresh and started at about the time of the retry attempt. The way it stops for refresh is not by sending an unbind command and disconnecting but ceasing to respond to SMPP commands while keeping the sockets open. Most of the 7000 or so messages accumulated in the queue during the stop submitted momentarily, but two got stuck.

I know this must be tough to recreate, but if you want me to activate tracing my hands are tied - this is a production system we can't do debugs on.

The version is 2009.07.04, separate user queues deactivated, the message itself is just like thousands sending to the same uplink, which has no restrictions for the user or the destination.

Interestingly, 9 of those 11 stuck files have a last file change of exactly 00:00. One has
1 retry attempt:

[ErrorDetail]
RetryCount=1
LastRetryTime=20090709000154
LastErrorInfo=ERROR: Timeout waiting for response from server or lost connection -- SMPP - pecur1_com:xxxxx

The others don't, they're just normal .req files. All files are locked and are impossible to remove or change.

Two of those dated 00:00 are delivery receipts (don't ask me how they got in the queue)

SubmittedBy=127.0.0.1
SubmitUser=xxxxxxx
Sender=+xxxxxxx
PhoneNumber=+xxxxxxx
Data=id:0232156741 sub:001 dlvrd:001 submit date:0907081500 done date:0907081200 stat:EXPIRED err:000 text:
pid=00
dcs=00
Binary=0
ReceiptFailed=Yes
ReceiptMessageId=0DD66E45

I've now stopped the server and:
- deleted the DLR-s
- Deleted the [ErrorDetail] and what's below from one of the files and saved it.

Started the service - all stuck messages are gone immediately.

Hope you know what to look for..

Kind regards,
Ashot
Alex Kaiser
New member
Username: Alex_k

Post Number: 27
Registered: 07-2006
Posted on Thursday, July 09, 2009 - 07:34 am:   

Hello,

We noticed the same problem in new NowSMS releases, message got stuck in the queue and freezes all sending. But seems it happen not only with concat messages.

Regards,
Alex K.
Des - NowSMS Support
Board Administrator
Username: Desosms

Post Number: 1011
Registered: 08-2008
Posted on Thursday, July 09, 2009 - 05:04 pm:   

Hi Ashot & Alex,

You're correct. There is a problem if an SMPP connection with async mode enabled drops unexpectedly. If this happens, then there is a good chance that one message (per connection) will get stuck in the queue until the NowSMS service is restarted.

This bug was introduced some time between the Feb 2008 and June 2008 releases.

It was a very quick fix. Additional code that was added to more quickly detect dropped connections was not processing the connection error correctly.

I've uploaded a 2009.07.09 update, and made that the primary download. http://www.nowsms.com/download/nowsms2009rc.zip will also return this version.

--
Des
NowSMS Support
ashot shahbazian
New member
Username: Animatele

Post Number: 23
Registered: 06-2004
Posted on Friday, July 10, 2009 - 02:30 am:   

Hi Bryce,

Updated, will check tomorrow if any files get stuck.

Kind regards,
Ashot
ashot shahbazian
New member
Username: Animatele

Post Number: 27
Registered: 06-2004
Posted on Saturday, July 11, 2009 - 08:47 pm:   

The problem is gone, thanks bunch for a wonderful job!

Kind regards,
Ashot
Abhit Nigam
New member
Username: Abhitnigam

Post Number: 1
Registered: 08-2009
Posted on Tuesday, August 18, 2009 - 08:53 am:   

Hi all,
I also using NowSMS for invoking a web application with the information came via sms to the application.My application was running good but after 1 day it got stuck,message can't receive by nowsms because of that my application can't call. I just want to ask you that is it is the same problem as you discussed above or anything else.
whether it is a fault from application side(but I checked on system service configuration, all services are running.)or it is because of nowsms version problem. Please let me know....Thanks }
Des - NowSMS Support
Board Administrator
Username: Desosms

Post Number: 1152
Registered: 08-2008
Posted on Tuesday, August 18, 2009 - 01:28 pm:   

Hi,

The problem you describe does not sound related. It was an issue where one or more outbound messages could get stuck if an async mode SMPP connection was terminated unexpectedly. (Other messages would be processed, but some would get stuck.)

Tell me more about your configuration ... what type of SMSC connection?

What version of NowSMS?

If you restart the NowSMS service, do things become unstuck?

Do you see any errors displayed anywhere?

Enable the SMSDEBUG.LOG (checkbox on the "Serial #" page of the configuration dialog), and if a problem occurs again, perhaps we can learn more about your situation from this log file.

--
Des
NowSMS Support