Shell script to compare text and send a mail

 
Thread Tools Search this Thread
Top Forums UNIX for Beginners Questions & Answers Shell script to compare text and send a mail
# 1  
Old 05-03-2018
Computer Shell script to compare text and send a mail

Hello,
Somebody can help me to develop a script for the below requirement

I have a 3 files in a directory which was dynamically changed everyday basis. I need a script to fetch the 1pattern of strings in each file. if the three matching pattern is same send a mail with subject as success else fail.

Thanks in advance.
# 2  
Old 05-03-2018
Is this a homework assignment? Homework and coursework questions can only be posted in the Homework & Coursework forum under special homework rules.

Please review the rules, which you agreed to when you registered, if you have not already done so.

If you did not post homework, please explain the nature of the problem you are working on, the source of the files you need to process, the format of the files you need to process, the patterns that you expect to find in those files, a couple of sets of sample input files (one set that should satisfy your requirements and one set that should generate an e-mail message [also showing the contents of that e-mail]), other desired outputs from those sets of sample input files, the operating system you're using, the shell you're using, and show us what you have written to try to solve this on your own.

If you did post homework in the main forums, please review the guidelines for posting homework and repost.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Shell script to send mail alert

Hi I have below shell script to send mail alert , however I want to add more functionality in this script and that is , script should only check that file between 9 am to 5pm , and if there is no activity in this time 9 am to 5 pm for 2hours then it should give me mail alert, please help... (2 Replies)
Discussion started by: scazed
2 Replies

2. Shell Programming and Scripting

A shell script to run a script which don't get terminated and send a pattern from the output by mail

Hi Guys, I am very new to shell script and I need your help here to write a script. Actually, I have a script abc.sh which don't get terminated itself. So I need to design a script to run this script, save the output to a file, search for a given string in the output and if it exists send those... (11 Replies)
Discussion started by: Sambit Sahu
11 Replies

3. Shell Programming and Scripting

Shell script to send mail alert

HI Guys, I am writing one shell script to send the mail alert to some email id's if the file not modified in last 10 mins but its not working, I believe MTIME is null string is wrong . can you please assist me on this. script :- filename="abc.txt" echo "Filename is $filename"... (1 Reply)
Discussion started by: abhigrkist
1 Replies

4. Shell Programming and Scripting

Compare the dates and send mail

Hi Guys, I am new to this fourm. Need your help to complete my requirment. Below is my requirment. Have to check expiry of the certificate. Compare the certificate expiry date with current date. If the difference is less than 30 days, need to send mail. #!/usr/bin/ksh... (2 Replies)
Discussion started by: rameshchukka
2 Replies

5. Shell Programming and Scripting

To send a mail through shell script

I want to send a mail through shell script,If it is possible Please give me a code. mail id : upload.xxx@example.com (8 Replies)
Discussion started by: kannansoft1985
8 Replies

6. UNIX for Dummies Questions & Answers

How to send e-mail from shell script ( C shell )?

Hi , How to send e-mail from shell script ( C shell ) . Mailx command is not working ( It didn't giving error also ). Please help me (2 Replies)
Discussion started by: arukuku
2 Replies

7. UNIX for Advanced & Expert Users

Send a mail when a shell script is modified

I would like to know, whether is there any command/tool in Linux (something like Oracle Trigger function) to send a mail if a particular shell script has been modified with details like, modification time, modified by, etc. Thanking in advance, (1 Reply)
Discussion started by: apsprabhu
1 Replies

8. Shell Programming and Scripting

Shell script to send a mail

Hi , I need to prepare a script which will check my database with specific to particluar table. If the row count exceeds a certain limit, i need to send a mail to a set of Recipients. Being new to unix, please guide me to complete this task. Advance thanks, Sekar. (4 Replies)
Discussion started by: Sekar1
4 Replies

9. Shell Programming and Scripting

shell script to send a mail

Hi, I need a shell script which runs in the backround for all the 24 hours and send a mail to us regarding the output of the prstat command when the load average increase above certain percent. kindly help me on this...... (1 Reply)
Discussion started by: jayaramanit
1 Replies

10. Shell Programming and Scripting

Send e-mail in Shell script

How to send an error mail from a shell script e.g. mail destination_adr@blabla.int "Message : here an error message " thanks, Ann. (1 Reply)
Discussion started by: annelisa
1 Replies
Login or Register to Ask a Question