Modem Stops Responding

Modem Stops Responding SearchSearch

SMS & MMS Technical Forum » NowSMS Support - SMS Issues (Product Support Only) » Archive through January 22, 2009 » Modem Stops Responding « Previous || Next »
Author Message
Bo Tanaka
Posted on Tuesday, November 11, 2008 - 04:55 pm:   

It seems that if a message hits NowSMS that has invalid data (like an improper recipient address), or if the system receives more messages than licensed, NowSMS will end up putting one or more modems into a hung state, where the modem stops responding and I have to reboot my server.

I have attempted setting up throttling, and rejecting the one error I see for the improper MDN. Here is my SMSGW.INI file:

[Inbound SMS Routing]
<account>=<modem number>
[Modem - MultiTech Systems USB GSM_GPRS Wireless Modem]
PhoneNumber=<phone numnber>
ReceiveSMS=Yes
ReceiveMMS=No
ReceiveTo=Direct
AllowPhase2Plus=No
RouteLocal=<local account>
[SMSGW]
Modem1=MultiTech Systems USB GSM_GPRS Wireless Modem
ConfigurationUpdateTriggerRestart=20081104055703
SMPPServerMaxConnectionsPerUser=20
WebAuth=No
WebMenu=Yes
WebPort=8800
SMPPPort=2323
ReceiveSMS=No
ReceiveMMS=No
ReceiveSMSCharset=utf-8
Debug=Yes
LogDirectory=c:\logs
SMSCSendLimit=3/2
SMPPThrottleErrorDelay=10
RetryDelay=60
RetryDelayAfterAttempts=1
RetryMaxAttempts=0
SMPPRejectErrorCodes=26
ModemSendWorkaround=yes
[SMPP]
SMPPServerEnquireLink=120
SMSCSendLimit=3/2


And here is what I see in my logs when I have issues:

12:51:06:593 [4] ThreadProcessModem: OUT: 0001440181F400006DAF97505ABCEA6078580C769B89CB391D350B2DF69C4F6291F91C2E8BC41DB5 2783C170B1582C468DC96A331A4DBB0B0EA9C9A7B307AD4A8FC59DF1291D167BB0DD34797406A955 69B147CDAF6E30F61A4E3BD65ECA60B8869409C3D573AFB703
12:51:09:890 [4] ThreadProcessModem: ERROR - Modem Response (2): +CMS ERROR: 38
12:51:09:890 [4] ThreadProcessModem: Error: ERROR - Modem Response (2): +CMS ERROR: 38
12:51:12:796 [4] ThreadProcessModem: Processing 490FE964.req...
12:51:12:796 [4] ThreadProcessModem: OUT: AT+CMGS=104

12:51:12:875 [4] ThreadProcessModem: IN:
>
12:51:12:875 [4] ThreadProcessModem: OUT: 0001450181F400006DAF97505ABCEA6078580C769B89CB391D350B2DF69C4F6291F91C2E8BC41DB5 2783C170B1582C468DC96A331A4DBB0B0EA9C9A7B307AD4A8FC59DF1291D167BB0DD34797406A955 69B147CDAF6E30F61A4E3BD65ECA60B8869409C3D573AFB703
12:51:13:218 [4] ThreadProcessModem: OK

12:51:13:218 [4] ThreadProcessModem: Processing 490FE965.req...
12:51:13:796 [4] ThreadProcessModem: OUT: AT+CMGS=47

12:51:13:875 [4] ThreadProcessModem: ERROR - Modem Response (1): +CME ERROR: 515
12:51:13:875 [4] ThreadProcessModem: Error: ERROR - Modem Response (1): +CME ERROR: 515
12:51:15:390 [4] ThreadProcessModem: modem test failed
12:51:16:390 [4] ThreadProcessModem: AT+CNMI=0,0
12:51:21:437 [4] ThreadProcessModem: Before ModemRelease - MultiTech Systems USB GSM_GPRS Wireless Modem
12:51:21:437 [4] ThreadProcessModem: After ModemRelease - MultiTech Systems USB GSM_GPRS Wireless Modem
12:51:27:437 [4] ThreadProcessModem: Before ModemAllocate - MultiTech Systems USB GSM_GPRS Wireless Modem
12:51:27:437 [4] ThreadProcessModem: After ModemAllocate - MultiTech Systems USB GSM_GPRS Wireless Modem - OK
12:51:27:437 [4] ThreadProcessModem: Re-initializing modem: MultiTech Systems USB GSM_GPRS Wireless Modem ...
12:51:30:109 [4] OpenDevice: Unable to initialize modem: Error 80000018 from lineGetID
12:51:30:109 [4] HammerNonResponsiveModem: Begin
12:51:30:109 [4] HammerNonResponsiveModem: Unable to access modem at COM3: -- Error 5 -- Access is denied.

12:51:30:109 [4] HammerNonResponsiveModem: Another application is already using this device.
12:51:30:109 [4] HammerNonResponsiveModem: FAILED
12:51:30:125 [4] ThreadProcessModem: Before ModemRelease - MultiTech Systems USB GSM_GPRS Wireless Modem
12:51:30:125 [4] ThreadProcessModem: After ModemRelease - MultiTech Systems USB GSM_GPRS Wireless Modem
12:51:50:125 [4] ThreadProcessModem: Before ModemAllocate - MultiTech Systems USB GSM_GPRS Wireless Modem
12:51:50:125 [4] ThreadProcessModem: After ModemAllocate - MultiTech Systems USB GSM_GPRS Wireless Modem - OK
12:51:50:125 [4] ThreadProcessModem: Re-initializing modem: MultiTech Systems USB GSM_GPRS Wireless Modem ...
12:51:52:796 [4] OpenDevice: Unable to initialize modem: Error 80000018 from lineGetID
12:51:52:796 [4] HammerNonResponsiveModem: Begin
12:51:52:796 [4] HammerNonResponsiveModem: Unable to access modem at COM3: -- Error 5 -- Access is denied.

I really need to understand how I can configure NowSMS to just reject a message if it fails to send, and to prevent the modem from going into a hung state.

Thanks
Des - NowSMS Support
Board Administrator
Username: Desosms

Post Number: 238
Registered: 08-2008
Posted on Tuesday, November 11, 2008 - 05:27 pm:   

Hi Bo,

I'm not sure that we can stop this modem from going into a hung state. It's very possible that something is wrong with the modem. But maybe we can find a solution, as maybe it is a timing problem with the modem firmware going into a hung state.

The error codes are very puzzling.

The first error "+CMS ERROR: 38" indicates that there has been a network failure. And this particular code in particular indicates that the failure is not necessarily temporary ... "This cause indicates that the network is not functioning correctly and that the condition is likely to last a relatively long period of time".

After that, we seem to send a message. Do you know if that message was actually received correctly? (I'm wondering if we can trust the modem at this point.)

Then for the next message, before the modem "hangs" ... we get "+CME ERROR: 515". This code is modem specific ... but in the case of Multitech GPRS, they say it means "Please wait, init or command processing in progress."

Most references I can find for this 515 error indicate that the modem is in the process of starting up.

So it's almost like the modem firmware is crashing and it is trying to reboot.

After that, we see "modem test failed", which basically means that NowSMS couldn't get a response to a simple AT command. The modem is hung.

At this point, we drop the connection and try to re-init. But that's obviously not working.

How could NowSMS prevent this? Or recover from it?

I don't know.

What version of NowSMS are you currently running?

We made some changes in the 2008.08.22 release to add some additional logic after a failed message send to try to recover from a modem that got confused during the message send attempt. And some additional logic is attempted before we report "modem test failed".

Maybe that will make a difference? (Download http://www.nowsms.com/download/nowsmsupdate.zip.)

Is this scenario readily reproducible?

I really think that something is wrong with the modem, but if we can find a way to avoid the problem, we will try.

As a starting point try that update.

--
Des
NowSMS Support
Des - NowSMS Support
Board Administrator
Username: Desosms

Post Number: 239
Registered: 08-2008
Posted on Tuesday, November 11, 2008 - 05:29 pm:   

P.S. - Get rid of that "ModemSendWorkaround=yes" setting.

That setting addresses a particular bug in the Multitech CDMA modem.

However, using that setting with other modems could cause a timing problem for the modem, since when this setting is in place NowSMS does not wait for a modem response that is defined in the specification.
Des - NowSMS Support
Board Administrator
Username: Desosms

Post Number: 254
Registered: 08-2008
Posted on Monday, November 24, 2008 - 09:39 pm:   

Follow-up ...

It may or may not be related, but we found an issue with another modem where NowSMS was sending data faster than the modem driver allowed. This was causing the modem driver to hang. (A properly implemented modem driver should return an error instead, but this didn't seem to be happening.)

There is an updated version of NowSMS avaialble at http://www.nowsms.com/download/nowsms20081124.zip. I would be very curious to hear if this improves your modem reliability.

--
Des
NowSMS Support
Bo Tanaka
New member
Username: Bo_tanaka

Post Number: 2
Registered: 08-2007
Posted on Tuesday, December 30, 2008 - 11:48 pm:   

I have installed the 20081124 patch.

I will let you know how it goes.

Thanks!

Login Login / Register Logout Logout Search Last 30 Days Topics Topics