For some time I have been fighting a queuing and locking up problem with
Kannel.  Today, I found something of interest that has helped a little in
solving the problem.  The problems I have been having are that after a short
period of time, any where from 26 hrs to 1 wk, Kannel simply quits sending
messages and just queues them.

Using the store file I was able to continue sending some messages while some
stayed stuck in the store file.  Watching the sms connection log I could see
(as described in previous emails) that Kannel would continually try sending
a message that would get a Generic ERROR response from the modem.  Thanks to
Alvaro Cornejo (Thanks Alvaro), I was able to turn on the error messages and
see that I was getting an error: "+CMS ERROR: 38 ... Network out of order
(38)".

I sent this info to the manufacturer of the hardware and got back:
  "... means that a sending to an invalid number can also result in this
error."
Not very helpful, the first half of the message was sent fine so, I know the
number was correct.

After playing today, I found that the messages receiving the errors were all
(at least as far as I can see) the nth segment of a split, long message that
ended with a <CR> and/or <LF>.  If I make sure the message is trimmed of
white space the message goes through fine.  If the message is short and has
a line feed character it seems to go through just fine.  It is only when the
message is split and has a line feed character at the end that the error
occures.

Can anyone explain this?  Is having a line feed character or characters at
the end of a message that gets split a violation in SMS protocol or Kannel
protocol?

I fear that my solution of trimming the text before URL encoding will only
work as long as the message never gets split in a way that a non-first
segment never ends in a line feed character, which certainly has a
possibility of happening with a long message.  I will be testing for bad
middle segments soon, I just didn't want to count characters this morning.
The problem I see is that Kannel splits the message and I worry that the
split could leave this bad condition in a middle segment as well as the end
segment and I can't trim the middle segments.

Any help would be greatly appreciated.

Thanks,

-Tony

On Fri, Nov 7, 2008 at 11:10 AM, Alvaro Cornejo <[EMAIL PROTECTED]>wrote:

> on modem init in kannel config file
>
> On Fri, 2008-11-07 at 11:06 -0700, Tony Kirkham wrote:
> > Thank you very much for your help!
> >
> > Where do I place this AT command?  Is there a setting in Kannel's
> > config file, or do I send this command manually to the modem before
> > Kannel connects to it?
> >
> > Thanks again,
> >
> > -Tony
> >
> >
> > On Fri, Nov 7, 2008 at 10:38 AM, Alvaro Cornejo
> > <[EMAIL PROTECTED]> wrote:
> >         "ERROR"  is returned from your modem and could mean
> >         anything...
> >
> >         Enable verbose response commands
> >
> >         use AT+CMEE=1 or 2
> >
> >         and see the results
> >
> >
> >
> >
> >         On Fri, 2008-11-07 at 09:27 -0700, Tony Kirkham wrote:
> >         > I have had Kannel running for the last several months and
> >         have been
> >         > having problems with sudden queuing of messages which
> >         corrects itself
> >         > with a simple stop and start of Kannel.  However, this
> >         morning it
> >         > looks like nothing is going out regardless of restarting
> >         Kannel and
> >         > unplugging the modem.
> >         >
> >         > Here is Kannel's status and a segment from the sms
> >         connection log:
> >         >
> >         >
> >         > Kannel bearerbox version `cvs-20080613'. Build `Jun 24 2008
> >         23:13:52',
> >         > compiler `4.1.3 20070929 (prerelease) (Ubuntu
> >         4.1.2-16ubuntu2)'.
> >         > System Linux, release 2.6.24-21-generic, version #1 SMP Tue
> >         Oct 21
> >         > 23:09:30 UTC 2008, machine x86_64. Hostname message1, IP
> >         127.0.1.1.
> >         > Libxml version 2.6.30. Using native malloc.
> >         >
> >         > Status: running, uptime 0d 0h 4m 57s
> >         >
> >         > WDP: received 0 (0 queued), sent 0 (0 queued)
> >         >
> >         > SMS: received 0 (0 queued), sent 0 (0 queued), store size 6
> >         >
> >         > SMS: inbound 0.00 msg/sec, outbound 0.00 msg/sec
> >         >
> >         > DLR: 0 queued, using internal storage
> >         >
> >         > Box connections:
> >         >     smsbox:(none), IP 127.0.0.1 (0 queued), (on-line 0d 0h
> >         4m 56s)
> >         >
> >         >
> >         > SMSC connections:
> >         >     vzn00    AT2[vzn00] (online 283s, rcvd 0, sent 0, failed
> >         0, queued
> >         > 11 msgs)
> >         >
> >         > 2008-11-07 07:58:48 [6456] [6] DEBUG: AT2[vzn00]: <-- >
> >         > 2008-11-07 07:58:48 [6456] [6] DEBUG: AT2[vzn00]: send
> >         command status:
> >         > 1
> >         > 2008-11-07 07:58:48 [6456] [6] DEBUG: AT2[vzn00]: -->
> >         > 0051000A8103414046490000A74705
> >         >
> >
> 0003020202402C90B26C36839A65B6FD9D76B340CEB79C8E2ECBDDA0221EFE9ED7E5651688586EBFC7F2F0380F4ABB41C176599E1E8759A0582E276B28
> >         > 2008-11-07 07:58:48 [6456] [6] DEBUG: AT2[vzn00]: --> ^Z
> >         > 2008-11-07 07:58:52 [6456] [6] DEBUG: AT2[vzn00]: <-- >
> >         > 2008-11-07 07:58:52 [6456] [6] DEBUG: AT2[vzn00]: <-- ERROR
> >         > 2008-11-07 07:58:52 [6456] [6] ERROR: AT2[vzn00]: Generic
> >         error: ERROR
> >         > 2008-11-07 07:58:52 [6456] [6] DEBUG: AT2[vzn00]: send
> >         command status:
> >         > -1
> >         > 2008-11-07 07:58:54 [6456] [6] DEBUG: AT2[vzn00]:
> >         TP-Validity-Period:
> >         > 24.0 hours
> >         > 2008-11-07 07:58:54 [6456] [6] DEBUG: AT2[vzn00]: --> AT
> >         +CMGS=75^M
> >         > 2008-11-07 07:58:54 [6456] [6] DEBUG: AT2[vzn00]: <-- >
> >         > 2008-11-07 07:58:54 [6456] [6] DEBUG: AT2[vzn00]: send
> >         command status:
> >         > 1
> >         > 2008-11-07 07:58:54 [6456] [6] DEBUG: AT2[vzn00]: -->
> >         >
> >
> 0051000A8103414046490000A747050003020202402C90B26C36839A65B6FD9D76B340CEB79C8E2ECBDDA0221EFE9ED7E5651688586EBFC7F2F0380F4ABB41C176599E1E8759A0582E276B28
> >         > 2008-11-07 07:58:54 [6456] [6] DEBUG: AT2[vzn00]: --> ^Z
> >         > 2008-11-07 07:58:56 [6456] [6] DEBUG: AT2[vzn00]: <-- >
> >         > 2008-11-07 07:58:56 [6456] [6] DEBUG: AT2[vzn00]: <-- ERROR
> >         > 2008-11-07 07:58:56 [6456] [6] ERROR: AT2[vzn00]: Generic
> >         error: ERROR
> >         > 2008-11-07 07:58:56 [6456] [6] DEBUG: AT2[vzn00]: send
> >         command status:
> >         > -1
> >         > 2008-11-07 07:58:58 [6456] [6] DEBUG: AT2[vzn00]:
> >         TP-Validity-Period:
> >         > 24.0 hours
> >         > 2008-11-07 07:58:58 [6456] [6] DEBUG: AT2[vzn00]: --> AT
> >         +CMGS=75^M
> >         > 2008-11-07 07:58:58 [6456] [6] DEBUG: AT2[vzn00]: <-- >
> >         >
> >         > I have a plethora of questions about the real meaning of
> >         some of the
> >         > elements of the status page but, has anyone seen this
> >         behavior and
> >         > know a fix?
> >         > Is this a potential modem/SIM/network hardware problem?
> >         >
> >         > Any help would be greatly appreciated.
> >         >
> >         > Thanks,
> >         >
> >         > -Tony
> >         >
> >         >
> >         >
> >         >
> >
> >
> >
>
>

Reply via email to