使用Kannel网关将短信发送到海外移动电话号码时出错

时间:2011-01-11 08:37:37

标签: kannel

我在柬埔寨,我现在能够使用kannel网关向本地手机号码发送短信。但是,为什么尝试向海外手机号码(新加坡手机号码)发送短信,我遇到了一个错误。如果我取出我的SIM卡并放入手机,我就可以将短信发送到海外。

错误 2011-01-11 10:58:04 [3960] [6]错误:AT2 [abcd]:一般错误:错误

有没有人遇到过这个问题?我真的很感谢你的帮助。谢谢。

我在Ubuntu 10.04 LTS上安装了Kannel 1.4.3。我使用的是wavecom调制解调器,其型号为WAVECOM FASTRACK型DUAL BRANCH MODEM,通过串口连接到kannel。

这是我用来从网络浏览器发送短信的命令

的http://本地主机:13013 /的cgi-bin / sendsms用户名=测试器&安培;密码= foobar的&安培;从= + 85516872490&安培;要= + 6597379814&安培;文本= TestSendingAnSMSFromTheSystem

以下是我的配置文件和日志文件。

如果您需要更多详细信息,请告知我们。

配置文件:kannel.conf

group = core
admin-port = 13000
admin-password = bar
smsbox-port = 13001
smsbox-port-ssl = false
log-file = "/home/sambath/Documents/softwares/kannel/kannel.log"
log-level = 0
access-log = "/home/sambath/Documents/softwares/kannel/access.log"
access-log-clean = true
sms-resend-retry = 0

# SMSC GSM

group = smsc
smsc = at
smsc-id = abcd
modemtype = wavecom 
device = /dev/ttyUSB0
pin = 0000
alt-charset = "ASCII" 

group = modems
id = wavecom
name = "wavecom"
detect-string = "wavecom"
message-storage = sm
speed = 115200    

# SMSBOX SETUP

group = smsbox
bearerbox-host = localhost
sendsms-port = 13013
sendsms-chars = "0123456789 +-"
log-file = "/home/sambath/Documents/softwares/kannel/smsbox.log"
access-log = "/home/sambath/Documents/softwares/kannel/access.log"
mo-recode = true

# SEND-SMS USERS

group = sendsms-user
username = tester
password = foobar    

# SMS SERVICES

group = sms-service
keyword = default
get-url = "http://localhost:8080/ReceiveSms.php?sender=%p&text=%a"
catch-all = true
max-messages = 0

日志文件:kannel.log

2011-01-11 10:57:44 [3960] [0] INFO: Added logfile `/home/sambath/Documents/softwares/kannel/kannel.log' with level `0'.
2011-01-11 10:57:44 [3960] [0] INFO: Started access logfile `/home/sambath/Documents/softwares/kannel/access.log'.
2011-01-11 10:57:44 [3960] [0] INFO: SSL not supported, no SSL initialization done.
2011-01-11 10:57:44 [3960] [0] INFO: HTTP: Opening server at port 13000.
2011-01-11 10:57:44 [3960] [0] DEBUG: Started thread 1 (gwlib/fdset.c:poller)
2011-01-11 10:57:44 [3960] [1] DEBUG: Thread 1 (gwlib/fdset.c:poller) maps to pid 3960.
2011-01-11 10:57:44 [3960] [0] DEBUG: Started thread 2 (gwlib/http.c:server_thread)
2011-01-11 10:57:44 [3960] [0] DEBUG: Started thread 3 (gw/bb_http.c:httpadmin_run)
2011-01-11 10:57:44 [3960] [3] DEBUG: Thread 3 (gw/bb_http.c:httpadmin_run) maps to pid 3960.
2011-01-11 10:57:44 [3960] [0] DEBUG: starting smsbox connection module
2011-01-11 10:57:44 [3960] [0] INFO: BOXC: 'smsbox-max-pending' not set, using default (100).
2011-01-11 10:57:44 [3960] [0] DEBUG: Started thread 4 (gw/bb_boxc.c:sms_to_smsboxes)
2011-01-11 10:57:44 [3960] [4] DEBUG: Thread 4 (gw/bb_boxc.c:sms_to_smsboxes) maps to pid 3960.
2011-01-11 10:57:44 [3960] [0] DEBUG: Started thread 5 (gw/bb_boxc.c:smsboxc_run)
2011-01-11 10:57:44 [3960] [5] DEBUG: Thread 5 (gw/bb_boxc.c:smsboxc_run) maps to pid 3960.
2011-01-11 10:57:44 [3960] [0] INFO: Set SMS resend frequency to 60 seconds.
2011-01-11 10:57:44 [3960] [0] INFO: SMS resend retry set to 0.
2011-01-11 10:57:44 [3960] [0] DEBUG: smsbox MO concatenated message handling enabled
2011-01-11 10:57:44 [3960] [0] INFO: DLR rerouting for smsc id <abcd> disabled.
2011-01-11 10:57:44 [3960] [0] INFO: AT2[abcd]: configuration shows modemtype <wavecom>
2011-01-11 10:57:44 [3960] [0] DEBUG: AT2[abcd]: Reading modem definitions from <kannel.conf>
2011-01-11 10:57:44 [3960] [0] DEBUG: AT2[abcd]: Found <1> modems in config
2011-01-11 10:57:44 [3960] [0] INFO: AT2[abcd]: read modem definition for <wavecom>
2011-01-11 10:57:44 [3960] [0] DEBUG: Started thread 6 (gw/smsc/smsc_at.c:at2_device_thread)
2011-01-11 10:57:44 [3960] [6] DEBUG: Thread 6 (gw/smsc/smsc_at.c:at2_device_thread) maps to pid 3960.
2011-01-11 10:57:44 [3960] [0] DEBUG: Started thread 7 (gw/bb_smscconn.c:sms_router)
2011-01-11 10:57:44 [3960] [7] DEBUG: Thread 7 (gw/bb_smscconn.c:sms_router) maps to pid 3960.
2011-01-11 10:57:44 [3960] [6] INFO: AT2[abcd]: trying to use speed <115200> from modem definition
2011-01-11 10:57:44 [3960] [6] INFO: AT2[abcd]: opening device
2011-01-11 10:57:44 [3960] [0] INFO: ----------------------------------------
2011-01-11 10:57:44 [3960] [0] INFO: Kannel bearerbox II version 1.4.3 starting
2011-01-11 10:57:44 [3960] [0] INFO: MAIN: Start-up done, entering mainloop
2011-01-11 10:57:44 [3960] [0] DEBUG: AT2[abcd]: start called
2011-01-11 10:57:44 [3960] [2] DEBUG: Thread 2 (gwlib/http.c:server_thread) maps to pid 3960.
2011-01-11 10:57:44 [3960] [6] DEBUG: AT2[abcd]: device opened. Telnet mode = 0
2011-01-11 10:57:44 [3960] [6] DEBUG: AT2[abcd]: device opened
2011-01-11 10:57:44 [3960] [6] INFO: AT2[abcd]: speed set to 115200
2011-01-11 10:57:44 [3960] [6] DEBUG: AT2[abcd]: --> ^M
2011-01-11 10:57:46 [3960] [6] DEBUG: AT2[abcd]: --> AT^M
2011-01-11 10:57:46 [3960] [6] DEBUG: AT2[abcd]: <-- AT
2011-01-11 10:57:46 [3960] [6] DEBUG: AT2[abcd]: <-- OK
2011-01-11 10:57:46 [3960] [6] INFO: AT2[abcd]: Closing device
2011-01-11 10:57:46 [3960] [6] INFO: AT2[abcd]: speed is 115200
2011-01-11 10:57:46 [3960] [6] INFO: AT2[abcd]: opening device
2011-01-11 10:57:46 [3960] [6] DEBUG: AT2[abcd]: device opened. Telnet mode = 0
2011-01-11 10:57:46 [3960] [6] DEBUG: AT2[abcd]: device opened
2011-01-11 10:57:46 [3960] [6] INFO: AT2[abcd]: Logging in
2011-01-11 10:57:46 [3960] [6] INFO: AT2[abcd]: init device
2011-01-11 10:57:46 [3960] [6] INFO: AT2[abcd]: speed set to 115200
2011-01-11 10:57:46 [3960] [6] DEBUG: AT2[abcd]: --> ATZ^M
2011-01-11 10:57:46 [3960] [6] DEBUG: AT2[abcd]: <-- ATZ
2011-01-11 10:57:46 [3960] [6] DEBUG: AT2[abcd]: <-- OK
2011-01-11 10:57:46 [3960] [6] DEBUG: AT2[abcd]: --> AT^M
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: <-- AT
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: <-- OK
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: --> AT&F^M
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: <-- AT&F
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: <-- OK
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: --> ATE0^M
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: <-- ATE0
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: <-- OK
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: --> AT+IFC=2,2^M
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: <-- OK
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: --> AT+CPIN?^M
2011-01-11 10:57:47 [3960] [6] DEBUG: AT2[abcd]: <-- +CPIN: READY
2011-01-11 10:57:48 [3960] [5] INFO: Client connected from <127.0.0.1> 
2011-01-11 10:57:48 [3960] [5] DEBUG: Started thread 8 (gw/bb_boxc.c:function)
2011-01-11 10:57:48 [3960] [8] DEBUG: Thread 8 (gw/bb_boxc.c:function) maps to pid 3960.
2011-01-11 10:57:48 [3960] [8] DEBUG: Started thread 9 (gw/bb_boxc.c:boxc_sender)
2011-01-11 10:57:48 [3960] [9] DEBUG: Thread 9 (gw/bb_boxc.c:boxc_sender) maps to pid 3960.
2011-01-11 10:57:58 [3960] [6] DEBUG: AT2[abcd]: --> AT+CMGF=0^M
2011-01-11 10:57:58 [3960] [6] DEBUG: AT2[abcd]: <-- OK
2011-01-11 10:57:58 [3960] [6] DEBUG: AT2[abcd]: --> AT+CSMS=?^M
2011-01-11 10:57:58 [3960] [6] DEBUG: AT2[abcd]: <-- +CSMS: (0,1)
2011-01-11 10:57:58 [3960] [6] DEBUG: AT2[abcd]: <-- OK
2011-01-11 10:57:58 [3960] [6] INFO: AT2[abcd]: Phase 2+ is supported
2011-01-11 10:57:58 [3960] [6] DEBUG: AT2[abcd]: --> AT+CSMS=1^M
2011-01-11 10:57:58 [3960] [6] DEBUG: AT2[abcd]: <-- +CSMS: 1,1,1
2011-01-11 10:57:58 [3960] [6] DEBUG: AT2[abcd]: <-- OK
2011-01-11 10:57:58 [3960] [6] DEBUG: AT2[abcd]: --> AT+CNMI=1,2,0,1,0^M
2011-01-11 10:57:58 [3960] [6] DEBUG: AT2[abcd]: <-- OK
2011-01-11 10:57:58 [3960] [6] INFO: AT2[abcd]: AT SMSC successfully opened.
2011-01-11 10:58:00 [3960] [8] DEBUG: boxc_receiver: sms received
2011-01-11 10:58:00 [3960] [8] DEBUG: send_msg: sending msg to box: <127.0.0.1>
2011-01-11 10:58:02 [3960] [6] DEBUG: AT2[abcd]: TP-Validity-Period: 24.0 hours
2011-01-11 10:58:02 [3960] [6] DEBUG: AT2[abcd]: --> AT+CMGS=39^M
2011-01-11 10:58:02 [3960] [6] DEBUG: AT2[abcd]: <-- 
2011-01-11 10:58:02 [3960] [6] DEBUG: AT2[abcd]: <-- >
2011-01-11 10:58:02 [3960] [6] DEBUG: AT2[abcd]: send command status: 1
2011-01-11 10:58:02 [3960] [6] DEBUG: AT2[abcd]: --> 0011000A8156797377780000A71DD4F29C3E2DBBC969F739E89E36A746F9BB4D4597A7F939BDDC06
2011-01-11 10:58:02 [3960] [6] DEBUG: AT2[abcd]: --> ^Z
2011-01-11 10:58:04 [3960] [6] DEBUG: AT2[abcd]: <-- ERROR
2011-01-11 10:58:04 [3960] [6] ERROR: AT2[abcd]: Generic error: ERROR
2011-01-11 10:58:04 [3960] [6] DEBUG: AT2[abcd]: send command status: -1
2011-01-11 10:58:04 [3960] [7] DEBUG: sms_router: handling message (0x9268090 vs 0x9268090)
2011-01-11 10:58:04 [3960] [7] DEBUG: re-queing SMS not-yet-to-be resent

日志文件:smsbox.log

2011-01-11 10:57:48 [3968] [0] INFO: Added logfile `/home/sambath/Documents/softwares/kannel/smsbox.log' with level `0'.
2011-01-11 10:57:48 [3968] [0] INFO: Logging accesses to '/home/sambath/Documents/softwares/kannel/access.log'.
2011-01-11 10:57:48 [3968] [0] INFO: Started access logfile `/home/sambath/Documents/softwares/kannel/access.log'.
2011-01-11 10:57:48 [3968] [0] INFO: HTTP: Opening server at port 13013.
2011-01-11 10:57:48 [3968] [0] DEBUG: Started thread 1 (gwlib/fdset.c:poller)
2011-01-11 10:57:48 [3968] [1] DEBUG: Thread 1 (gwlib/fdset.c:poller) maps to pid 3968.
2011-01-11 10:57:48 [3968] [0] DEBUG: Started thread 2 (gwlib/http.c:server_thread)
2011-01-11 10:57:48 [3968] [2] DEBUG: Thread 2 (gwlib/http.c:server_thread) maps to pid 3968.
2011-01-11 10:57:48 [3968] [0] INFO: Set up send sms service at port 13013
2011-01-11 10:57:48 [3968] [0] DEBUG: Started thread 3 (gw/smsbox.c:sendsms_thread)
2011-01-11 10:57:48 [3968] [3] DEBUG: Thread 3 (gw/smsbox.c:sendsms_thread) maps to pid 3968.
2011-01-11 10:57:48 [3968] [0] DEBUG: ----------------------------------------------
2011-01-11 10:57:48 [3968] [0] DEBUG: Kannel smsbox version 1.4.3 starting
2011-01-11 10:57:48 [3968] [0] DEBUG:   dumping group (sendsms-user):
2011-01-11 10:57:48 [3968] [0] DEBUG:     <group> = <sendsms-user>
2011-01-11 10:57:48 [3968] [0] DEBUG:     <username> = <tester>
2011-01-11 10:57:48 [3968] [0] DEBUG:     <password> = <foobar>
2011-01-11 10:57:48 [3968] [0] DEBUG: Started thread 4 (gw/smsbox.c:obey_request_thread)
2011-01-11 10:57:48 [3968] [4] DEBUG: Thread 4 (gw/smsbox.c:obey_request_thread) maps to pid 3968.
2011-01-11 10:57:48 [3968] [0] DEBUG: Started thread 5 (gw/smsbox.c:url_result_thread)
2011-01-11 10:57:48 [3968] [5] DEBUG: Thread 5 (gw/smsbox.c:url_result_thread) maps to pid 3968.
2011-01-11 10:57:48 [3968] [0] DEBUG: Started thread 6 (gw/smsbox.c:http_queue_thread)
2011-01-11 10:57:48 [3968] [6] DEBUG: Thread 6 (gw/smsbox.c:http_queue_thread) maps to pid 3968.
2011-01-11 10:57:48 [3968] [0] INFO: Connected to bearerbox at localhost port 13001.
2011-01-11 10:57:48 [3968] [0] DEBUG: Started thread 7 (gw/heartbeat.c:heartbeat_thread)
2011-01-11 10:57:48 [3968] [7] DEBUG: Thread 7 (gw/heartbeat.c:heartbeat_thread) maps to pid 3968.
2011-01-11 10:58:00 [3968] [2] DEBUG: HTTP: Creating HTTPClient for `127.0.0.1'.
2011-01-11 10:58:00 [3968] [2] DEBUG: HTTP: Created HTTPClient area 0x84472b0.
2011-01-11 10:58:00 [3968] [3] INFO: smsbox: Got HTTP request </cgi-bin/sendsms> from <127.0.0.1>
2011-01-11 10:58:00 [3968] [3] INFO: sendsms used by <tester>
2011-01-11 10:58:00 [3968] [3] INFO: sendsms sender:<tester: 85516872490> (127.0.0.1) to:< 6597379814> msg:<TestSendingAnSMSFromTheSystem>
2011-01-11 10:58:00 [3968] [3] DEBUG: Stored UUID 7b596f94-9784-456c-bd51-930b1f129df0
2011-01-11 10:58:00 [3968] [3] DEBUG: message length 29, sending 1 messages
2011-01-11 10:58:00 [3968] [3] DEBUG: Status: 202 Answer: <Sent.>
2011-01-11 10:58:00 [3968] [3] DEBUG: Delayed reply - wait for bearerbox
2011-01-11 10:58:00 [3968] [0] DEBUG: Got ACK (0) of 7b596f94-9784-456c-bd51-930b1f129df0
2011-01-11 10:58:00 [3968] [0] DEBUG: HTTP: Resetting HTTPClient for `127.0.0.1'.

1 个答案:

答案 0 :(得分:2)

尝试将00替换为+ ..因此您的目的地号码应为0065xxxxxx