Community discussions

MikroTik App
 
-headstrong-
Member
Member
Topic Author
Posts: 377
Joined: Thu Jun 05, 2008 8:04 pm
Location: South Africa

GSM modem to send sms when highsight down?

Mon Nov 17, 2008 10:07 pm

Hi guys

Is it possible to setup a script or something which will monitor the network and send an sms to the technicians if a highsight goes down? Will the dude help?

thanks
 
itsh.net
Member Candidate
Member Candidate
Posts: 115
Joined: Mon Jan 23, 2006 12:00 pm
Location: Germany
Contact:

Re: GSM modem to send sms when highsight down?

Tue Nov 18, 2008 2:04 pm

 
-headstrong-
Member
Member
Topic Author
Posts: 377
Joined: Thu Jun 05, 2008 8:04 pm
Location: South Africa

Re: GSM modem to send sms when highsight down?

Wed Nov 19, 2008 11:43 am

Thanks for that..

how can I modify the script to check wait for 5 ping losses instead if 1. Coz every now and then there is a bit of packet loss and I do not want to receive an sms just because of that
 
InoX
Forum Guru
Forum Guru
Posts: 1969
Joined: Tue Jan 09, 2007 6:44 pm

Re: GSM modem to send sms when highsight down?

Wed Nov 19, 2008 12:11 pm

I'm curios of that. I'm sick of false alarm. 5-20 timed-out pings will be good.
 
User avatar
bellis
newbie
Posts: 49
Joined: Wed Nov 05, 2008 1:15 am
Location: Woodland, WA
Contact:

Re: GSM modem to send sms when highsight down?

Wed Nov 19, 2008 10:40 pm

did this a while back with dude notifications, first sending sms via email ( mailto: 5551234567@sms.att.net), which is an old standard email to sms interface system that most every reputable cell provider has.

later realized that if my dude box lost inet, emails would never get out. now using a gsm gateway and having dude execute a .bat that notifies us via the gsm gateway, so now notifications are completely independent of our network.
 
-headstrong-
Member
Member
Topic Author
Posts: 377
Joined: Thu Jun 05, 2008 8:04 pm
Location: South Africa

Re: GSM modem to send sms when highsight down?

Wed Nov 19, 2008 11:30 pm

bellis...could you explain how your .bat file works? sounds very interesting
thanks
 
User avatar
bellis
newbie
Posts: 49
Joined: Wed Nov 05, 2008 1:15 am
Location: Woodland, WA
Contact:

Re: GSM modem to send sms when highsight down?

Thu Nov 20, 2008 2:40 am

In dude, create a new notification. Select execute locally, or server, depending on your deployment.

In the command box, insert

sms.bat [Device.Name] [Device.AddressesCommaList] [Device.NotesColumn]

Make sure you chose what events you want to trigger this notification and when you want it run in the schedule and advanced tabs

create a .bat file containing

"C:\Program Files\GnuWin32\bin\wget" -q --delete-after --post-data "bMobile=1&DEST=5551234567&HEXTEXT=%1 %2 is not responding to ping. %3.&Send=Send Now" http://192.168.1.1/smsSendNow.cgi
ping http://www.google.com -n 10
"C:\Program Files\GnuWin32\bin\wget" -q --delete-after --post-data "bMobile=1&DEST=5551234567&HEXTEXT=%1 %2 is not responding to ping. %3.&Send=Send Now" http://192.168.1.1/smsSendNow.cgi


ensure you place your phone numbers in place of 5551234567, and set the 192.x.x.x to the ip of your gsm gateway

this should sms both devices. if you only want one person to receive an sms, remove ping http://www.google.com and everything after. if you need more than 2 phones messaged, add ping http://www.google.com and the cmd line for each additional number. the ping n-10 is simply to delay the sending of each message, as a gsm gateway can only send one message at a time.

this is exploiting a backdoor of our particular gsmn gateway, not sure if it will work on all, but it's simple enough and definitely worth a try

also, don't forget that your carrier's standard text messaging rates apply. we all have at&t phones, and our gsm gateway has a at&t sim card, so it all falls under our unlimited mobile to mobile messaging
"If it ain't broke, you're not tryin"
 
-headstrong-
Member
Member
Topic Author
Posts: 377
Joined: Thu Jun 05, 2008 8:04 pm
Location: South Africa

Re: GSM modem to send sms when highsight down?

Fri Nov 21, 2008 9:40 pm

Thanks bellis for that...Will definetly give it a try soon
 
User avatar
Bigfoot
Frequent Visitor
Frequent Visitor
Posts: 76
Joined: Sat Jan 15, 2011 10:41 am
Location: South Africa

Re: GSM modem to send sms when highsight down?

Mon Jun 03, 2013 3:46 pm

Hi -headstrong-
I use net Netwhatch to send sms when highsight is down or up, to do this set your host IP Address and intervals to 00:05:00 , timeout to 5000

Add this to Down section:

:log info "*************************"
:log info "* --- High sight One Down --- *"
:log info "*************************"
:local phonenumber { "+27821234567"; "+27828901234"; "+27847871234"; }

:local message "--- High sight One Down ---"

:foreach r in=$phonenumber do={

:put ("Sending SMS to " [:tostr $r])
:log info ("Sending SMS to $r")

/tool sms send usb3 [:tostr $r] message=[:tostr $message]

}

Who is online

Users browsing this forum: No registered users and 33 guests