LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 10-16-2006, 10:19 PM   #1
fakie_flip
Senior Member
 
Registered: Feb 2005
Location: san antonio, texas
Distribution: Fedora 64 bit RAID0 + LUKS, CentOS (server), Backtrack, Gentoo Hardened
Posts: 1,440

Rep: Reputation: 80
sendmail wont send mail


I never received this email. I tried many times. What is the problem?

Code:
chris@debian:~$ banner -w80 "linux" | sendEmail -t christopher.lemire@gmail.com -f root@chris1.myftp.org -u "tux"
Reading message body from STDIN because the '-m' option was not used.
If you are manually typing in a message:
  - First line must be received within 60 seconds.
  - End manual input with a CTRL-D on its own line.

Oct 16 21:40:51 debian sendEmail[24656]: Message input complete.
Oct 16 21:40:59 debian sendEmail[24656]: Email was sent successfully!
chris@debian:~$
Nothing is wrong with my sendmail configuration if you are thinking that. My script runs fine by cron to email me about my system updates, and I receive the emails. This is it.

Code:
chris@debian:~$ cat myapt
#!/bin/bash
if [ `whoami` != "root" ]; then
   echo "You must be root to execute this script."
   exit
fi
apt-get update
apt-get upgrade -y
echo "----------------------------------------------" >> /tmp/mylog
echo "Apt successfully updated the system:" >> /tmp/mylog
echo $(date) >> /tmp/mylog
echo >> /tmp/mylog
ls -luh /var/cache/apt/archives/ >> /tmp/mylog
echo >> /tmp/mylog
cat /tmp/mylog | sendEmail -t christopher.lemire@gmail.com -f root@chris1.myftp.org -u "Re: Apt successful system update" -q
cat /tmp/mylog | tee -a /var/log/pkgsbyapt
rm -f /tmp/mylog
apt-get clean
exit 0
chris@debian:~$

Last edited by fakie_flip; 10-17-2006 at 04:41 PM.
 
Old 10-16-2006, 11:24 PM   #2
jantman
Member
 
Registered: Nov 2005
Location: New Jersey, USA
Distribution: SuSE
Posts: 492

Rep: Reputation: 31
Quote:
Originally Posted by fakie_flip
Code:
If you are manually typing in a message:
  - First line must be received within 60 seconds.
  - End manual input with a CTRL-D on its own line.
Did you read the MAN file for sendmail?

And sendmail is a pain in the @$$, I'd recommend using MailX.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Mail Server Issues; Can't Send E-mail (using sendmail) Vegetarian Smoker Linux - Software 1 06-18-2006 02:16 PM
Sendmail cannot send mail rubenscript Linux - Networking 2 01-05-2006 04:38 AM
Qmail wont send mail to some addresses The_Nerd Linux - Software 5 01-03-2005 06:40 PM
Perl form wont send mail calmbomb Linux - Software 4 11-07-2004 10:08 AM
Can't send mail with Sendmail familyman Linux - Software 3 09-15-2004 10:30 AM


All times are GMT -5. The time now is 07:00 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration