08-31-2013
Hi,
Do you need the email IDs to be read from the text file or from the database?
From the file, it is pretty much easy. From the database, you can use SQL Plus to read the field values from the database and store it in a variable for further processing. Use
this link for code samples on how to use SQL Plus in Unix.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
hi,
i am trying to send mail with attachment to web-based email client like gmail.com using mailx. the problem is it is displayed in content rather than as attachment.
the code i am using is as follows,
uuencode test1.txt test1.txt | mailx -s "test only" aaaa@gmail.com
does anyone... (1 Reply)
Discussion started by: randomcz1
1 Replies
2. UNIX for Dummies Questions & Answers
Hi
Can any one help me out ?
I am trying to send an autogenerated mail with an attachment to bulk of users using 'MAILX' and 'UNENCODE' . I have used it as follows
X " ( cat /sastemp/body.txt; uuencode Test.xls.gz Test.xls.gz ) | mailx -s 'Testing' ' abcd@yahoo.com , efgh@gmail.com ' "
... (9 Replies)
Discussion started by: manas6
9 Replies
3. Shell Programming and Scripting
hi,
I want to send mail to DL...
i am sending email to single id using mailx .. how to send to group of ids? :confused:
i am using a file which conatins all the ids,
is there any other way to send mail without creating the DLfile?
DL=path\file.txt
mailx -s "Info BG is now... (4 Replies)
Discussion started by: sreelu
4 Replies
4. Shell Programming and Scripting
Hi All
can someone help please create a bash script.
Here's a scenario:
1. I have a directory where it's a destination for scanned documents. e.g. /dest/scan
2. The filename is in the form IDNumber_Category. e.g. 123456_notes.pdf
3. The first part of the script is to rename the... (1 Reply)
Discussion started by: aemestech
1 Replies
5. Shell Programming and Scripting
Hello ,
I am trying to write a unix shell script to compare folder permission to say drwxr-x-wx and then send an email to my id in case the folders don't have the drwxr-x-wx permissions set for them .
I have been trying to come up with a script for few days now , pls help me:( (2 Replies)
Discussion started by: nairshar
2 Replies
6. Shell Programming and Scripting
i have below code to count number of rows in file1.txt, if the row count is more than one then i have sending an email along with file1.txt attached and fail the process(do nothing if count is <=1),
if I test individually count part works good but when i include the email part its not working,... (1 Reply)
Discussion started by: srini_106
1 Replies
7. Shell Programming and Scripting
I have written a shell script that calls below sql file. It is not sending the query data in table in the body of email.
spool table_update.html;
SELECT * FROM PROCESS_LOG_STATS where process = 'ActivateSubscription';
spool off;
exit;
Please use code tags next time for your code and data.... (9 Replies)
Discussion started by: Sharanakumar
9 Replies
8. Shell Programming and Scripting
hi,
I added an email id to a list of existing aliases in .mailrc on my unix box, using vi editor. However, the new id has not been receiving any mails from the box.
Kindly help as to what needs to be done here. Does the box need to be rebooted for these changes to reflect? Is there any other... (5 Replies)
Discussion started by: qwerty000
5 Replies
9. Solaris
Hi how to send below prstat script output into table format and send through email?
prstat|awk '{ if ($9 >= 5) print $0 }' (17 Replies)
Discussion started by: tharmendran
17 Replies
10. UNIX for Beginners Questions & Answers
HI Team,
I am working on reading hive table and send email in email body using shell script, can you please help on fixing the errors: I have 6 columns in my hive table and trying to send the email in the mail body.
below script:
#!/bin/bash
hive -e 'SELECT count(*) from db.table' >... (4 Replies)
Discussion started by: Mi4304
4 Replies
LEARN ABOUT DEBIAN
mbot.conf
mbot.conf(5) File Formats Manual mbot.conf(5)
NAME
mbot.conf -- mbot configuration file
SYNOPSIS
mbot.conf
Description
mbot.conf is organized in sections where you can associate handlers to mails.
When mbot receive a mail, it will search for a section having a name which match the mail subject, then use the associated handler. So the
name of the section will depend on the subject to use, and the parameters to be defined in this section will depend on the selected han-
dler.
Here is a list of available handlers:
GoogleHandler
Used to perform some search with the well known search engine
UrlHandler
This one allows to download some url and attach its content to the return mail, with the mime type properly set.
NewsHandler
You can also send some news (with images) to mbot, it will fill your database with it. Currently supported RDBMs are PostgreSQL
and MySQL, so you will have to choose between PgNewsHandler and MyNewsHandler.
PipeHandler
This one will make mbot call an arbitrary given command!
Default and common options
For each section we have a common option who's:
HANDLER This option define for the current section which Handler will be used.
WHITE_LIST
Here we define which are the e-mail addresses allowed to use associated Handler. Only e-mails are stored here, like this:
name@domain.tld. If no BLACKLIST is defined then the sender MUST be in this list otherwise mail will be rejected
BLACK_LIST
This list contains blocked emails. If sender is in this list, mbot won't be allowed to handle the request. If BLACK_LIST exists
but not WHITE_LIST then every sender who's not in this list will be allowed to use this Handler. The format of the list is:
["email@domain.tld", "email2@anotherdom.tld"]. It's the same as WHITE_LIST.
Default options:
MBOT_ADDRESS
Email address used in the response.
LOG_LEVEL Here we tell the Logger which level we want to log to syslog. Those levels are, from lower to higher, emerg - alert - crit - err
- warning - notice - info - debug.
Handler's options
GoogleHandler's options:
HOST This is the first for this Handler, it define the host for the searching engine.
BASE_URL Define here the string that is usually used by the searching engine.
UrlHandler's options:
MAILSIZE This option define the maximum mail size while mbot fetch url, sender will receive error message if mail size exceed
this value.
ATTSIZE For each attachement we define a size behind which mbot will raise an error.
NewsHandler's options:
HOST This is the FQDN for the database server.
DB The name of the database.
DB_USER Username to add entry into database.
NEWS_TBL Name of the table used by the Handler.
NEWS_TBLSQ
Name of the sequence table used by the Handler. Usually used with Postgres server's.
ATTACH_PATH
Used if sender attach an image with his mail, in this directory mbot will resize image to store it as normal and thumb-
nail size into database.
tnX and tnY
These are the options for thumbnail resizing.
SITE This is a list in which mbot will select the site according to the receiver email. It will be used to feed the data-
base.
PHOTO_TBL This option is optionnal, it will be used only if you want to have pictures associated to news.
PHOTO_TBLSQ
Name of the sequence table used by the Handler for the photo table. Usually used with Postgres server's.
Note that there is no option for PipeHandler.
Bugs
Please report bugs to the authors.
See Also
mbot(1)
Authors
mbot was writen by Dimitri Fontaine dim@tuxfamily.org and Christophe Truffier nah-ko@tuxfamily.org.
mbot.conf(5)