Skip to content

SMSFireBrigade

kabirkukreti edited this page Apr 9, 2013 · 4 revisions

Before troubleshooting

Whenever SMS services goes down on +91.96195.24420, call this Fire Brigade and run through the steps as below:

Pre-requisite

ssh access to atlas with root.Since some of the processes run as ‘root’.Root ( or sudo ) access to atlas is a pre requisite

Do not start minicom with runrouter

If you do probably some kind of contention ( or race condition ) may be created for the modem port

Get the log

Run the following commands as root or under sudo

Go to the directory

cd /srv/smsBEST/gateway 

Get the log ( live running )

tail -f rapidsms.log

This will tell you wha the situation is.Send an sms to the ChaloBEST number, you should see it and its reply in the log. The modem is polled by gateway for new messages. In an error or non working scenario, you should see either an error or nothing in the log,If this happens then we troubleshoot the mode

Troubleshooting

You should do folloing as root or as sudo.

stop supervisor

The runrouter cannot be stopped ny simply killing it, as it is goverened by supervisor.This restarts the process, on its absence. To stop runrouter

/etc/init.d/supervisor stop

Kill runrouter after that

Now that the supervisor has been stopped, we can kill runrouter without worrying about it getting restarted. TO kill it use folowing commands:

Find the runrouter process

ps aux | grep "runrouter" 

This will give you give you router’s process id ( pid for short).It is a 4 -5 digit number, in the frst 3 or so columms of the output of grep. Now kill the process

pid kill <pid>

Make sure that the process is gone, by running the find command said above once more.If it still appears, make sure you have

Minicom procedures

Now we troubleshoot through minicom

Goto minicom

Type minicom in shell and press enter ( requires sudo )

Get all the messages from the modem

AT+CMGL=? - Signal to list messages ( unread ones )

Command to delete messages

AT+CMGD=<number> - Delete message <number>
AT+CMGD=1 - Delete message 1

Command to delete all messages and clear message cache

repeat AT+CMGD = x -> x goes from 1 to 25

Since there are 25 messages

Exit minicom

Exit minicom,after all this

start supervisor

/etc/init.d/supervisor stop

This will restart the runrouter process

If you still get error messages ( advanced troubleshooting )

Note of caution: The following steps are to be performed in the server room of HBCSE, please be careful.If you are having confusion or doubt as to what is to be done, please ask someone who knows the process to be along. Taking one of the administrators for this task is highly recommended.

Please do the process of stopping runrouter and minicom, before attempting the following

Check for network

Simply call the number up, if its rings, the sim is receiving network.

Remove and plug in the antenna

CAUTION: DO NOT DO THIS ALONE FOR THE FIRST TIME !

Please do it along with someone, who has done it already before attemting this yourself, to be safe.

The antenna is a coaxial cable screwed on to the modem, to the left.Unscrew it and re fit it.

After this again call the number again, to make sure that sim is receiving network

Restart modem

CAUTION: DO NOT DO THIS ALONE FOR THE FIRST TIME !

If you are doing this for the first time, please take some one who knows setup along.

The modem is kept on top of a power supply, remove the cable attached to the power supply and reattach it.This will reboot the modem.

Note of caution

The advanced troubleshooting’ section should be done ideally with someone who knows and is experienced with the procedures.

I will also be putting pictures of the setup later

Clone this wiki locally