LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 04-29-2001, 10:34 PM   #1
lesath
LQ Newbie
 
Registered: Apr 2001
Posts: 3

Rep: Reputation: 0
Question


Here's what I'm trying to do,

I want to set something up so when my Redhat 7 machine boots up it automatically sends an email (with an attachment) to my email address.

The best way I could think of is to have it just as one big command line. With PINE I found I could do:

pine superspud@hotmail.com -attach /home/lesath/filename

but then it still won't automatically send the email and exit pine.

If anyone has an idea, it'd be greatly appreciated. Thanks!

j.
 
Old 04-30-2001, 04:18 AM   #2
webtoe
Member
 
Registered: Apr 2001
Location: Cambridge, England
Distribution: Slackware 10, Fedora Core 3, Mac OS X
Posts: 617

Rep: Reputation: 30
you would have to right a bash script.

this (unless you didn;t know) is a sort of programming language for bash. you can writ one to do what your need then add it to the start up sequence. unfortunatly im not that good at script writing (only just started learning C)so maybe some one else here might write you one or you might want to take a go yourself (its very useful).

i think you just need to put the above command you used to send the mail then have below that: killall pine

im not sure though

sorry that was useless

Alex
 
Old 04-30-2001, 08:18 AM   #3
woodchuck
LQ Newbie
 
Registered: Apr 2001
Posts: 9

Rep: Reputation: 0
This may work for you:
mail -s "I just booted" superspud@hotmail.com < /home/lesath/filename

It doesn't attach the file; the content of the email will be the file.
 
Old 04-30-2001, 05:24 PM   #4
lesath
LQ Newbie
 
Registered: Apr 2001
Posts: 3

Original Poster
Rep: Reputation: 0
Cool, worked great. Thanks a lot guys!

j.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
What email program can work with email header on pop3 server TruongAn Linux - Software 0 01-13-2005 11:48 AM
automatic email notification kallu Linux - General 2 11-27-2004 12:39 AM
How do I configure postfix master to forward all email to an email server ? hello321_1999 Linux - Software 1 11-18-2004 04:43 AM
How to Import Microsft outlook Email in any Red hat 9 Email Software mobassir Linux - Software 0 07-26-2003 04:08 AM
Automatic email sending with sendmail? Stingreen Linux - General 10 04-15-2002 02:55 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 09:15 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration