12-15-2010
Can't configure sendmail to send mails to external SMTP Server
Hi all,I know, that this is very common issue, but I can't find where is the problem... I have Solaris 10 installed.I want to send mail to external SMTP server, like:echo "letter body"| mailx -s "subject"
test@test.comBut I donno what kind of changes I have to do in /etc/hosts and sendmail.cf or sendmail.mc files...I kindly ask someone to help me to configure the system.Thanks in advance,Roman
10 More Discussions You Might Find Interesting
1. Solaris
Hi, Can anyone pls. tell me how to access Active directory from solaris. I am looking at solution by which I can send mail notification from the logs generated by scripts, to the users on Exchange server. I am trying for a Perl-LDAP module , but don't realy know how to go for it (5 Replies)
Discussion started by: ganeshh
5 Replies
2. SuSE
Hi All,
I have a system running with Suse Enterprise Linux 9.0.
xyz# uname -a
Linux xyz 2.4.21-291-smp #1 SMP Tue May 24 14:07:45 UTC 2005 i686 unknown
I would like to configure postfix on this system for sending mails as a root user using "mail" command to smtp server (Windows System)... (5 Replies)
Discussion started by: jumadhiya
5 Replies
3. UNIX for Advanced & Expert Users
Hi,
We had an upgrade today morning and since then mailx command is not working.
I have been told to change the DNS to use host name as smtp.companyname.com instead of the IP address.
Can someone please help me out to know where can I change this on a Unix Server.
Thanks
Aman (5 Replies)
Discussion started by: chawlaaman
5 Replies
4. SCO
Did anyone know or can provide some instructions on how to setup smtp
for sendmail.
All I need to do is email files from sco thru my ISP smtp provider.
please help (3 Replies)
Discussion started by: miles556
3 Replies
5. UNIX for Dummies Questions & Answers
Hi Unix Gurus,
Please help me out here.
Please tell me the steps to conigure sendmail to receive emails (same way we configure outlook client in windows)?
Thanks in advance.
-Dejavu (1 Reply)
Discussion started by: DejaVu
1 Replies
6. Shell Programming and Scripting
i am new in AIX i am trying to write a script to take a backup for specific files on server to and check error log if backup success send email to administrator , script done except for sending mail , i try to configure sendmail on aix to use our exchange server to send emails but still get error... (0 Replies)
Discussion started by: ahmed_salah
0 Replies
7. Solaris
Hi,
Iam not able to send mails from solaris servers to external mailid (gmail,yahoo).I am able to send mails to internal mailids with in network.
Requesting you all to please help me to resolve this issue.
Thanks in advance.
Venkat (2 Replies)
Discussion started by: venkatasiva85
2 Replies
8. Red Hat
Hi,
We current use an email/hosted exchange server (provided by 3rd party company).
Our production DNS (RH5) server has got the MX rec configured for this 3rd party mail relay server. So in order to resolve hostnames to send outbound mails an A record entry is also required on the external... (1 Reply)
Discussion started by: Duffs22
1 Replies
9. Solaris
Hello Everybody !
I'm Harry from Athens Greece and i have a problem with my Sendmail 8.13.3 installed on Solaris SunOS ultra 5.10.
The problem is that when someone sends to us an e-mail and his e-mail address is like : xxxx@xxxx.com, our e-mail server adds up in the senders address a .com.gr... (2 Replies)
Discussion started by: Mcasim
2 Replies
10. Solaris
Hello,
I'm trying to configure sendmail with SMTP authentication on a SunOS 5.11 operating system. I have been read various documentation / tutorials and unfortunately is not working. I need help from someone who has configured smtp on this operating system.
When I try to send a mail, I have... (2 Replies)
Discussion started by: d4rkm4nx99
2 Replies
LEARN ABOUT DEBIAN
log::handler::output::email
Log::Handler::Output::Email(3pm) User Contributed Perl Documentation Log::Handler::Output::Email(3pm)
NAME
Log::Handler::Output::Email - Log messages as email (via Net::SMTP).
SYNOPSIS
use Log::Handler::Output::Email;
my $email = Log::Handler::Output::Email->new(
host => "mx.bar.example",
hello => "EHLO my.domain.example",
timeout => 120,
debug => 0,
from => 'bar@foo.example',
to => 'foo@bar.example',
subject => "your subject",
buffer => 0
);
$email->log(message => $message);
DESCRIPTION
With this output module it's possible to log messages via email and it used Net::SMTP to do it. The date for the email is generated with
"Email::Date::format_date".
Net::SMTP is from Graham Barr and it does it's job very well.
METHODS
new()
Call "new()" to create a new Log::Handler::Output::Email object.
The following opts are possible:
host
With this option you has to define the SMTP host to connect to.
host => "mx.host.com"
# or
host => [ "mx.host.example", "mx.host-backup.example" ]
hello
Identify yourself with a HELO. The default is set to "EHLO BELO".
timeout
With this option you can set the maximum time in seconds to wait for a response from the SMTP server. The default is set to 120
seconds.
from
The sender address (MAIL FROM).
to The receipient address (RCPT TO).
Additional options are cc and bcc.
subject
The subject of the mail.
The default subject is "Log message from $progname".
buffer
This opts exists only for security. The thing is that it would be very bad if something wents wrong in your program and hundreds of
mails would be send. For this reason you can set a buffer to take care.
With the buffer you can set the maximum size of the buffer in lines. If you set
buffer => 10
then 10 messages would be buffered. Set "buffer" to 0 if you want to disable the buffer.
The default buffer size is set to 20.
debug
With this option it's possible to enable debugging. The information can be intercepted with $SIG{__WARN__}.
log()
Call "log()" if you want to log a message as email.
If you set a buffer size then the message will be pushed into the buffer first.
Example:
$email->log(message => "this message will be mailed");
If you pass the level then its placed into the subject:
$email->log(message => "foo", level => "INFO");
$email->log(message => "bar", level => "ERROR");
$email->log(message => "baz", level => "DEBUG");
The lowest level is used:
Subject: ERROR: ...
You can pass the level with "Log::Handler" by setting
message_pattern => '%L'
flush()
Call "flush()" if you want to flush the buffered lines.
sendmail()
Call "sendmail()" if you want to send an email.
The difference to "log()" is that the message won't be buffered.
validate()
Validate a configuration.
reload()
Reload with a new configuration.
errstr()
This function returns the last error message.
DESTROY
"DESTROY" is defined and called "flush()".
PREREQUISITES
Carp
Email::Date
Net::SMTP
Params::Validate
EXPORTS
No exports.
REPORT BUGS
Please report all bugs to <jschulz.cpan(at)bloonix.de>.
If you send me a mail then add Log::Handler into the subject.
AUTHOR
Jonny Schulz <jschulz.cpan(at)bloonix.de>.
COPYRIGHT
Copyright (C) 2007-2009 by Jonny Schulz. All rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.14.2 2012-11-21 Log::Handler::Output::Email(3pm)