Hi guys
Im new to forum so please dont be hard to me if I make any mistakes
I want to the following task:
1. I have a file lets say file1, which contains job names with numbers which have failed to start and ....
I can sort that file into another to get only the Job numbers with awk
the file1 looks like this
>cat file1
O575757.*
O262628.*
2. I want to send also the whole log from the jobs that have failed in a attachement in a mail.
want do to something like
for i in `ls /log_path/date/ | !!! need to specify the grep so that i will give output of those files with the names from file1`
then goes
do
uuencode $i $i
done | mailx -s "Files"
mymail@company.com
!!! Point is I dont know how to apply the pattern for ls do echo only the that match from the file1
I will appreciate any help
Thank you in advance