- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: sending text from file via e mail
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2003 06:36 AM - last edited on тАО03-10-2013 10:30 PM by Cathy_xu
тАО04-22-2003 06:36 AM - last edited on тАО03-10-2013 10:30 PM by Cathy_xu
sending text from file via e mail
I have a file which gets stuff written in it every now and then... what would be the best approach to get that data sent to my e-mail account.
I will try to work it into a crontab if thats possible too.
P.S.This thread has been moved from HP-UX>Databases to HP-UX > languages-HP Forums Moderator
- Tags:
- crontab
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2003 06:44 AM
тАО04-22-2003 06:44 AM
Re: sending text from file via e mail
Couple of ways.
1) If you want the data in the body of the msg
cat filename | mailx -s "Your Subject Here" user@company.com
2) If you want it as an attachment
uuencode filename filname.out | mailx -s "Subject line" user@company.com
HTH,
Jeff
P.S. What's a spod?
- Tags:
- mailx
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2003 06:47 AM
тАО04-22-2003 06:47 AM
Re: sending text from file via e mail
cat file | mailx -s "filename" -r return@sender send_to@name
also you can:
mailx -s "filename" -r return@sender send_to@name
< file
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2003 06:48 AM
тАО04-22-2003 06:48 AM
Re: sending text from file via e mail
tdate=`date +%m%d%y`
cp bob bob${tdate}
uuencode bob${tdate} bobfile | mailx -m -s "Subject" bob@bob.com
Put this file into your crontab
Thanks
Zafar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2003 06:48 AM
тАО04-22-2003 06:48 AM
Re: sending text from file via e mail
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2003 06:49 AM
тАО04-22-2003 06:49 AM
Re: sending text from file via e mail
You can write a script that check the file every so often and if newer then executed what Jeff posted. This way you won't get the file every time the script is executed.
Regards,
DR
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2003 07:01 AM
тАО04-22-2003 07:01 AM
Re: sending text from file via e mail
in answer to your question... a 'spod' is another term for a person who's soul is gradually been sucked into a p.c. (via any spare usb port)
others like to use the word geek however i prefer the term spod - in my opinion it sounds more upper class!
Thanks for your suggestions
back to the box
Bob (the spod!)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2003 07:57 AM
тАО04-22-2003 07:57 AM
Re: sending text from file via e mail
never heard of a spod before today.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2003 08:48 AM
тАО04-22-2003 08:48 AM
Re: sending text from file via e mail
This job can and has been called from cron scripts in my shop.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-22-2003 06:54 PM
тАО04-22-2003 06:54 PM
Re: sending text from file via e mail
http://hpux.ee.ualberta.ca/hppd/hpux/Users/mpack-1.5/
"mpack/munpack version 1.5 for unix
Mpack and munpack are utilities for encoding and decoding
(respectively) binary files in MIME (Multipurpose Internet Mail
Extensions) format mail messages. For compatibility with older forms
of transferring binary files, the munpack program can also decode
messages in split-uuencoded format.}"
Rgds...Geoff