gpt4 book ai didi

smpp - Kannel 启动但不创建日志文件

转载 作者:行者123 更新时间:2023-12-02 21:12:25 25 4
gpt4 key购买 nike

当我使用 service kannel start 启动 kannel 服务时,一切正常,kannel 确实启动了,但不起作用。未创建日志文件,并且 /var/log/kannel/ 目录为空,但我不知道为什么。

我的配置如下:

group = core
admin-port = 13000
admin-password = pass
log-file = "/var/log/kannel/bearerbox.log"
log-level = 0
access-log = "/var/log/kannel/access_kannel.log"
store-file = "/var/log/kannel/store_sms"
smsbox-port = 13001
dlr-storage = internal
sms-resend-retry = 1

group = smsc
smsc-id = povoljye
smsc = smpp
host = **.***.***.***
port = 2775
smsc-username = "***"
smsc-password = "***"
address-range = ""
source-addr-ton = 0
source-addr-npi = 1
dest-addr-ton = 1
dest-addr-npi = 1
system-type = VMA
throughput = 1000
reconnect-delay = 5
connection-timeout = 120
transceiver-mode = true
denied-smsc-id = kemerovo
allowed-smsc-id = povoljye
preferred-smsc-id = povoljye

group = smsc
smsc-id = kemerovo
smsc = smpp
host = ***.***.***.***
port = 3102
smsc-username = "***"
smsc-password = "***"
address-range = ""
source-addr-ton = 0
source-add-npi = 1
dest-addr-ton = 1
dest-addr-npi = 1
system-type = VMA
throughput = 1000
reconnect-delay = 5
connection-timeout = 120
transceiver-mode = true
denied-smsc-id = povoljye
allowed-smsc-id = kemerovo
preferred-smsc-id = kemerovo

group = smsbox
bearerbox-host = localhost
sendsms-port = 13005
global-sender = 4105
log-file = /var/log/kannel/smsbox.log
log-level = 0
access-log = /var/log/kannel/access_smsbox.log

group = sendsms-user
username = "user1"
password = "pass"
concatenation = true
max-messages = 20
default-smsc = povoljye

group = sendsms-user
username = "user2"
password = "pass"
concatenation = true
max-messages = 20
default-smsc = kemerovo

group = sms-service
keyword = default
post-url = "http://domain.com/sms/%p/time/%t/coding/%c/smsc/%i"
concatenation = true
max-messages = 0

此问题的原因可能是什么?如何找到更多信息?

最佳答案

我猜 kannel 用户无法写入您的 /var/log/kannel 。假设安装相当标准,您可以尝试

sudo chown -R kannel:kannel /var/log/kannel

使 kannel 用户成为目录的所有者。然后重新启动它,日志应该出现在那里。或者您可以尝试任何其他权限使目录可写(chmod、将 kannel 添加到所有者组或其他操作。)

您还可以在 Debug模式下从命令行启动 Kannel 并查看是否出现任何有趣的内容(我所说的有趣是指有关无法访问的目录或文件的错误消息),例如:

/usr/local/sbin/bearerbox -v 0 -- /etc/kannel/kannel.conf

(假设标准路径,如果您的路径不同,则应该更改它们。)

关于smpp - Kannel 启动但不创建日志文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32723575/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com