E-mail notifications not working

General discussion of Mantis.

Moderators: Developer, Contributor

Post Reply
acalvod
Posts: 7
Joined: 07 May 2010, 17:13

E-mail notifications not working

Post by acalvod »

Hello. I have installed Mantis BT in my server, and everything works fine except that I do not receive any e-mail notification.
It seems my SMTP server is working fine, because I do not get any error messages in my logs. It seems that Mantis even does not try to send any e-mail.
For example, if I ask to send an e-mail to remember my password, when I fill the fields and clic SUBMIT, it returns to the main page without providing information, and any e-mail is received.

Can anyone help me? Thanks!
atrol
Site Admin
Posts: 8536
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: E-mail notifications not working

Post by atrol »

acalvod wrote:if I ask to send an e-mail to remember my password, when I fill the fields and clic SUBMIT, it returns to the main page without providing information, and any e-mail is received
Do you use version 1.2.0? If yes, upgrade to 1.2.1 where this is fixed.
Please use Search before posting and read the Manual
acalvod
Posts: 7
Joined: 07 May 2010, 17:13

Re: E-mail notifications not working

Post by acalvod »

Thank you very much! The problem with "lost password application" is solved with version 1.2.1, but I cannot receive any e-mail.
Maybe it is a problem with my PHP.ini or SMTP configuration?

This is the SMTP content of my PHP.ini:

Code: Select all

[mail function]
; For Win32 only.
SMTP = localhost
smtp_port = 25
username = MyWindowsServerUser
password = MyWindowsServerPassword
; For Win32 only.
sendmail_from = info@MYSERVERNAME
This is the IIS SMTP Virtual Server configuration:
* Access Control: Integrated Windows Authentification
* Connection control: allow ALL
* Relay restrictions: allow ALL

Thank you very much for your help!!
atrol
Site Admin
Posts: 8536
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: E-mail notifications not working

Post by atrol »

Did you configure the following settings in config_inc.php?
Not all of them are needed to get email work, but there can be problems, for example if $g_return_path_email is not properly set

Code: Select all

$g_phpMailer_method = PHPMAILER_METHOD_SMTP;
$g_smtp_host = 'yourHost';
$g_smtp_username = 'yourUser';
$g_smtp_password = 'yourPassword';

# if not standard $g_smtp_port = yourPortIfNotStandard;
# if not standard $g_smtp_connection_mode = 'ssl' or 'tls'

$g_from_email = 'from@example.com';
$g_administrator_email = 'administrator@example.com';
$g_webmaster_email	 = 'webmaster@example.com';
$g_return_path_email = 'return@example.com'';
Please use Search before posting and read the Manual
acalvod
Posts: 7
Joined: 07 May 2010, 17:13

Re: E-mail notifications not working

Post by acalvod »

Thank you very much Atrol. I didn't have that file configured, but now I tried and still doesn't work.
I don't receive any e-mail, and all mail logs are empty.
I think it might be a problem with the configuration of my SMTP server, not concerning Mantis.
Note: I am not using ' ' when I provide the information below. Could it be the problem? Thanks!!

PHP.ini

Code: Select all

[mail function]
; For Win32 only.
SMTP = localhost
smtp_port = 25
username = MyWindowsServerUserAccount
password = MyWindowsServerPassword
; For Win32 only.
sendmail_from = info@mywebdomain.com
IIS SMTP Virtual Server configuration:

Code: Select all

* Access Control: Basic Authentification
* Connection control: allow ALL
* Relay restrictions: allow ALL
config_inc.php

Code: Select all

$g_phpMailer_method = PHPMAILER_METHOD_SMTP;
$g_smtp_host = localhost;
$g_smtp_username = MyWindowsServerUserAccount;
$g_smtp_password = MyWindowsServerPassword;
$g_from_email = info@mywebdomain.com;
$g_administrator_email = info@mywebdomain.com;
$g_webmaster_email    = info@mywebdomain.com;
$g_return_path_email = info@mywebdomain.com;
atrol
Site Admin
Posts: 8536
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: E-mail notifications not working

Post by atrol »

Sorry, I have no experience with IIS and SMTP on Windows (I am expert for nothing ;-) )
Yes, use '' in config_inc.php
Read these informations, especially to get an understanding which settings in which files are used depending on setting of $g_phpMailer_method
Maybe it's easier to get it run with $g_phpMailer_method = PHPMAILER_METHOD_MAIL (this is the default, where you started first)
http://docs.mantisbt.org/master/en/admi ... NFIG.EMAIL
http://www.php.net/manual/en/mail.confi ... p#ini.smtp
Please use Search before posting and read the Manual
acalvod
Posts: 7
Joined: 07 May 2010, 17:13

Re: E-mail notifications not working

Post by acalvod »

Thank you very much!!!
Post Reply