Kannel queue growing though TPS not exceeded

2013-07-30 Thread Oladeji Oladeji
Kannel bearerbox version `1.4.3'. Build `Mar 27 2013 08:45:56', compiler `4.4.7 
20120313 (Red Hat 4.4.7-3)'. System Linux, release 2.6.32-279.14.1.el6.x86_64, 
version #1 SMP Tue Nov 6 23:43:09 UTC 2012, machine x86_64. Hostname 
mobilise.kannel01, IP 192.168.2.140. Libxml version 2.7.6. Compiled with MySQL 
5.1.66, using MySQL 5.1.66. Using SQLite 3.6.20. Using native malloc.

Status: running, uptime 7d 6h 39m 37s

WDP: received 0 (0 queued), sent 0 (0 queued)

SMS: received 7449523 (0 queued), sent 5920323 (224 queued), store size -1

SMS: inbound (9.07,9.69,11.85) msg/sec, outbound (20.72,20.33,9.42) msg/sec

DLR: 122538 queued, using mysql storage

Box connections:
smsbox:(none), IP 127.0.0.1 (0 queued), (on-line 7d 6h 39m 37s) 

SMSC connections:
smsc-moSMPP:1/5020:yyy:'VMA' (online 10061s, rcvd 4021039, sent 
5835872, failed 431745, queued 13602 msgs)
smsc-mt   SMPP:2xxx/5020:yyy:'VMA' (online 10062s, rcvd 169235, sent 84451, 
failed 2836, queued 0 msgs)



Per the kannel status page above, I have 2 SMSC connections directly to 
operator. Connection1 (smsc-mo for broadcast messages) is configured for a 
throughput per  second (TPS) of 70 by operator, Connection 2 (smsc-mt  for 
Charging MT), TPS of 60. The kannel config file is pasted below: 

I have 2 questions:

1. As observed above I am only sending only 20 msg per second, yet the BB  
queue for smsc-mo has started to build up. It only goes down after if I reduce 
the sending rate from the application or stop sending for  a while.   The 
operator insists I have 70 TPS. If this true, what settings in my kannel 
configuration file may be causing BB queue to grow, even when I am no where 
close the TPS configured by the operator. Asked differently, what settings can 
I change to improve the performance and reach the capacity configured for the 
connection without getting queue build up.

2. Smsc-mt is used for MT billing. It appears the only SMS that are delivered 
to phones which have sufficient airtime balance are counted as sent in kannel's 
counter. The outbound sending rate also does not reflect The traffic on the 
Smsc-mt connection. I expect all messages that leave kannel Via that connection 
to counted as part of the statistics but is clearly not the case. Is this a 
kannel bug?



Thanks

Banji



Below is my kannel.conf file.

#--- mysql connection

group = mysql-connection

id = mydlr

host = localhost

username =xxx

password = xxx

database = xxx

max-connections = 1



# DLR table structure

group = dlr-db

id = mydlr

table = dlr

field-smsc = smsc

field-timestamp = ts

field-destination = destination

field-source = source

field-service = service

field-url = url

field-mask = mask

field-status = status

field-boxc-id = boxc



# Default kannel configuration file

group = core

admin-port = 

admin-password = 

status-password = 

admin-deny-ip = *.*.*.*

admin-allow-ip = 127.0.0.1

smsbox-port = 13013

#wapbox-port = 13002

#box-deny-ip = *.*.*.*

box-allow-ip = 127.0.0.1

wdp-interface-name = *

log-file = /var/log/kannel/bearerbox.log

access-log = /var/log/kannel/access.log

log-level = 0

dlr-storage = mysql

sms-resend-retry = 0

#group = wapbox

#bearerbox-host = localhost



# Configuring the smsBox

group = smsbox

log-file = /var/log/kannel/smsbox.log

log-level = 0

bearerbox-host = 127.0.0.1

sendsms-port =  6013

global-sender = 6013





group = sendsms-user

username = xxx

password = yyy

#forced-smsc = smsc-mo

#default-smsc = smsc-mo

dlr-url=xxx?dlr=%ddest=%preport=%A









# This is connection to smpp simulater

group = smsc

smsc = smpp

smsc-id = smsc-mo

allowed-smsc-id = smsc-mo

#denied-smsc-id = smsc-mt

host = a.b.c.d

port = 5020

receive-port = 5020

smsc-username = xxx

smsc-password = yyy

system-type = 'VMA'

service-type = 'test'

log-file = /var/log/kannel/smpp.log

log-level = 0

interface-version = 34

address-range = ''

msg-id-type = 0

throughput = 45

max-pending-submits = 40

wait-ack = 600



# This is connection to smpp simulater

group = smsc

smsc = smpp

smsc-id = smsc-mt

allowed-smsc-id = smsc-mt

host =  a.b.c.d

port = 5020

receive-port = 5020

smsc-username = xxx

smsc-password = yyy

system-type = 'VMA'

service-type = 'test'

log-file = /var/log/kannel/smpp.log

log-level = 0

interface-version = 34

address-range = ''

msg-id-type = 0

throughput = 45

max-pending-submits = 40

wait-ack = 600

Re: Kannel queue growing though TPS not exceeded

2013-07-30 Thread spameden
Hi

2013/7/30 Oladeji Oladeji olad...@gmail.com

 Kannel bearerbox version `1.4.3'. Build `Mar 27 2013 08:45:56', compiler
 `4.4.7 20120313 (Red Hat 4.4.7-3)'. System Linux, release
 2.6.32-279.14.1.el6.x86_64, version #1 SMP Tue Nov 6 23:43:09 UTC 2012,
 machine x86_64. Hostname mobilise.kannel01, IP 192.168.2.140. Libxml
 version 2.7.6. Compiled with MySQL 5.1.66, using MySQL 5.1.66. Using SQLite
 3.6.20. Using native malloc.

 Status: running, uptime 7d 6h 39m 37s

 WDP: received 0 (0 queued), sent 0 (0 queued)

 SMS: received 7449523 (0 queued), sent 5920323 (224 queued), store size -1

 SMS: inbound (9.07,9.69,11.85) msg/sec, outbound (20.72,20.33,9.42)
 msg/sec

 DLR: 122538 queued, using mysql storage

 Box connections:
 smsbox:(none), IP 127.0.0.1 (0 queued), (on-line 7d 6h 39m 37s)

 SMSC connections:
 *smsc-mo*SMPP:1/5020:yyy:'VMA' (online 10061s, rcvd 4021039,
 sent 5835872, failed 431745, queued 13602 msgs)
 *smsc-mt*   SMPP:2xxx/5020:yyy:'VMA' (online 10062s, rcvd 169235,
 sent 84451, failed 2836, queued 0 msgs)


 Per the kannel status page above, I have 2 SMSC connections directly to
 operator. Connection1 (*smsc-mo *for broadcast messages) is configured
 for a throughput per  second (TPS) of 70 by operator, Connection 2 (*
 smsc-mt*  for Charging MT), TPS of 60. The kannel config file is pasted
 below:

 I have 2 questions:

 1. As observed above I am only sending only 20 msg per second, yet the BB
  queue for smsc-mo has started to build up. It only goes down after if I
 reduce the sending rate from the application or stop sending for  a while.
   The operator insists I have 70 TPS. If this true, what settings in my
 kannel configuration file may be causing BB queue to grow, even when I am
 no where close the TPS configured by the operator. Asked differently, what
 settings can I change to improve the performance and reach the capacity
 configured for the connection without getting queue build up.


kannel's web interface reports speed incorrectly in most cases if you're
not checking whilst sending happens (first number means speed for last 5
minutes if i'm not mistaken, last is overall speed).

you can check speed via grep'ing / awk'ing your smsc log.

as I can see you've already tweaked max-pending-submit as well as wait-ack
thing.

do you see any throttling errors at all in your smsc log?

you can also measure speed by sniffing your network interface and counting
submit_sm per second in any sniffer (ethershark, ettercap, etc).

from the page you've sent I can see you're using smsbox only, do you use
DLR reports at all? try sending test batch of MT without DLR reports and
see if speed improves.

2. Smsc-mt is used for MT billing. It appears the only SMS that are
 delivered to phones which have sufficient airtime balance are counted as
 sent in kannel's counter. The outbound sending rate also does not reflect
 The traffic on the Smsc-mt connection. I expect all messages that leave
 kannel Via that connection to counted as part of the statistics but is
 clearly not the case. Is this a kannel bug?


  I don't get what you mean here. Kannel's counter reflects all sms sent
through it even if they are not delivered to the phone. Kannel just reports
what sent/received to/from the upstream SMSC providers.

also

port = 5020

receive-port = 5020

you can replace with:

port = 5020

transceiver-mode = 1

 Thanks

 Banji


 Below is my kannel.conf file.

 #--- mysql connection

 group = mysql-connection

 id = mydlr

 host = localhost

 username =xxx

 password = xxx

 database = xxx

 max-connections = 1


 # DLR table structure

 group = dlr-db

 id = mydlr

 table = dlr

 field-smsc = smsc

 field-timestamp = ts

 field-destination = destination

 field-source = source

 field-service = service

 field-url = url

 field-mask = mask

 field-status = status

 field-boxc-id = boxc


 # Default kannel configuration file

 group = core

 admin-port = 

 admin-password = 

 status-password = 

 admin-deny-ip = *.*.*.*

 admin-allow-ip = 127.0.0.1

 smsbox-port = 13013

 #wapbox-port = 13002

 #box-deny-ip = *.*.*.*

 box-allow-ip = 127.0.0.1

 wdp-interface-name = *

 log-file = /var/log/kannel/bearerbox.log

 access-log = /var/log/kannel/access.log

 log-level = 0

 dlr-storage = mysql

 sms-resend-retry = 0

 #group = wapbox

 #bearerbox-host = localhost


 # Configuring the smsBox

 group = smsbox

 log-file = /var/log/kannel/smsbox.log

 log-level = 0

 bearerbox-host = 127.0.0.1

 sendsms-port =  6013

 global-sender = 6013



 group = sendsms-user

 username = xxx

 password = yyy

 #forced-smsc = smsc-mo

 #default-smsc = smsc-mo

 dlr-url=xxx?dlr=%ddest=%preport=%A





 # This is connection to smpp simulater

 group = smsc

 smsc = smpp

 smsc-id = smsc-mo

 allowed-smsc-id = smsc-mo

 #denied-smsc-id = smsc-mt

 host = a.b.c.d

 port = 5020

 receive-port = 5020

 smsc-username = xxx

 smsc-password = yyy

 system-type = 'VMA'

 service-type = 'test'


Does the introduction of Plivo Framework make Kannel obsolete?

2013-07-30 Thread Alexander Suraphel
I was wondering whether people are flocking to Plivo. What does Kannel
offer that Plivo open source framework doesn't?


unsubscribe

2013-07-30 Thread Teodor Arteni
unsubscribe



Re: Does the introduction of Plivo Framework make Kannel obsolete?

2013-07-30 Thread spameden
tbh I hate cloud word.

I've just checked code on github to me it seems like some python app to
send sms/voice/etc through their cloud platform?

I don't think it's better than kannel.

Also for voice calls I'd prefer asterisk.


2013/7/30 Alexander Suraphel alexsurap...@gmail.com

 I was wondering whether people are flocking to Plivo. What does Kannel
 offer that Plivo open source framework doesn't?



Re: unsubscribe

2013-07-30 Thread voukaman
I want to unsubscribe fro the list i have done it several times and i am 
still receiving emails from the list.

Can the admin please fix that?

On 07/30/2013 03:48 PM, Teodor Arteni wrote:


**unsubscribe**





Re: unsubscribe

2013-07-30 Thread spameden
Similarly, to *unsubscribe*, send e-mail to
*listname*-request@kannel.orgfrom the address you are subscribed, with
the subject or body text
*unsubscribe*; or to *listname*-requ...@kannel.org with the text *unsubscribe
address=your-address* if you want to unsubscribe some other address.
Unsubscriptions are also handled automatically and need to be confirmed.
Alternatively, you can use the Mailman web
interfacehttp://www.kannel.org/mailman/listinfo/to subscribe and
unsubscribe.


2013/7/30 voukaman vouka...@hotmail.com

  I want to unsubscribe fro the list i  have done it several times and i
 am still receiving emails from the list.
 Can the admin please fix that?

 On 07/30/2013 03:48 PM, Teodor Arteni wrote:

  *unsubscribe*





Re: Kannel queue growing though TPS not exceeded

2013-07-30 Thread oladeji
Please see my responses inline highlighted in yellow. Would appreciate your
feedback. Thanks for your help.

On Tue, Jul 30, 2013 at 9:33 AM, spameden spame...@gmail.com wrote:

 Hi

 2013/7/30 Oladeji Oladeji olad...@gmail.com

 Kannel bearerbox version `1.4.3'. Build `Mar 27 2013 08:45:56', compiler
 `4.4.7 20120313 (Red Hat 4.4.7-3)'. System Linux, release
 2.6.32-279.14.1.el6.x86_64, version #1 SMP Tue Nov 6 23:43:09 UTC 2012,
 machine x86_64. Hostname mobilise.kannel01, IP 192.168.2.140. Libxml
 version 2.7.6. Compiled with MySQL 5.1.66, using MySQL 5.1.66. Using SQLite
 3.6.20. Using native malloc.

 Status: running, uptime 7d 6h 39m 37s

 WDP: received 0 (0 queued), sent 0 (0 queued)

 SMS: received 7449523 (0 queued), sent 5920323 (224 queued), store size
 -1

 SMS: inbound (9.07,9.69,11.85) msg/sec, outbound (20.72,20.33,9.42)
 msg/sec

 DLR: 122538 queued, using mysql storage

 Box connections:
 smsbox:(none), IP 127.0.0.1 (0 queued), (on-line 7d 6h 39m 37s)

 SMSC connections:
 *smsc-mo*SMPP:1/5020:yyy:'VMA' (online 10061s, rcvd 4021039,
 sent 5835872, failed 431745, queued 13602 msgs)
 *smsc-mt*   SMPP:2xxx/5020:yyy:'VMA' (online 10062s, rcvd 169235,
 sent 84451, failed 2836, queued 0 msgs)


 Per the kannel status page above, I have 2 SMSC connections directly to
 operator. Connection1 (*smsc-mo *for broadcast messages) is configured
 for a throughput per  second (TPS) of 70 by operator, Connection 2 (*
 smsc-mt*  for Charging MT), TPS of 60. The kannel config file is pasted
 below:

 I have 2 questions:

 1. As observed above I am only sending only 20 msg per second, yet the BB
  queue for smsc-mo has started to build up. It only goes down after if I
 reduce the sending rate from the application or stop sending for  a while.
   The operator insists I have 70 TPS. If this true, what settings in my
 kannel configuration file may be causing BB queue to grow, even when I am
 no where close the TPS configured by the operator. Asked differently, what
 settings can I change to improve the performance and reach the capacity
 configured for the connection without getting queue build up.


 kannel's web interface reports speed incorrectly in most cases if you're
 not checking whilst sending happens (first number means speed for last 5
 minutes if i'm not mistaken, last is overall speed).

 you can check speed via grep'ing / awk'ing your smsc log. ---

banji:  the rate shown on kannel status page matches the rate I see when I
grep access.log files


 as I can see you've already tweaked max-pending-submit as well as wait-ack
 thing. -

banji:  These two settings are  the ones I am not most unsure about. What
is the rule of thumb? If I want to get to 70 message per second throughput
and assuming the smsc connection can handle it, what should these
parameters be set to?


 do you see any throttling errors at all in your smsc log?

banji: No throttling error. This is what leads me to believe the problem
may not be from operator side.


 you can also measure speed by sniffing your network interface and counting
 submit_sm per second in any sniffer (ethershark, ettercap, etc).

banji: Ok will try this. Not sure why this will be different from counting
the submit_sm per second in the log file.


 from the page you've sent I can see you're using smsbox only, do you use
 DLR reports at all? try sending test batch of MT without DLR reports and
 see if speed improves.


I set dlr-mask to 1 with the understanding that I will get a delivery
 report ONLY  if the message is successfully delivered. Yet I get quite a
few got DLR but could not find message or was not interested in it
id2596568125 dstx, type2 ERROR messages in smpp.log. After
the queue has dissolved I will try a batch without DLR report.



 2. Smsc-mt is used for MT billing. It appears the only SMS that are
 delivered to phones which have sufficient airtime balance are counted as
 sent in kannel's counter. The outbound sending rate also does not reflect
 The traffic on the Smsc-mt connection. I expect all messages that leave
 kannel Via that connection to counted as part of the statistics but is
 clearly not the case. Is this a kannel bug?


  I don't get what you mean here. Kannel's counter reflects all sms sent
 through it even if they are not delivered to the phone. Kannel just reports
 what sent/received to/from the upstream SMSC providers.


*smsc-mt*   SMPP:2xxx/5020:yyy:'VMA' (online 10062s, rcvd 169235, sent
84451, failed 2836, queued 0 msgs). For the smsc-mt connection which is
used for MT billing, I push more than 200k per day, yet the counter only
shows 84451 as sent in last 7 days. This happens to about same number of
successfully delivered messages - message is delivered only when there is
sufficient credit on the phone.


 also

 port = 5020

 receive-port = 5020

 you can replace with:

 port = 5020

 transceiver-mode = 1

 Thanks

 Banji


 Below is my kannel.conf file.

 #--- mysql connection

 group = 

Re: Kannel queue growing though TPS not exceeded

2013-07-30 Thread spameden
Sorry, forgot to include the list.


2013/7/30 spameden spame...@gmail.com

 Hi


 2013/7/30 olad...@gmail.com



 Please see my responses inline highlighted in yellow. Would appreciate
 your feedback. Thanks for your help.

 On Tue, Jul 30, 2013 at 9:33 AM, spameden spame...@gmail.com wrote:

 Hi

 2013/7/30 Oladeji Oladeji olad...@gmail.com

 Kannel bearerbox version `1.4.3'. Build `Mar 27 2013 08:45:56',
 compiler `4.4.7 20120313 (Red Hat 4.4.7-3)'. System Linux, release
 2.6.32-279.14.1.el6.x86_64, version #1 SMP Tue Nov 6 23:43:09 UTC 2012,
 machine x86_64. Hostname mobilise.kannel01, IP 192.168.2.140. Libxml
 version 2.7.6. Compiled with MySQL 5.1.66, using MySQL 5.1.66. Using SQLite
 3.6.20. Using native malloc.

 Status: running, uptime 7d 6h 39m 37s

 WDP: received 0 (0 queued), sent 0 (0 queued)

 SMS: received 7449523 (0 queued), sent 5920323 (224 queued), store
 size -1

 SMS: inbound (9.07,9.69,11.85) msg/sec, outbound (20.72,20.33,9.42)
 msg/sec

 DLR: 122538 queued, using mysql storage

 Box connections:
 smsbox:(none), IP 127.0.0.1 (0 queued), (on-line 7d 6h 39m 37s)

 SMSC connections:
 *smsc-mo*SMPP:1/5020:yyy:'VMA' (online 10061s, rcvd
 4021039, sent 5835872, failed 431745, queued 13602 msgs)
 *smsc-mt*   SMPP:2xxx/5020:yyy:'VMA' (online 10062s, rcvd 169235,
 sent 84451, failed 2836, queued 0 msgs)


 Per the kannel status page above, I have 2 SMSC connections directly to
 operator. Connection1 (*smsc-mo *for broadcast messages) is configured
 for a throughput per  second (TPS) of 70 by operator, Connection 2 (*
 smsc-mt*  for Charging MT), TPS of 60. The kannel config file is
 pasted below:

 I have 2 questions:

 1. As observed above I am only sending only 20 msg per second, yet the
 BB  queue for smsc-mo has started to build up. It only goes down after if I
 reduce the sending rate from the application or stop sending for  a while.
   The operator insists I have 70 TPS. If this true, what settings in my
 kannel configuration file may be causing BB queue to grow, even when I am
 no where close the TPS configured by the operator. Asked differently, what
 settings can I change to improve the performance and reach the capacity
 configured for the connection without getting queue build up.


 kannel's web interface reports speed incorrectly in most cases if you're
 not checking whilst sending happens (first number means speed for last 5
 minutes if i'm not mistaken, last is overall speed).

 you can check speed via grep'ing / awk'ing your smsc log. ---

 banji:  the rate shown on kannel status page matches the rate I see when
 I grep access.log files





 OK, just for me it was the case when I had similar problem like you.


 as I can see you've already tweaked max-pending-submit as well as
 wait-ack thing. -

 banji:  These two settings are  the ones I am not most unsure about.
 What is the rule of thumb? If I want to get to 70 message per second
 throughput and assuming the smsc connection can handle it, what should
 these parameters be set to?


 well, max-pending-submits is unofficial setting restricts how much
 'outstanding' operations can be between you and smsc provider.

 let's say if there i 40 set that means there can be 40 submit_sm without
 submit_sm_resp sent to your smsc.

 wait-ack is the time which kannel waits for ACK before resending the
 message 2nd time.


 do you see any throttling errors at all in your smsc log?

 banji: No throttling error. This is what leads me to believe the problem
 may not be from operator side.


 that's good, actually you might try increasing throughput parameter to 60
 and max-pending-submits to 45 and play with them (you might get throttling
 error tho).

 personally I'm using formula throughput + max-pending-submits = THROUGHPUT
 of your SMSC

 in your case 30 + 45 or 35 + 40.


 you can also measure speed by sniffing your network interface and
 counting submit_sm per second in any sniffer (ethershark, ettercap, etc).

 banji: Ok will try this. Not sure why this will be different from
 counting the submit_sm per second in the log file.


It will get you the real picture, incase there is something wrong how
kannel counts how many MTs are going per second.




 from the page you've sent I can see you're using smsbox only, do you use
 DLR reports at all? try sending test batch of MT without DLR reports and
 see if speed improves.


 I set dlr-mask to 1 with the understanding that I will get a delivery
  report ONLY  if the message is successfully delivered. Yet I get quite a
 few got DLR but could not find message or was not interested in it
 id2596568125 dstx, type2 ERROR messages in smpp.log. After
 the queue has dissolved I will try a batch without DLR report.



Kannel only asks DLR for 1st part of the concatenated message (160chars
for latin or 80 for ucs2).

So if your SMSC provider sends for all parts even if there is
registered_delivery flag set to 0 you can safely ignore this message.

On the other hand