On Fri, 2005-06-24 at 09:35 +0700, Ricky Wibowo wrote:
> Sorry I forgot to send you example log :
> conf :
> group = smsbox
> bearerbox-host = localhost
> smsbox-id = mysms               
> sendsms-port = 13131
> global-sender = 3345
> sendsms-chars = "0123456789 +-"
> log-file = "/var/log/kannel/smsbox.log"
> log-level = 0              
> access-log = "/var/log/kannel/access.log"
> 
> smsbox.log :
> 2005-06-24 09:12:00 [15950] [0] DEBUG: Started thread 5 
> (gw/smsbox.c:url_result_thread)
> 2005-06-24 09:12:00 [15950] [0] DEBUG: Started thread 6 
> (gw/smsbox.c:http_queue_thread)
> 2005-06-24 09:12:00 [15950] [0] INFO: Connected to bearerbox at 
> localhost port 13001.
> 2005-06-24 09:12:00 [15950] [0] DEBUG: Started thread 7 
> (gw/heartbeat.c:heartbeat_thread)
> 2005-06-24 09:12:00 [15950] [2] DEBUG: Thread 2 
> (gwlib/http.c:server_thread) maps to pid 15950.
> 2005-06-24 09:12:00 [15950] [3] DEBUG: Thread 3 
> (gw/smsbox.c:sendsms_thread) maps to pid 15950.
> 2005-06-24 09:12:00 [15950] [4] DEBUG: Thread 4 
> (gw/smsbox.c:obey_request_thread) maps to pid 15950.
> 2005-06-24 09:12:00 [15950] [5] DEBUG: Thread 5 
> (gw/smsbox.c:url_result_thread) maps to pid 15950.
> 2005-06-24 09:12:00 [15950] [6] DEBUG: Thread 6 
> (gw/smsbox.c:http_queue_thread) maps to pid 15950.
> 2005-06-24 09:12:00 [15950] [7] DEBUG: Thread 7 
> (gw/heartbeat.c:heartbeat_thread) maps to pid 15950.
> 
> access.log
> 2005-06-24 09:13:30 2005-06-24 02:13:30 Receive SMS [SMSC:smsc_fake] 
> [SMS ID:e19051d4-95d5-4a6f-ba16-b1efb069964d] [SVC:] [ACT:] [BINF:] 
> [from:100] [to:3345] [flags:-1:-1:-1:-1:-1] [msg:4:test] [udh:0:] 
> [Delivery Report Value:-1] [SMSC Reply:] [SMS User:]
> 2005-06-24 09:13:31 2005-06-24 02:13:31 Receive SMS [SMSC:smsc_fake] 
> [SMS ID:5960e6ac-428b-4cbb-a364-9f2c141c1b2e] [SVC:] [ACT:] [BINF:] 
> [from:100] [to:3345] [flags:-1:-1:-1:-1:-1] [msg:4:test] [udh:0:] 
> [Delivery Report Value:-1] [SMSC Reply:] [SMS User:]
> 2005-06-24 09:13:32 2005-06-24 02:13:32 Receive SMS [SMSC:smsc_fake] 
> [SMS ID:b77b3bea-b104-4594-bc08-d69e5281325a] [SVC:] [ACT:] [BINF:] 
> [from:100] [to:3345] [flags:-1:-1:-1:-1:-1] [msg:4:test] [udh:0:] 
> [Delivery Report Value:-1] [SMSC Reply:] [SMS User:]
> 2005-06-24 09:13:33 2005-06-24 02:13:33 Receive SMS [SMSC:smsc_fake] 
> [SMS ID:227f605c-e124-4cc2-942e-f6feb48722b1] [SVC:] [ACT:] [BINF:] 
> [from:100] [to:3345] [flags:-1:-1:-1:-1:-1] [msg:4:test] [udh:0:] 
> [Delivery Report Value:-1] [SMSC Reply:] [SMS User:]
> 2005-06-24 09:13:34 2005-06-24 02:13:34 Receive SMS [SMSC:smsc_fake] 
> [SMS ID:73197faf-2504-4e7d-b663-e278df6768a8] [SVC:] [ACT:] [BINF:] 
> [from:100] [to:3345] [flags:-1:-1:-1:-1:-1] [msg:4:test] [udh:0:] 
> [Delivery Report Value:-1] [SMSC Reply:] [SMS User:]
> 2005-06-24 09:13:35 2005-06-24 02:13:35 Receive SMS [SMSC:smsc_fake] 
> [SMS ID:46371b2c-e6fa-450d-a4d5-b656d4d5433f] [SVC:] [ACT:] [BINF:] 
> [from:100] [to:3345] [flags:-1:-1:-1:-1:-1] [msg:4:test] [udh:0:] 
> [Delivery Report Value:-1] [SMSC Reply:] [SMS User:]
> 2005-06-24 09:13:36 2005-06-24 02:13:36 Receive SMS [SMSC:smsc_fake] 
> [SMS ID:33775bee-306d-439d-af9a-6de263df88c9] [SVC:] [ACT:] [BINF:] 
> [from:100] [to:3345] [flags:-1:-1:-1:-1:-1] [msg:4:test] [udh:0:] 
> [Delivery Report Value:-1] [SMSC Reply:] [SMS User:]
> 2005-06-24 09:13:37 2005-06-24 02:13:37 Receive SMS [SMSC:smsc_fake] 
> [SMS ID:bbe0ecd7-a9c3-4cf4-98a5-2998be05ffc4] [SVC:] [ACT:] [BINF:] 
> [from:100] [to:3345] [flags:-1:-1:-1:-1:-1] [msg:4:test] [udh:0:] 
> [Delivery Report Value:-1] [SMSC Reply:] [SMS User:]
> 2005-06-24 09:13:38 2005-06-24 02:13:38 Receive SMS [SMSC:smsc_fake] 
> [SMS ID:0234854c-4d8b-402f-84de-4470a5e01011] [SVC:] [ACT:] [BINF:] 
> [from:100] [to:3345] [flags:-1:-1:-1:-1:-1] [msg:4:test] [udh:0:] 
> [Delivery Report Value:-1] [SMSC Reply:] [SMS User:]
> 2005-06-24 09:13:39 2005-06-24 02:13:39 Receive SMS [SMSC:smsc_fake] 
> [SMS ID:2c6aedd2-0434-4d07-9f9e-3744e46032f5] [SVC:] [ACT:] [BINF:] 
> [from:100] [to:3345] [flags:-1:-1:-1:-1:-1] [msg:4:test] [udh:0:] 
> [Delivery Report Value:-1] [SMSC Reply:] [SMS User:]
> 
> is this my configuration is working correctly??
> 
> thanx for your patient answering my question :-)
> 
> Ricky
> 
<answer>
It seem there is nothing with your smsbox dekcaration. I couldn't get
information from the access.log. I used bearbox log to see what's wrong
with my conf. 

BTW, from this part of log [SMS User:] told me that you don't have
sendsms-user declaration.

Here, I attached conf file that works for me. I change AT-SMSC (for GSM
modem) to FAKESMS. I suggest you test your config and sms processing
script with GSM modem to have real experience with real sms.

Hope this can help you.

--tjatur

PS: FAKE-SMS only for testing purposes only. It couldn't emulate real
SMSC from your Telco Operator

</answer>


> 
> 
> 
> Heru Tjatur wrote:
> 
> >On Thu, 2005-06-23 at 17:54 +0700, Ricky Wibowo wrote:
> >  
> >
> >>in my simple coding called myCoding.php
> >><?
> >>$a = $_GET['a'];
> >>$fp = fopen("/tmp/textfile_name.txt", "w");
> >>fwrite($fp, $a);
> >>fclose($fp);
> >>?>
> >>
> >>and my sms-service config :
> >>
> >>group = sms-service
> >>keyword = default
> >>get-url = "http://localhost/myCoding.php?a=%a
> >>catch-all = true         
> >>send-sender = true       
> >>omit-empty = true      
> >>max-messages = 0
> >>
> >>do you think, it would be work fine, just for write file 
> >>/tmp/textfile_name.txt and the file's content is the message which sent 
> >>by SMSc Operator??
> >>
> >>    
> >>
> ><answer>
> >Dear Ricky,
> >
> >First of all, if your conf file works (it means your sms reached the
> >smsbox and deploy your default sms-service declaration), your script
> >will overwrite the textfile every time sms comming. So the file have
> >last $a value from last sms processed. I suggest "a+" at fopen()
> >argument. 
> >
> >If your declaration of other part configuration file works
> >(bearbox/core, smsbox, smsc, and sendsms-user when necessary), yes your
> >myCoding.php script will be invoked for each incomming sms.
> >
> >If your get-url never been called, something goes wrong. You have to
> >trace back you configuration.
> >
> >
> >Hope this can help you
> >--tjatur
> ></answer>
> >
> >
> >
> >
> >  
> >
> >>thank you for your explaination
> >>
> >>Heru Tjatur wrote:
> >>
> >>    
> >>
> >>>On Thu, 2005-06-23 at 11:55 +0300, Jonas Zaveckas wrote:
> >>> 
> >>>
> >>>      
> >>>
> >>>>On Thu, 2005-06-23 at 15:39 +0700, Heru Tjatur wrote:
> >>>>   
> >>>>
> >>>>        
> >>>>
> >>>>>Dear Jonas,
> >>>>>
> >>>>>You may try to use get-url instead of post-url. You should confirm that
> >>>>>your url is capable of processing the incooming request (sms) and, of
> >>>>>course, send reply to sms's sender.
> >>>>>     
> >>>>>
> >>>>>          
> >>>>>
> >>>>How (and when?) I can confirm that my URL is capable to process SMS?
> >>>>What do you have in mind?
> >>>>
> >>>>   
> >>>>
> >>>>        
> >>>>
> >>><answer>
> >>>I used apache and PHP to process all incomming sms. On successfull
> >>>fetching sms'es from telco operator (SMPP 3.4), all smses goes get-url
> >>>set in sms-service declaration.
> >>>
> >>>I can confirm that the get-url does its job by investigating the httpd
> >>>log. All get-url invocation, the apache should write httpd request log.
> >>>
> >>>If you can't confirm that, it might be your sms never reached smsbox.
> >>>You have to trace it back from smsbox and bearbox log.
> >>>
> >>>Hope that information help you 
> >>>
> >>>--tjatur
> >>></answer>
> >>>
> >>>
> >>> 
> >>>
> >>>      
> >>>
> >>>>>Hope this could help you
> >>>>>
> >>>>>--tjatur 
> >>>>>
> >>>>>On Thu, 2005-06-23 at 10:13 +0300, Jonas Zaveckas wrote:
> >>>>>     
> >>>>>
> >>>>>          
> >>>>>
> >>>>>>Hello
> >>>>>>I need to create SMS based service - receive SMSes sent by users to
> >>>>>>particular SMS number and reply them with response SMS. Kannel seems to
> >>>>>>fit such simple requirement. After reading user documentation I've found
> >>>>>>that sending SMS to some terminal is quite simple. However, the way to
> >>>>>>get SMS'es sent by terminals remains unclear. I've create entry in
> >>>>>>configuration smskannel.conf like this:
> >>>>>>...
> >>>>>>group = sms-service
> >>>>>>keyword = default
> >>>>>>post-url = "http://localhost:8084/sender=%p&receiver=%P&smscid=%i&name=%
> >>>>>>n&coding=%c&charset=%C"
> >>>>>>catch-all = true
> >>>>>>..
> >>>>>>
> >>>>>>, have started socket server listening on 8084, but SMS'es do not
> >>>>>>arrive. If I start fakesmsc like this:
> >>>>>>'fakesmsc -i 0.1 -m 100 "100 200 text nop" "100 300 text echo this"'
> >>>>>>then SMS arrive to my server. But if I generate SMS, say from SMSC
> >>>>>>simulator (got from 'http://opensmpp.logica.com/introhtml/menu.htm')
> >>>>>>then from bearerbox log I can see that SMS reaches bearerbox, but it is
> >>>>>>not seen in smsbox log and it is not received by my server.
> >>>>>>
> >>>>>>My complete smskannel.conf is attached.
> >>>>>>
> >>>>>>Jonas
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>>       
> >>>>>>
> >>>>>>            
> >>>>>>
> >>>>>     
> >>>>>
> >>>>>          
> >>>>>
> >>>
> >>>
> >>>
> >>> 
> >>>
> >>>      
> >>>
> >
> >
> >
> >
> >  
> >
#
# THIS IS A SAMPLE CONFIGURATION FOR KANNEL
#
# For any modifications to this file, see Kannel User Guide 
# If that does not help, send email to [email protected]
#

group = core
admin-port = 13000
admin-password = XXXX
status-password = XXXX
log-file = "/var/log/kannel/bearbox.log"
log-level = 2
access-log = "/var/log/kannel/bearbox-access.log"
smsbox-port = 13001
box-deny-ip = "*.*.*.*"
box-allow-ip = "127.0.0.1"
unified-prefix = "+62,0"
#store-file = "/var/log/kannel/kannel.store"


# FAKE SMSC
group = smsc
smsc = fake
smsc-id = myFAKE
port = 10000
connect-allow-ip = 127.0.0.1


# SMSBOX SETUP

group = smsbox
bearerbox-host = 127.0.0.1
sendsms-port = 13013
sendsms-chars = "0123456789 +-"
global-sender = 123456789 
log-file = "/var/log/kannel/smsbox.log"
log-level = 2
access-log = "/var/log/kannel/smsbox-access.log"


# SEND-SMS USERS

group = sendsms-user
username = user
password = password
#user-deny-ip = "*.*.*.*"
user-allow-ip = "127.0.0.1"

# this sender is for Kannel relay testing (http_smsc)

#group = sendsms-user
#username = kannel
#password = rL4y
#user-deny-ip = "*.*.*.*"
#user-allow-ip = "127.0.0.1"


# SMS SERVICE Default
# there should be default always
#group = sms-service
#keyword = default
#text = "No service specified"


group = sms-service
keyword = default
accepted-smsc = myFAKE
#aliases = quote;info;bid;sell;update;reg;
get-url = 
"http://127.0.0.3/index.php?fuseaction=sms.incomming&smscid=%i&sms_msisdn=%p&sms_text=%a&sms_time=%t";
max-messages = 0
#text = "Just running a test "
accept-x-kannel-headers = false

Reply via email to