Help with SMS sending Script

Thread Tools Search this Thread
Operating Systems Solaris Help with SMS sending Script
# 1  
Old 09-26-2011
Help with SMS sending Script

I would like assistance on a script that could send a text message to my mobile phone when I run a command and the text should be send only if a condition is met. I want to have a cron-job running every 10 minutes to check the system for overload conditons with a command:

more logfile.log | grep overloaded | wc -l

If the output of this command is greater than zero I want an SMS to be send to my mobile number. I would also want to customize the message to read, " Overload on Server 2"

Thanks in advance...
# 2  
Old 09-26-2011
if [ $? -eq 0 ]

# 3  
Old 09-26-2011
Can you elaborate? I am more interested in the code that sends the SMS and how to configure it to send to my mobile number eg +27780008000
# 4  
Old 09-26-2011
Easily You can send email to some SMS gateway
# 5  
Old 09-26-2011
Please elaborate your suggested solution and include how to do it and the associated commands. Thank you
# 6  
Old 09-26-2011

command can do it if you have access to some SMS gateway otherwise you can look for sms client
$ mailx -s subject phone_number@yourGSMProvider.tld < SMSBody

Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. AIX

Sending SMS from my AIX server

Hello AIXian :) I'm trying to send SMS from my AIX server, but I can't find any good solution :confused: Can anyone help me please to finish this task? Many thanks (2 Replies)
Discussion started by: Mohannad
2 Replies

2. UNIX for Dummies Questions & Answers

Sending sms from UNIX server

Hi, I am currently using Unix solaris server. I need to send a sms to my mobile whenever the CPU usage exceeds the threshold. I tried using mail command its not working. I am using Vodafone sim. Can anyone help me to find this as soon.:confused: And also exactly i don't know the SP name... (9 Replies)
Discussion started by: Arasu123
9 Replies

3. Shell Programming and Scripting

Sending sms through Shell script

Can anyone please help me to in scripting of sending sms through shell script (1 Reply)
Discussion started by: gargidas15
1 Replies

4. Solaris

Sending SMS from Solaris 10 - Help

All, I'm an in-experienced Solaris user, but our application is now hosted on Solaris 10, after being hosted on HPUX for many years. In some of our scripts, we send a text message to a support persons cell phone using the mailx command: echo "process count high on $HOST" | mailx -s... (2 Replies)
Discussion started by: turk22
2 Replies

5. Shell Programming and Scripting

Need help on setting up New shell script for sending SMS

Hello guys, I have been given a task to set up a new shell script, which needs to trigger the SMS(Short Messaging Service) to the phone numbers if an event occurs like filesystem goes beyond the threshold value of 70%. I am having the script to send a mail to recipients if that incident happens... (3 Replies)
Discussion started by: vpraveenn
3 Replies

6. HP-UX

sending sms through shell script

pl. if any one can help me in this . i wouldlike to know if there is a way to send sms through unix box. i have tried using mailx option. but what type of servers will be required . if any one can give me references... Thankxs in advance Regards, Alpa (1 Reply)
Discussion started by: alpareshamwala
1 Replies

7. Shell Programming and Scripting

Sending SMS Via Unix Script?

Hi, Is it possible to send sms to a mobile from unix box using Shell Scripting? I really wonder if anyone can help me with some information regarding how to setup the environment if possible. Iam also searching and trying to setup the same. My Environment: HP-UX B.11.11 U 9000/800... (2 Replies)
Discussion started by: Omkumar
2 Replies

8. UNIX for Advanced & Expert Users

Sending SMS

Hi, Can any one tell me how to send SMS using Unix shell scripting. My scenario is whenever my count on particular tables exceeds beyond certain limit i need to trigger out an sms to the client. It could be better if there is no third party tools involved in it. Thanks in advance... (9 Replies)
Discussion started by: sarojadevi
9 Replies

9. HP-UX

sending sms to handphone

Hi guys, anyone knows exactly how to send sms to handphone from a unix server? What is/are needed to perform such a task??Pls Advise. (1 Reply)
Discussion started by: alexjee
1 Replies

10. UNIX for Dummies Questions & Answers

Sending SMS on AIX unix

Is it possible to send SMS messages from an AIX unix machine? Preferable using a unix script. I hope somebody knows the answer. (3 Replies)
Discussion started by: chriss
3 Replies
Login or Register to Ask a Question