0

Ubuntu 14.04 に gammu と gammu-smsd 1.37 をインストールしました。gammu から直接 SMS を送信しようとすると、問題なく動作します。しかし、gammu-smsd-inject で実行しようとすると、うまくいきません。

gammu-smsd.log:
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: Using FILES service
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: Configuring Gammu SMSD...
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: SHM token: 0xffffffffce0106d2 (-838793518)
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: Warning: No PIN code in /etc/gammu-smsdrc file
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: CommTimeout=30, SendTimeout=30, ReceiveFrequency=15, ResetFrequency=0, HardResetFrequency=0
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: checks: CheckSecurity=1, CheckBattery=1, CheckSignal=1, CheckNetwork=1
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: mode: Send=1, Receive=1
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: deliveryreport = no
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: phoneid =
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: Inbox is "/var/spool/gammu/inbox/" with format "standard"
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: Outbox is "/var/spool/gammu/outbox/" with format "detail" and transmission format "7bit"
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: Sent SMS moved to "/var/spool/gammu/sent/"
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2557]: SMS with errors moved to "/var/spool/gammu/error/"
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2558]: Created POSIX RW shared memory at 0x7fc66468b000
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2558]: Starting phone communication...
    Nov  1 17:04:19 mostjs-srv gammu-smsd[2558]: Error at init connection: Can not open specified file. (CANTOPENFILE[28])

私の設定ファイル:

~/.gammurc
device = /dev/ttyS0
#model = at
connection = at19200
logfile = /var/log/gammu.log
logformat = textall
use_locking = no

/etc/gammu-smsdrc
[gammu]
port = /dev/ttyS0
connection = at
logfile = /var/log/gammu.log
logformat = textall
use_locking = no

# SMSD configuration, see gammu-smsdrc(5)
[smsd]
service = files
LogFile = syslog
debuglevel = 1
# Increase for debugging information

# Paths where messages are stored
inboxpath = /var/spool/gammu/inbox/
outboxpath = /var/spool/gammu/outbox/
sentsmspath = /var/spool/gammu/sent/
errorsmspath = /var/spool/gammu/error/

私は何を間違っていますか?

4

1 に答える 1

0

Michal、それは私のデバイスに対する許可です:

crw-rw----  1 root dialout   4,  64 Ноя  2 10:41 ttyS0
crw-rw----  1 root dialout   4,  65 Ноя  2 10:34 ttyS1
crw-rw----  1 root dialout   4,  74 Ноя  2 10:34 ttyS10
crw-rw----  1 root dialout   4,  75 Ноя  2 10:34 ttyS11
crw-rw----  1 root dialout   4,  76 Ноя  2 10:34 ttyS12
crw-rw----  1 root dialout   4,  77 Ноя  2 10:34 ttyS13
crw-rw----  1 root dialout   4,  78 Ноя  2 10:34 ttyS14
crw-rw----  1 root dialout   4,  79 Ноя  2 10:34 ttyS15
crw-rw----  1 root dialout   4,  80 Ноя  2 10:34 ttyS16
crw-rw----  1 root dialout   4,  81 Ноя  2 10:34 ttyS17
crw-rw----  1 root dialout   4,  82 Ноя  2 10:34 ttyS18
crw-rw----  1 root dialout   4,  83 Ноя  2 10:34 ttyS19
crw-rw----  1 root dialout   4,  66 Ноя  2 10:34 ttyS2
crw-rw----  1 root dialout   4,  84 Ноя  2 10:34 ttyS20
crw-rw----  1 root dialout   4,  85 Ноя  2 10:34 ttyS21
crw-rw----  1 root dialout   4,  86 Ноя  2 10:34 ttyS22
crw-rw----  1 root dialout   4,  87 Ноя  2 10:34 ttyS23
crw-rw----  1 root dialout   4,  88 Ноя  2 10:34 ttyS24
crw-rw----  1 root dialout   4,  89 Ноя  2 10:34 ttyS25
crw-rw----  1 root dialout   4,  90 Ноя  2 10:34 ttyS26
crw-rw----  1 root dialout   4,  91 Ноя  2 10:34 ttyS27
crw-rw----  1 root dialout   4,  92 Ноя  2 10:34 ttyS28
crw-rw----  1 root dialout   4,  93 Ноя  2 10:34 ttyS29
crw-rw----  1 root dialout   4,  67 Ноя  2 10:34 ttyS3
crw-rw----  1 root dialout   4,  94 Ноя  2 10:34 ttyS30
crw-rw----  1 root dialout   4,  95 Ноя  2 10:34 ttyS31
crw-rw----  1 root dialout   4,  68 Ноя  2 10:34 ttyS4
crw-rw----  1 root dialout   4,  69 Ноя  2 10:34 ttyS5
crw-rw----  1 root dialout   4,  70 Ноя  2 10:34 ttyS6
crw-rw----  1 root dialout   4,  71 Ноя  2 10:34 ttyS7
crw-rw----  1 root dialout   4,  72 Ноя  2 10:34 ttyS8
crw-rw----  1 root dialout   4,  73 Ноя  2 10:34 ttyS9

ユーザーgammuはグループ に属していdialoutます。このデーモンを実行するユーザーを に変更するとroot、すべて正常に動作します。user の下でデーモンを動作させるために他に必要な権限が本当にわかりませんgammu

于 2016-11-02T08:54:47.957 に答える