Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

PHP Mail Pear Issue

Status
Not open for further replies.

johnnyasterisk

IS-IT--Management
Apr 2, 2008
26
0
0
IE
So here is one of those issues that I really hate.....

Appreciate anyones time if you can help.

I have a php script setup to send a blank email through my mail server. The script is called send_alert.php

When I run in from the CLI like so:

php send_alert.php

The email sends fine.

However when I try to browse to the send_alert.php file i get the following:

Failed to connect to mail.mailserver.ie:25 [SMTP: Failed to connect socket: Permission denied (code: -1, response: )]

I have confirmed that I can Telnet to port 25 on my mail server and it works fine from command line. Anyone else had this?

Regards,

Johnny
 
Sounds like the user as which the webserver runs doesn't have the right permissions to access the mail server.

----------------------------------
Phil AKA Vacunita
----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.

Web & Tech
 
Hi there thanks for your reply found the issue.... It was selinux.

Disabled SElinux and all is running fine.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top