I got the problem fixed. It had nothing to do with Apache. It was all with the VM setup. On 6/17/15, 11:54 AM, "Patton, Billy N" <billy.patton@xxxxxxxxx> wrote: >I'm having a problem sending email from my app. >To simplify at the top of my cp.cgi I added a little code then blocked >the rest of my script with _END_ . >Below is my entry cp.cgi >From a command line if I execute : perl cp.cgi >I'll get an email. >If I bury this within my code, at the desired location, I get nothing, no >errors, no email. >I've tried replacing smtp.west.com with the actual IP address, same >results. > >From the command line I've checked : >getsebool -a | grep mail >allow_postfix_local_write_mail_spool --> on >httpd_can_sendmail --> on >logging_syslogd_can_sendmail --> on > >This is on a VM. We have other VMs able to send email. >It was suggested that it might firewall problem. >From the command line I can ping the server. >I can put that snippet of code in a file, execute and receive an email. > >cp.cgi >===================== >#!/usr/bin/perl > >use Mail::Sender::Easy qw (email); > >email({'from' => 'bnpatton@xxxxxxxx', > 'to' => 'bnpatton@xxxxxxxx', > 'subject' => 'test', > 'smtp' => 'smtp.west.com', > '_text' => 'test email' > }); > >_END_ >... >================== > > > > > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx >For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx