我试图在centos中安装kannel我已经下载了tar文件并使用了以下命令
./ configure --- prefix = / etc / kannel / 使 make install
然后 vi kannel.conf
group = core
admin-port = 1300
admin-password = fxxbar
box-allow-ip = "127.0.0.1"
admin-allow-ip = "127.0.0.1"
group = smsc
smsc = fake
smsc-id = FAKE
port = 10000
connect-allow-ip = 127.0.0.1
group = smsbox
bearerbox-host = 127.0.0.1
sendsms-port = 13013
global-sender = 13013
#log-file = "/tmp/smsbox.log"
#log-level = 0
#---------------------------------------------
# SEND-SMS USERS
#
# These users are used when Kannel smsbox sendsms interface is used to
# send PUSH sms messages, i.e. calling URL like
# http://kannel.machine:13013/cgi-bin/sendsms?username=tester&password=foobar...
group = sendsms-user
username = tester
password = foobar
#user-allow-ip = ""
#---------------------------------------------
# SERVICES
#
# These are 'responses' to sms PULL messages, i.e. messages arriving from
# handsets. The response is based on message content. Only one sms-service is
# applied, using the first one to match.
group = sms-service
keyword = nop
text = "You asked nothing and I did it!"
# There should be always a 'default' service. This service is used when no
# other 'sms-service' is applied.
group = sms-service
keyword = default
text = "No service specified"
然后我使用了这个命令sbin / bearerbox kannel.conf并得到以下结果
2013-12-12 04:12:21 [27491] [0] INFO: SSL not supported, no SSL initialization d one.
2013-12-12 04:12:21 [27491] [0] INFO: HTTP: Opening server at port 1300.
2013-12-12 04:12:21 [27491] [0] DEBUG: Started thread 1 (gwlib/fdset.c:poller)
2013-12-12 04:12:21 [27491] [0] DEBUG: Started thread 2 (gwlib/http.c:server_thr ead)
2013-12-12 04:12:21 [27491] [0] DEBUG: Started thread 3 (gw/bb_http.c:httpadmin_ run)
2013-12-12 04:12:21 [27491] [0] DEBUG: starting smsbox connection module
2013-12-12 04:12:21 [27491] [0] ERROR: Missing smsbox-port variable, cannot star t smsboxes
2013-12-12 04:12:21 [27491] [0] INFO: Set SMS resend frequency to 60 seconds.
2013-12-12 04:12:21 [27491] [0] INFO: SMS resend retry set to unlimited.
2013-12-12 04:12:21 [27491] [0] DEBUG: smsbox MO concatenated message handling e nabled
2013-12-12 04:12:21 [27491] [0] INFO: DLR rerouting for smsc id <FAKE> disabled.
2013-12-12 04:12:21 [27491] [0] DEBUG: Started thread 4 (gw/smsc/smsc_fake.c:fak e_listener)
2013-12-12 04:12:21 [27491] [0] DEBUG: Started thread 5 (gw/bb_smscconn.c:sms_ro uter)
2013-12-12 04:12:21 [27491] [0] INFO: ----------------------------------------
2013-12-12 04:12:21 [27491] [0] INFO: Kannel bearerbox II version 1.4.3 starting
2013-12-12 04:12:21 [27491] [3] DEBUG: Thread 3 (gw/bb_http.c:httpadmin_run) map s to pid 27491.
2013-12-12 04:12:21 [27491] [4] DEBUG: Thread 4 (gw/smsc/smsc_fake.c:fake_listen er) maps to pid 27491.
2013-12-12 04:12:21 [27491] [5] DEBUG: Thread 5 (gw/bb_smscconn.c:sms_router) ma ps to pid 27491.
2013-12-12 04:12:21 [27491] [0] INFO: MAIN: Start-up done, entering mainloop
2013-12-12 04:12:21 [27491] [0] DEBUG: smsc_fake: start called
2013-12-12 04:12:21 [27491] [2] DEBUG: Thread 2 (gwlib/http.c:server_thread) map s to pid 27491.
2013-12-12 04:12:21 [27491] [1] DEBUG: Thread 1 (gwlib/fdset.c:poller) maps to p id 27491.
问题是它被困在最后一行 “DEBUG:Thread 1(gwlib / fdset.c:poller)映射到pid 27491.” 在那之后我什么都没发生。
答案 0 :(得分:0)
在你的情况下,没有任何事情发生是正确的
如果你想发送短信:
启动SMSBox
打开一个新终端并输入以下命令
$ smsbox path_to_the_configuration_file
您可以使用FAKESMSC发送假短信:
打开一个新终端并输入:
$ test / fakesmsc
它不是一个真正的短信中心,如果你想发送真正的短信配置短信中心组
(see User's Guide)
答案 1 :(得分:0)
我认为这种配置是错误的。您可以使用我使用的配置文件。 This谷歌文档有很多细节。如果您只想要配置文件,只需复制并粘贴代码即可。 对于核心小组。就像这样
group = core
admin-port = 13000
smsbox-port = 13001
admin-password = abcd #any admin pasword
status-password = **** #your password for this username
log-file = "/var/log/kannel/bearerbox.log"
log-level = 0
box-deny-ip = "*.*.*.*"
box-allow-ip = "127.0.0.1" #local host IP address
sms-resend-retry = 1
答案 2 :(得分:0)
2013-12-12 04:12:21 [27491] [0]错误:缺少smsbox-port变量, 不能加星标
您必须指定“smsbox-port”