|
|
SMS Server Tools 3 Community |
Welcome, Guest. The forum is currently read-only, but will open soon. |
Fri Aug 22, 2025 12:03 |
Page: 1
Keywords: Mode: All keywords (AND) |
Fri Sep 25, 2009 03:36
|
mattb: Hey Keke!
Thanks for all your help.
So basically I should have a dedicated GSM gateway for SMSes?
The current setup has astericks running two 2N via the PSTN ports for phone calls. A mac mini is plugged into one of the gateways via a serial port, this is what communicates with SMSD.
I assume that the commands from astericks are colliding with SMSD and causing my problems?
Thanks again. I am but a hack, I made a quick web front end for smsd and thought this would be a easy task....
|
Mon Sep 21, 2009 23:48
|
mattb: What is the version of smsd you are using?
Latest 3.1.5
the startup script sms3 should be used to start and stop the smsd
Previously I was not using the script to start smsd. I have changed that now. Though I am still getting a NO CARRIER error on the logs.
Somebody was trying to make a call, but it was not a process which was logging to the trouble log. It looks like there was another process running which was using the same modem. As there are answers like CSQ and CREG, this another process must be device handler of smsd.
The two GSM modems are used for the phone system via astricks but are not connected via the serial port, which I use to connect the GSM modem to the MAC for the SMSing. Could this be my problem? Another company handles the phone system so I am unaware of there setup beyond that it uses astericks.
Thanks again.
|
Sat Sep 19, 2009 03:13
|
mattb: Hey!
I thought that my load was not very heavy. I am still trying to iron out the kinks in my setup.
This is what 'ps -e' gives me, currently it appears to be running but no messages are being sent or received. Do you know why the brackets are around one of the processes?
41500 ?? 0:03.44 smsd
41501 ?? 0:00.00 (smsd)
This is the trouble log after a day usage(not heavy). I have seen this before. It appears the modem is failing to communicate. Is it possible the GSM modem is not initialized correctly? Or maybe the signal is dropping out.
2009-09-18 15:20:45,3, GSM1: Unexpected input: NO CARRIER NO CARRIER NO CARRIER NO CARRIER NO CARRIER NO CARRIER NO CARRIER NO CARRIER NO CARRIER NO CARRIER NO CARRIER NO CARRIER
2009-09-18 15:20:45,7, GSM1: -> AT
2009-09-18 15:20:45,7, GSM1: Command is sent, waiting for the answer
2009-09-18 15:20:45,7, GSM1: <- OK
2009-09-18 15:20:45,6, GSM1: Pre-initializing modem
2009-09-18 15:20:45,7, GSM1: -> ATE0+CMEE=1
2009-09-18 15:20:45,7, GSM1: Command is sent, waiting for the answer
2009-09-18 15:20:46,7, GSM1: <- +CSQ: 21,0 OK
2009-09-18 15:20:46,6, GSM1: Checking if modem needs PIN
2009-09-18 15:20:46,7, GSM1: -> AT+CPIN?
2009-09-18 15:20:46,7, GSM1: Command is sent, waiting for the answer
2009-09-18 15:20:56,7, GSM1: put_command expected (READY)|( PIN)|( PUK)|(ERROR), timeout occurred. 1.
2009-09-18 15:20:56,7, GSM1: <- +CREG: 0,1 OK
2009-09-18 15:20:56,2, GSM1: PIN handling: expected READY, modem answered +CREG: 0,1 OK
2009-09-18 15:20:56,2, GSM1: Modem handler 0 terminated abnormally. PID: 41501.
2009-09-18 15:20:47,7, GSM1: -> AT+CREG?
2009-09-18 15:20:47,7, GSM1: Command is sent, waiting for the answer
2009-09-18 15:20:57,7, GSM1: put_command expected (\+CREG:.*OK)|(ERROR), timeout occurred. 1.
2009-09-18 15:20:57,7, GSM1: <-
2009-09-18 15:20:57,3, GSM1: Error: Unexpected answer from Modem after +CREG?, waiting 1 sec. before retrying
When I run the log in debug(7) level AT+CREG? returns normally....
Thanks again.
-M@
|
Fri Sep 18, 2009 02:17
|
mattb: Thanks again Keke,
I am receiving emails now, thanks.
In terms of volume 30-50 SMS's at once is really not to much for a single server and single GSM modem? I have another GSM modem I can use if this would assist in breaking the load up? As I am unaware of what setups and loads people typically use.
I'm assuming I have a light load and the one server is enough to deal with my load?
Cheers.
|
Thu Sep 17, 2009 03:09
|
mattb: Hey Keke, would there be any proformance loss from running the log level at debug(7) for long periods of time?
Cheers
|
Wed Sep 16, 2009 11:24
|
mattb: Awesome!
I will give it a try!
You said before that the event handler shouldn't cause the process to break, I have been receiving alerts with every message could this be simply because I have the script returning 1 and not 0?
Thanks Keke, you are doing an great job in the forums!
:D :D
|
Wed Sep 16, 2009 10:47
|
mattb: Hey Keke!
The problem occured first when about 50 messages were sent at once. Up to that point we had problems for at least 3 days though usage was only testing, this was about just simple back and forth to make sure the database was storing messages correctly.
This is one of the process termination events in the logs from a few days ago. When the bulk messages were sent. The process had been up for a few days prior though.
2009-09-14 16:18:02,7, GSM1: Command is sent, waiting for the answer
2009-09-14 16:18:09,2, smsd: Conflict with .LOCK file in the spooler: /var/spool/sms/outgoing/FRprMb /var/spool/sms/checked
2009-09-14 16:18:09,2, smsd: Fatal error: Cannot move /var/spool/sms/outgoing/FRprMb to /var/spool/sms/checked. Check file and dir permissions.
2009-09-14 16:18:09,2, smsd: Smsd mainprocess terminated abnormally. PID: 47428.
2009-09-14 16:18:11,7, GSM1: <- +CMGS: 217 OK
2009-09-14 16:18:11,5, GSM1: SMS sent, Message_id: 217, To: 0431437189, sending time 12 sec.
2009-09-14 16:18:11,7, GSM1: Running eventhandler: /usr/local/bin/receiveEvent.sh SENT /var/spool/sms/checked/FRprMb 217
2009-09-14 16:18:11,3, GSM1: Done: eventhandler, execution time 0 sec., status: 256
2009-09-14 16:18:11,6, GSM1: ALERT (continues, 81): problem with eventhandler, result 1
2009-09-14 16:18:11,6, GSM1: Deleted file /var/spool/sms/checked/FRprMb
2009-09-14 16:18:11,2, GSM1: Modem handler 0 terminated. PID: 47429, was started 09-09-13 16:34:58.
Also I get two processes running. This is what 'ps -e | grep sms' returns.
21484 ?? 0:00.04 smsd
21485 ?? 0:00.25 smsd
22119 ttys000 0:00.00 grep sms
Is that correct?
I will also note that the process was restarted and I preformed a test by sending the about 50 text messages of about 100 characters and requesting a reply. Everything went to plan The messages went out and I also got the replys. It was not until the day after the process terminated again. I lost the log with that termination info.
Thanks again.
-Mattb
|
Wed Sep 16, 2009 09:38
|
mattb: Hey everybody!
I must say great tool set, its easy and straight forward.
I'm currently using SMS tools 3 on OSX it works, not sure if anybody else has tried this or not. But I can confirm this.
With that out of the way I do have some problems they may or may not relate to OSX.
I run a fairly simple setup 1 GSM modem ( possibly 2 ) and a single server. The server is also used for a database system that about 3-5 computers access throughout the day. It is not a very heavy load(?).
I have created a web front end for SMS tools to be used on the client machines. Everything works....
Since it has been put to use I have had to restart the process several times, if fact it has not lasted a full day yet.
The problems have been, first my event handle script returns an error:
Running eventhandler: /usr/local/bin/receiveEvent.sh RECEIVED /var/spool/sms/incoming/GSM1.4k2LUj
2009-09-16 19:11:19,3, GSM1: Done: eventhandler, execution time 0 sec., status: 256
2009-09-16 19:11:19,3, GSM1: ALERT: problem with eventhandler, result 1 :oops:
I would like to use the alert handler but would like some guidance or examples.
Eventually the smsd process fails and and no more sms-ing for the office.
This is my event handler script.... No doubt I'm doing something wrong.
#!/bin/sh
if [ "$1" == "SENT" ]; then
exit 1
fi
if [ "$1" == "FAILED" ]; then
POST=`formail -zx From: < $2`
SENT=`formail -zx Sent: < $2`
MESSAGE="FAILED"
FROM="0"${POST:2}
SQL_ARGS="-h localhost -u root -ppassword -D db -s -e"
mysql $SQL_ARGS "INSERT INTO inbox (number, text, sent) values (\"$FROM\", \"$MESSAGE\", \"$SENT\");"
exit 1
fi
if [ "$1" == "RECEIVED" ]; then
POST=`formail -zx From: < $2`
SENT=`formail -zx Sent: < $2`
MESSAGE=`formail -I "" < $2`
FROM="0"${POST:2}
SQL_ARGS="-h localhost -u root -ppassword -D db -s -e"
mysql $SQL_ARGS "INSERT INTO inbox (number, text, sent) values (\"$FROM\", \"$MESSAGE\", \"$SENT\");"
fi
exit 1
EOF
Thanks in advance
-M@
|
Wed Sep 16, 2009 09:01
|
mattb: Description: A back-end for a sms communication within a small-medium logistics company
Usage: Private internal use.
Number of users: 6 max( currently)
Deployment: 1 office
Volume of 160-character SMs per day: 30-60 (typical); 70-100 (peak)
Hardware: A single mac mini and one SMS gateway ( Siemens S55 )
|
Page: 1
Time in this board is UTC.
|
|
|
 |
|
 |
|