Re: Message text in Sent_sms

Andreas Fink <[email protected]>
Newsgroups gmane.comp.mobile.kannel.devel
Message-ID <[email protected]>
you have to create one for yourself. it's up to you to decide what you want to do with a delivery report. This is just a callback to you telling you that the message got delivered.

On 21.08.2012, at 22:57, Clay Zevely <[email protected]> wrote:

> I get the message
>  
> NOT FOUND
> The requested URL /dlr.php was not found on this server.
> Apache/2.2.15 (CentOS) Server at localhost Port 80
>  
>  
> I cannot even locate a dlr.php file if I am suppose to have one.
>  
>  
> Clay
>  
> From: Rene Kluwen [mailto:[email protected]] 
> Sent: Tuesday, August 21, 2012 4:11 PM
> To: 'Clay Zevely'; [email protected]
> Subject: RE: Message text in Sent_sms
>  
> What happens if you call the url: http://localhost/websms/inc/dlr.php?user=test&passwd=hostin&to=%p&message=%a directly from your browser?
> If you do this from the machine that kannel is running from, you might be able to see where the error is.
>  
> == Rene
>  
> From: [email protected] [mailto:[email protected]] On Behalf Of Clay Zevely
> Sent: Tuesday, 21 August, 2012 21:34
> To: [email protected]
> Subject: Message text in Sent_sms
>  
> I have been working to get kannel to log messages in the database and have it partly working. I manually populated the database with data then made test with the smsc sending 3 messages.
> When the smsc sends the data the message text is formatted incorrectly. And kannel returns message Could not fetch content, sorry
> Where and how do I fix this?
>  
>  
> The data should be logged in database as                                 *001f2c07*19.936398,E,75.160046,N,0.04,119.15*280109,122306.000**
> Yet it is being logged as  this making the comma  %2C          *001f2c07*19.936398%2CE%2C75.160046%2CN%2C0.04%2C119.15*280109%2C122306.000**+
>  
>  
> Also I am seeing messages from kannel being returned to smsc with Could not fetch content, sorry
> I am running centos 6.3 with Kannel smsbox version svn-r4985
>  
>  
>  
>  
>  
> Kannel. Conf is
> #CORE
> group = core
> admin-port = 13000
> smsbox-port = 13001
> admin-password = hostin
> wdp-interface-name = "*"
> log-file = "/var/log/kannel/bearerbox.log"
> store-file = "/var/log/kannel/kannel.store"
> log-level = 0
> box-deny-ip = "*.*.*.*"
> box-allow-ip = "*.*.*.*"
> dlr-storage = internal
> #dlr-storage = mysql
>  
> #SMSBOX SETUP
> group = smsbox
> smsbox-id = "mysmsc"
> bearerbox-host = localhost
> bearerbox-port = 13001
> sendsms-port = 13013
> log-file = "/var/log/kannel/smsbox.log"
> log-level = 0
> http-request-retry = 3
> http-queue-delay = 15
> sendsms-chars = "0123456789 +-"
> global-sender = 12345
> mo-recode = true
>  
> group = smsbox-route
> smsbox-id = "mysmsc"
> smsc-id = "mysmsc"
>  
> #group = sms-service
> #keyword = default
> #text = "This is a reply"
> #max-messages = 1
> #catch-all = true
>  
> group = sms-service
> keyword = default
> catch-all = true
> max-messages = 10
> get-url = "http://localhost/websms/inc/dlr.php?user=test&passwd=hostin&to=%p&message=%a"
>  
> # SMSC SMPP
> group = smsc
> smsc-id = "mysmsc"
> smsc = smpp
> host = xxx.xxx.xxx.xxx
> port = 16400
> receive-port = 16400
> smsc-username = Track
> smsc-password = Track
> system-type = ""
> address-range = ""
>  
> group = sendsms-user
> username = root
> password = hostin
> max-messages = 10
>  
> # MySQL DLR Storage
> #group = mysql-connection
> #id = sqlbox-db
> #host = localhost
> #username = root
> #password = hostin
> #database = dlr
> #max-connections = 1
>  
> group = mysql-connection
> id = mydlr
> host = localhost
> username = root
> password = "hostin"
> database = dlr
> max-connections = 1
>  
> 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
>  
>  
> sqlbox.conf is
> #Group sqlbox
> group = sqlbox
> id = mysmsc
> smsbox-id = mysmsc
> bearerbox-host = localhost
> bearerbox-port = 13001
> smsbox-port = 13003
> smsbox-port-ssl = false
> sql-log-table = sent_sms
> sql-insert-table = send_sms
> log-file = "/var/log/kannel/kannel-sqlbox.log"
> log-level = 0
>  
> group = mysql-connection
> id = mysmsc
> host = localhost
> username = root
> password = hostin
> database = dlr
> max-connections = 10
>  
>  
> smsbox.log
> 2012-08-21 14:50:43 [24084] [0] INFO: Added logfile `/var/log/kannel/smsbox.log' with level `0'.
> 2012-08-21 14:50:43 [24084] [0] INFO: Service global sender set as '12345'
> 2012-08-21 14:50:43 [24084] [0] INFO: HTTP: Opening server at port 13013.
> 2012-08-21 14:50:43 [24084] [0] DEBUG: Started thread 1 (gwlib/fdset.c:poller)
> 2012-08-21 14:50:43 [24084] [1] DEBUG: Thread 1 (gwlib/fdset.c:poller) maps to pid 24084.
> 2012-08-21 14:50:43 [24084] [0] DEBUG: Started thread 2 (gwlib/http.c:server_thread)
> 2012-08-21 14:50:43 [24084] [0] INFO: Set up send sms service at port 13013
> 2012-08-21 14:50:43 [24084] [2] DEBUG: Thread 2 (gwlib/http.c:server_thread) maps to pid 24084.
> 2012-08-21 14:50:43 [24084] [0] DEBUG: Started thread 3 (gw/smsbox.c:sendsms_thread)
> 2012-08-21 14:50:43 [24084] [2] DEBUG: HTTP: Including port 13013, fd 9 for polling in server thread
> 2012-08-21 14:50:43 [24084] [0] INFO: Using HTTP request queueing with 3 retries, 15s delay.
> 2012-08-21 14:50:43 [24084] [0] DEBUG: ----------------------------------------------
> 2012-08-21 14:50:43 [24084] [0] DEBUG: Kannel smsbox version svn-r4985 starting
> 2012-08-21 14:50:43 [24084] [3] DEBUG: Thread 3 (gw/smsbox.c:sendsms_thread) maps to pid 24084.
> 2012-08-21 14:50:43 [24084] [0] DEBUG:   dumping group (sendsms-user):
> 2012-08-21 14:50:43 [24084] [0] DEBUG:     <group> = <sendsms-user>
> 2012-08-21 14:50:43 [24084] [0] DEBUG:     <max-messages> = <10>
> 2012-08-21 14:50:43 [24084] [0] DEBUG:     <username> = <root>
> 2012-08-21 14:50:43 [24084] [0] DEBUG:     <password> = <hostin>
> 2012-08-21 14:50:43 [24084] [0] DEBUG: Started thread 4 (gw/smsbox.c:obey_request_thread)
> 2012-08-21 14:50:43 [24084] [4] DEBUG: Thread 4 (gw/smsbox.c:obey_request_thread) maps to pid 24084.
> 2012-08-21 14:50:43 [24084] [0] DEBUG: Started thread 5 (gw/smsbox.c:url_result_thread)
> 2012-08-21 14:50:43 [24084] [5] DEBUG: Thread 5 (gw/smsbox.c:url_result_thread) maps to pid 24084.
> 2012-08-21 14:50:43 [24084] [0] DEBUG: Started thread 6 (gw/smsbox.c:http_queue_thread)
> 2012-08-21 14:50:43 [24084] [6] DEBUG: Thread 6 (gw/smsbox.c:http_queue_thread) maps to pid 24084.
> 2012-08-21 14:50:43 [24084] [0] DEBUG: Connecting to <127.0.0.1>
> 2012-08-21 14:50:43 [24084] [0] INFO: Connected to bearerbox at localhost port 13001.
> 2012-08-21 14:50:43 [24084] [0] DEBUG: Started thread 7 (gw/heartbeat.c:heartbeat_thread)
> 2012-08-21 14:50:43 [24084] [7] DEBUG: Thread 7 (gw/heartbeat.c:heartbeat_thread) maps to pid 24084.
> 2012-08-21 14:51:02 [24084] [4] INFO: Starting to service <*001f2c07*19.936398,E,75.160046,N,0.04,119.15*280109,122306.000** > from <19182271748> to <19038120026>
>  
>  
> Bearbox.log
> 2012-08-21 14:51:43 [24063] [7] DEBUG: SMPP[mysmsc]: Sending PDU:
> 2012-08-21 14:51:43 [24063] [7] DEBUG: SMPP PDU 0x975f888 dump:
> 2012-08-21 14:51:43 [24063] [16] DEBUG: send_msg: sending msg to boxc: <mysmsc>
> 2012-08-21 14:51:43 [24063] [7] DEBUG:   type_name: deliver_sm_resp
> 2012-08-21 14:51:43 [24063] [7] DEBUG:   command_id: 2147483653 = 0x80000005
> 2012-08-21 14:51:43 [24063] [7] DEBUG:   command_status: 0 = 0x00000000
> 2012-08-21 14:51:43 [24063] [7] DEBUG:   sequence_number: 10 = 0x0000000a
> 2012-08-21 14:51:43 [24063] [7] DEBUG:   message_id: NULL
> 2012-08-21 14:51:43 [24063] [7] DEBUG: SMPP PDU dump ends.
> 2012-08-21 14:51:43 [24063] [16] DEBUG: boxc_sender: sent message to <127.0.0.1>
> 2012-08-21 14:51:43 [24063] [15] DEBUG: boxc_receiver: got ack
> 2012-08-21 14:51:44 [24063] [7] DEBUG: SMPP[mysmsc]: Got PDU:
> 2012-08-21 14:51:44 [24063] [7] DEBUG: SMPP PDU 0x975f888 dump:
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   type_name: deliver_sm
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   command_id: 5 = 0x00000005
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   command_status: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   sequence_number: 11 = 0x0000000b
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   service_type: NULL
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   source_addr_ton: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   source_addr_npi: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   source_addr: "19182271748"
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   dest_addr_ton: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   dest_addr_npi: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   destination_addr: "19038120026"
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   esm_class: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   protocol_id: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   priority_flag: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   schedule_delivery_time: NULL
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   validity_period: "120824145142016-"
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   registered_delivery: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   replace_if_present_flag: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   data_coding: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   sm_default_msg_id: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   sm_length: 66 = 0x00000042
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   short_message:
> 2012-08-21 14:51:44 [24063] [7] DEBUG:    Octet string at 0x975fab8:
> 2012-08-21 14:51:44 [24063] [7] DEBUG:      len:  66
> 2012-08-21 14:51:44 [24063] [7] DEBUG:      size: 67
> 2012-08-21 14:51:44 [24063] [7] DEBUG:      immutable: 0
> 2012-08-21 14:51:44 [24063] [7] DEBUG:      data: 2a 30 30 31 66 32 63 30 37 2a 31 39 2e 39 33 36   *001f2c07*19.936
> 2012-08-21 14:51:44 [24063] [7] DEBUG:      data: 33 39 38 2c 45 2c 37 35 2e 31 36 30 30 34 36 2c   398,E,75.160046,
> 2012-08-21 14:51:44 [24063] [7] DEBUG:      data: 4e 2c 30 2e 30 34 2c 31 31 39 2e 31 35 2a 32 38   N,0.04,119.15*28
> 2012-08-21 14:51:44 [24063] [7] DEBUG:      data: 30 31 30 39 2c 31 32 32 33 30 36 2e 30 30 30 2a   0109,122306.000*
> 2012-08-21 14:51:44 [24063] [7] DEBUG:      data: 2a 20                                             *
> 2012-08-21 14:51:44 [24063] [7] DEBUG:    Octet string dump ends.
> 2012-08-21 14:51:44 [24063] [7] DEBUG: SMPP PDU dump ends.
> 2012-08-21 14:51:44 [24063] [7] DEBUG: SMPP[mysmsc]: Sending PDU:
> 2012-08-21 14:51:44 [24063] [7] DEBUG: SMPP PDU 0x9761158 dump:
> 2012-08-21 14:51:44 [24063] [16] DEBUG: send_msg: sending msg to boxc: <mysmsc>
> 2012-08-21 14:51:44 [24063] [16] DEBUG: boxc_sender: sent message to <127.0.0.1>
> 2012-08-21 14:51:44 [24063] [15] DEBUG: boxc_receiver: got ack
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   type_name: deliver_sm_resp
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   command_id: 2147483653 = 0x80000005
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   command_status: 0 = 0x00000000
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   sequence_number: 11 = 0x0000000b
> 2012-08-21 14:51:44 [24063] [7] DEBUG:   message_id: NULL
> 2012-08-21 14:51:44 [24063] [7] DEBUG: SMPP PDU dump ends.
> 2012-08-21 14:51:45 [24063] [7] DEBUG: SMPP[mysmsc]: Got PDU:
> 2012-08-21 14:51:45 [24063] [7] DEBUG: SMPP PDU 0x9761158 dump:
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   type_name: deliver_sm
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   command_id: 5 = 0x00000005
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   command_status: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   sequence_number: 12 = 0x0000000c
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   service_type: NULL
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   source_addr_ton: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   source_addr_npi: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   source_addr: "19182271748"
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   dest_addr_ton: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   dest_addr_npi: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   destination_addr: "19038120026"
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   esm_class: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   protocol_id: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   priority_flag: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   schedule_delivery_time: NULL
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   validity_period: "120824145142016-"
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   registered_delivery: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   replace_if_present_flag: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   data_coding: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   sm_default_msg_id: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   sm_length: 66 = 0x00000042
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   short_message:
> 2012-08-21 14:51:45 [24063] [7] DEBUG:    Octet string at 0x975ede8:
> 2012-08-21 14:51:45 [24063] [7] DEBUG:      len:  66
> 2012-08-21 14:51:45 [24063] [7] DEBUG:      size: 67
> 2012-08-21 14:51:45 [24063] [7] DEBUG:      immutable: 0
> 2012-08-21 14:51:45 [24063] [7] DEBUG:      data: 2a 30 30 31 66 32 63 30 37 2a 31 39 2e 39 33 36   *001f2c07*19.936
> 2012-08-21 14:51:45 [24063] [7] DEBUG:      data: 33 39 38 2c 45 2c 37 35 2e 31 36 30 30 34 36 2c   398,E,75.160046,
> 2012-08-21 14:51:45 [24063] [7] DEBUG:      data: 4e 2c 30 2e 30 34 2c 31 31 39 2e 31 35 2a 32 38   N,0.04,119.15*28
> 2012-08-21 14:51:45 [24063] [7] DEBUG:      data: 30 31 30 39 2c 31 32 32 33 30 36 2e 30 30 30 2a   0109,122306.000*
> 2012-08-21 14:51:45 [24063] [7] DEBUG:      data: 2a 20                                             *
> 2012-08-21 14:51:45 [24063] [7] DEBUG:    Octet string dump ends.
> 2012-08-21 14:51:45 [24063] [7] DEBUG: SMPP PDU dump ends.
> 2012-08-21 14:51:45 [24063] [7] DEBUG: SMPP[mysmsc]: Sending PDU:
> 2012-08-21 14:51:45 [24063] [7] DEBUG: SMPP PDU 0x975dbc8 dump:
> 2012-08-21 14:51:45 [24063] [18] DEBUG: send_msg: sending msg to boxc: <mysmsc>
> 2012-08-21 14:51:45 [24063] [18] DEBUG: boxc_sender: sent message to <127.0.0.1>
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   type_name: deliver_sm_resp
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   command_id: 2147483653 = 0x80000005
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   command_status: 0 = 0x00000000
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   sequence_number: 12 = 0x0000000c
> 2012-08-21 14:51:45 [24063] [7] DEBUG:   message_id: NULL
> 2012-08-21 14:51:45 [24063] [7] DEBUG: SMPP PDU dump ends.
> 2012-08-21 14:51:45 [24063] [17] DEBUG: boxc_receiver: got ack
> 2012-08-21 14:51:48 [24063] [15] DEBUG: boxc_receiver: sms received
> 2012-08-21 14:51:48 [24063] [15] DEBUG: send_msg: sending msg to boxc: <mysmsc>
> 2012-08-21 14:51:48 [24063] [6] DEBUG: SMPP[mysmsc]: throughput (0.00,0.00)
> 2012-08-21 14:51:48 [24063] [6] DEBUG: SMPP[mysmsc]: Sending PDU:
> 2012-08-21 14:51:48 [24063] [6] DEBUG: SMPP PDU 0x975f888 dump:
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   type_name: submit_sm
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   command_id: 4 = 0x00000004
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   command_status: 0 = 0x00000000
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   sequence_number: 7 = 0x00000007
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   service_type: NULL
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   source_addr_ton: 2 = 0x00000002
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   source_addr_npi: 1 = 0x00000001
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   source_addr: "12345"
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   dest_addr_ton: 2 = 0x00000002
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   dest_addr_npi: 1 = 0x00000001
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   destination_addr: "19182271748"
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   esm_class: 3 = 0x00000003
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   protocol_id: 0 = 0x00000000
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   priority_flag: 0 = 0x00000000
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   schedule_delivery_time: NULL
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   validity_period: NULL
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   registered_delivery: 0 = 0x00000000
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   replace_if_present_flag: 0 = 0x00000000
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   data_coding: 0 = 0x00000000
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   sm_default_msg_id: 0 = 0x00000000
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   sm_length: 31 = 0x0000001f
> 2012-08-21 14:51:48 [24063] [6] DEBUG:   short_message:
> 2012-08-21 14:51:48 [24063] [6] DEBUG:    Octet string at 0x975ef50:
> 2012-08-21 14:51:48 [24063] [6] DEBUG:      len:  31
> 2012-08-21 14:51:48 [24063] [6] DEBUG:      size: 32
> 2012-08-21 14:51:48 [24063] [6] DEBUG:      immutable: 0
> 2012-08-21 14:51:48 [24063] [6] DEBUG:      data: 43 6f 75 6c 64 20 6e 6f 74 20 66 65 74 63 68 20   Could not fetch
> 2012-08-21 14:51:48 [24063] [6] DEBUG:      data: 63 6f 6e 74 65 6e 74 2c 20 73 6f 72 72 79 2e      content, sorry.
> 2012-08-21 14:51:48 [24063] [6] DEBUG:    Octet string dump ends.
> 2012-08-21 14:51:48 [24063] [6] DEBUG: SMPP PDU dump ends.
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.