473,385 Members | 1,311 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

how to mail from unix shell script?

Hi,


#! /bin/bash
x=50
if [ $x -gt 25 ]
then
mail -s "$x is greater than 25" email@address
fi


i have run this command on unix shell script...
their is no error but i am not getting the mail
can anybody tell me what may be the reason??
Apr 14 '11 #1
1 2183
sicarie
4,677 Expert Mod 4TB
What happens when you run

mail -s "$x is greater than 25" email@address

without the rest of the script? Do you get an error? Do you get mail? Is the mailserver installed and all processes started?
Apr 18 '11 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: nidhikhandelwal | last post by:
I am calling a unix shell script from a perl script by using the following system command: system("./readfile_new.sh"); but it seems the unix script readfile_new.sh is not being called. Can...
0
by: Aashif | last post by:
I want to call Unix Shell script which is available in other Server (Unix server) from windows application using C#. Currently the shell script runs the C program but the GUI is not good, So I want...
9
by: sohan | last post by:
Hi, I want to know how to connect and execute a db2 query from inside a UNIX shell script. Details: We have a unix shell script. We need to execute multiple db2 sql queries from this shell...
0
by: Purple Haze | last post by:
I have a stored procedure which returns a resultset. I am calling that stored procedure from UNIX shell script. I want the data in the result set to be exported to a .csv file. How can I do this...
0
by: INCANDESCENT | last post by:
Hi All , Could any one of you tell me , if we can call a Unix shell script from VB forms ?? VB is used for client interaction , i have developed program using unix script which internally calls...
2
by: gagandutta01 | last post by:
Hi, Can anyone tell me how to execute a function declared in Oracle Package from Unix shell script? I created a shell script and after connecting to oracle database i am using exec @...
0
by: abhishek | last post by:
any way by which i can trigger a unix shell script from a button click.after that i should display an error message if the script was'nt executed successfully.Please help!!!
3
by: regnumber | last post by:
Hi. I am new to Unix. I need to write a Unix Shell Script to extract records from the table and write those extracted datas to a text file. DB using is DB2. Can anyone give me some sample...
1
by: Koteswara Rao K | last post by:
Hi, How to get server file( UNIX Server) to local desktop(Windows desktop) Using unix shell script Program. Thanks & Regards Koteswara Rao Kavuri
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.