I'm testing Drupal on one site and I create a new account there is an info that the message has been sent to email address but so far message hasn't been delivered. First I entered Yahoo address and then Gmail address.

Does anyone know how long does it take that email for new members be delivered and what can be the reason if the message hasn't been delivered.

Is there some general patch for version 4.7 because there are also some problems with adding menu and menu items?

Thanks!

Comments

greggles’s picture

Drupal relies on a properly configured smtp server on your host. Does your host have one? What environment are you on (shared hosting, local linux desktop, WAMP, XAMP setup, etc.)?

Also, have you set the email address in admin/settings?

Sometimes the emails can get blocked by a spam filter, but making sure you have smtp installed and properly configured is the first step.

--
Growing Venture Solutions
Drupal Implementation and Support in Denver, CO

freespirit’s picture

Email address has been set in admin/settings Is there some option in Drupal where people can choose to disable/enable sending emails? Is there some good module for this?

greggles’s picture

What about the SMTP server? Is that installed?

--
Growing Venture Solutions
Drupal Implementation and Support in Denver, CO

freespirit’s picture

SMTP is installed, I don't know if that Drupal SMTP module will work, because I read some post where user wrote that it doesn't work with that either.

Does Drupal have option where administrator disable/enable sending emails? I don't know why Drupal give message that Email can not be sent. Please contact the administrator.

greggles’s picture

Where do you get the error message "Email can not be sent. Please contact the administrator."

You may want to turn on (or turn up) logging in the smtp software and then try to register a new account (which should trigger an email) and watch what happens. Perhaps there is a misconfiguration of your smtp server in some way.

--
Growing Venture Solutions
Drupal Implementation and Support in Denver, CO

lurchdog19’s picture

Sorry, I don't mean to hijack your thread but I too have a simliar problem and this looked so similar as to not start a new thread. For me when creating new members I get the error message

warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\wamp\www\drupal\modules\user.module on line 409.

Now I have not fixed it yet, but I did install Postcast server (free edition) to use as my email server. I set the smtp to localhost and nothing works for me.

thoughts??
(again not trying to hijack your thread, perhaps we can help each other)

Mike

sepeck’s picture

You error is in the error message

verify your "SMTP" and "smtp_port" setting in php.ini

You do not have a SMTP server defined in your php.ini file OR you do not have permission to send SMTP mail through that SMTP server. Neither of which are actually Drupal issues.

For the first, define a valid SMTP server. For the second, allow your Drupal server to relay mail through your SMTP server.

-Steven Peck
---------
Test site, always start with a test site.
Drupal Best Practices Guide -|- Black Mountain

-Steven Peck
---------
Test site, always start with a test site.
Drupal Best Practices Guide

lurchdog19’s picture

here is my settings in PHP.ini

freespirit do you have the same??

[mail function]
; For Win32 only.
SMTP = localhost

I also had

[mail function]
; For Win32 only.
SMTP = mail.charter.net

Nothing worked.

Eino Mäkitalo’s picture

There is no way tell in php.ini external smtp-server or is it....

There are lot of talk and responses in this chat, but nobody actually solves this issue but maybe this external smtp-module.

What is the best and right solution when you want to configure your linxux based drupal site to send email

* without installing local smtp mta
* using external smtp-server

This is drupal issue, because php is not solving it yet

- frustrated

gpk’s picture

Eino (and others who have not solved this problem)

If there is no outgoing mail server available to you on localhost then smtp.module (SMTP authentication support) should help, provided that you have access to an authenticated SMTP mail server, e.g. via your ISP or a 3rd party email service.

Regards
gpk

billye’s picture

Drupal SMTP manages to send out the test email "If you receive this message it means your site is capable of sending email.'

Log: error 07/21/2007 - 07:27 About to send email to: namexxxxxx@somedomain.com Billy

Details
Type error
Date Saturday, July 21, 2007 - 07:27
User Billy
Location http://somedomain.com/admin/settings/smtp
Referrer http://somedomain.com/admin/settings/smtp
Message About to send email to: namexxxxxx@somedomain.com
Severity notice
Hostname Some IP

Can anyone help me understand, why there's an error and what it means when it says "About to send" when I was able to get the test message.

This basically prevents people from registering on the website, using feedback, and registering for the forum. Otherwise drupal is pretty good for my needs except the email issue is a major headache.

*** Update: Feel free to ignore the log error, it was throwing me off where the SMTP was working properly. Registration works, Feedback form works, and Forum works. I am HAPPY.

angelopc’s picture

When a new member registers, there is no error message and the account details ARE sent to me (the admin). I can even use the contact form to send myself messages, but other members don't receive anything when I send it.

greggles’s picture

Sounds like your mail being sent to other hosts is being denied for some reason. Can you check for bounce messages or check your smtp log files to see if the messages are bouncing?

--
Growing Venture Solutions
Drupal Implementation and Support in Denver, CO

angelopc’s picture

It was actually TWO problems. It's fixed, now. One of the problems WAS that the mail was being bounced. The other was just a little tweak as far as WHO the mail was being sent from. "-f" (if that means anything to anyone)

Thanks for responding.

greggles’s picture

angelopc - that means a lot and thanks to you for closing the loop and letting us all know 1) that your problem is solved and 2) how you solved it. Very useful information for sure.
--
Growing Venture Solutions
Drupal Implementation and Support in Denver, CO

fordboy0’s picture

First off... Drupal 4.7 rocks my world! Now on to the meat...

I use Postfix for my MTA and I have set the a proper "from:" mail user (band@chubbyjams.com) in Administer>settings>general settings>Email address. When requesting a new password for a user (say jeff@chubbyjams.com) the mail doesn't go out.
Running
tail -f /var/log/maillog
I notice the following:

May  8 23:19:06 peter postfix/smtp[23784]: 3F58413850B: to=<band@chubbyjams.com>, relay=mail.one.net[64.89.70.104], delay=6, status=bounced (host mail.one.net[64.89.70.104] said: 553 5.1.8 <www@peter.jfeige.net>... Domain of sender address www@peter.jfeige.net does not exist (in reply to MAIL FROM command))

jfeige.net is my internal domain and peter is the hostname of the machine. www is the owner of the apache process. I don't know why it is not using the defined FROM: in Drupal. This configuration used to work fine in Drupal 4.6, but...

Telnetting in to the SMTP server and setting

MAIL FROM: band@chubbyjams.com
RCPT TO: jeff@chubbyjams.com
DATA
Hey look ma, it works
.

results in:

May  9 01:24:49 peter postfix/qmgr[18400]: 5019A1383B1: from=<band@chubbyjams.com>, size=378, nrcpt=1 (queue active)
May  9 01:24:51 peter postfix/smtp[27850]: 5019A1383B1: to=<jeff@chubbyjams.com>, relay=mail.one.net[64.89.70.104], delay=22, status=sent (250 2.0.0 k495On9h005078 Message accepted for delivery)

so I know it's not an SMTP configuration problem.

What is the "-f" parameter to which you are referring?

I'm obviously missing something here...

As always, any suggestions would be appreciated.

-Jeff

voc’s picture

I have the same problem as Freespirit.
My user doesnt receive any email password.
Have you solved your problem freespirit?What is the answer then?
There is a module for auto login:(http://drupal.org/node/34309).

MRsneezy’s picture

I had the same problem and the smtp module fixed it instantly.

aliak’s picture

me too. my email used to work then one day stopped. not sure if it was something my isp did. I didn't find out until some users emailed me and said they didn't get their passwords.

I upgraded to 4.7 over the w/e and tried the smtp module just now and it's working again, so thanks everyone for the tips!
Kath

jason342’s picture

I have the EXACT same problem, my email used to work great. All of a sudden emails are not sent out to new members.

It might be an SMTP issue, just wht do I tell my host to do to fix this?

Or what do I do?

senpai’s picture

i just received two complaints from new users stating that they are not receiving an email with their password. I know for a fact that new user accounts used to send emails, because I'd seen it in action three times. Somehow, the server is no longer sending emails for new users, but it can send "lost password" requests, so I know that SMTP is functioning.

Ladies and Gent, it seems we have a bug in 4.7 that doesn't manifest itself until a certain number of modules are in play? I'm not even sure how to go about tracking this down. Should I post a listing of the modules I'm currently using in my 4.7 installation?

Also, how does one fix this problem? I know its not SMTP related because Drupal can send email for lost passwords, and it's not a web server mis-configure because I can send out-bound email from my personal email client. Where should I be looking?

****
Joel "Senpai" Farris | certified to rock score

jason342’s picture

joelfarris, it has nothing to do with modules as I don’t even have any new modules installed. The only modules I’m using are the core modules, and not all of them as well.

New users are not sent mails and my "lost password" requests don’t work too.

senpai’s picture

I've done some further testing on my 4.7 install, and my problem appears to be related to AOL, not some bug or module. I have 16 users who have signed up and logged in since I posted my original reply on December 28, 2006 - 19:23.

Only two users have not received their New User email, and both of them turned out to have AOL addys. Funny that!
--
Joel Farris
"...and that's the way it oughtta be!"

****
Joel "Senpai" Farris | certified to rock score

jason342’s picture

Mine doesn't work with hotmail and gmail. I tested it.

greggles’s picture

If you are getting blocked emails from AOL or hotmail/gmail then you'll want to look at whether you are in a blacklist or perhaps if the emails are getting marked as spam.

I've had that happen on different hosts for about 20 different reasons. The best thing you can do is just try out different things and ask your host/system admin for assistance in reviewing the mail logs for possible indications of bounced/refused mail.

--
Knaddison Family | mmm Beta Burritos

jason342’s picture

I'm testing them myself. So I know for a fact it's not in spam or what not.

But what I want to confirm is that this is no way Drupal's fault, but is my host's right?

That way I can discuss this problem with them.

greggles’s picture

When an email comes into AOL (or hotmail or...) they do a bunch of things:

1. Do we even bother listening to the incoming email that's being sent or do we just respond with a "no, we won't take your email at all, sorry"
2. Once it's in our server, do we deliver it to the user or just drop it silently
3. It's in our server, we sent it to the user, do we stick it into the user's spam box or to their regular inbox?

So, before it even hits your inbox there are at least 2 points where it can get dropped.

Scenarios #1 and #2 both happen quite often - and you will need to talk to your system administrators (and possibly the AOL/hotmail/whomever admins) to clear up the problem. It may sound like an impossible task and it is somewhat difficult. However they should be able to help.

Regards,
Greg

--
Knaddison Family | mmm Beta Burritos

jason342’s picture

I am (kind of) sure that it might be my host.

As my drupal site is new, and no other drupal site has this problem. So it can't be gmail, hotmail, etc... in my case.

Whats strange is, the emails was able to send and it suddenly *broke* and didn't send.

Can some one explain please what I need to say to my host (the technical term) so I can get this matter sorted?

senpai’s picture

Jason,

Does your server send out any email at all? Try sending yourself a message using the contact form. Or the Personal Contact form. Report back here.
--
Joel Farris
"...and that's the way it oughtta be!"

****
Joel "Senpai" Farris | certified to rock score

Chill35’s picture

I am trying to come up with a possible fix in this thread : http://drupal.org/node/106837

Caroline

rdasilva’s picture

AOL (and some other mail systems/ISPs) will bounce any email that comes from a mailer that does not resolve with reverse DNS. In other words if the IP address of the machine running your SMTP/Sendmail will not return a VALID DOMAIN NAME by reverse DNS, AOL will bounce back your email.

ericinwisconsin’s picture

That's my problem, rdasilva.

I can understand AOL trying to stop spam, but I really think they're going to strangle all email from servers other than ones like Hotmail and Gmail and Yahoo.

jason342’s picture

joelfarris,

I did what you advised and sent my self an email via the contact form, and I didn't get the mail. It seems that doesn't work either.

However, my log did say "mail blah blah blah". So log does show that an email was sent from drupal, but the mail itself did not arrive.

I hope this clarifies things so i can fix this problem.

Shai’s picture

I've got pretty much the exact same situation. I'm following this thread closely.

Shai

Shai’s picture

Here is what the host wrote in explaining his discovery of the solution...

In cpanel (he means the cpanel view for hosts -- not the cpanel icons we lowly clients see) under mail server -> configuration -> tweak settings, there is an option to turn on or off :

Prevent the user "nobody" from sending out mail to remote addresses (PHP and CGI scripts generally run as nobody if you are not using PHPSuexec and Suexec respectively.)

I switched this setting from "on" to "off" to solve the problem.

I hope this helps others, I'm so relieved.

Shai

jason342’s picture

kelev, is this something you did (you can do) yourself via the cPanel, or your host did (can only do) it for you?

Shai’s picture

Host had to do it -- it was a server configuration issue.

Shai’s picture

Host had to do it -- it was a server configuration issue.

jason342’s picture

So to explain to my host I say the following, is this correct?

Go to mail server -> configuration -> tweak settings, there is an option to turn on or off: Then switch the user nobody to “on”?

Shai’s picture

The setting in question (at least in my situation - can't be sure you have the same problem) was:

Prevent the user "nobody" from sending out mail to remote addresses

And that setting was on.

Ask the host to turn that setting to off.

Shai

senpai’s picture

But of course its "nobody". Apache is prolly running as user "nobody", so therefore the Sendmail that Apache invokes would also be running as "nobody". Once this setting was enabled, or 'not blocked', Drupal, which is running through Sendmail, which is running through Apache, would be allowed to go about its business.

I'll bet your server admins are really REALLY scared that someone might be able to send emails to remote email addresses by default, ergo not localhost-only email addresses. What hosting company is this? Others may need to know this info, so it'd be helpful for you to post the name of this hosting company so that anyone who is searching for "can't send email NameOfMyHostingCompany" would be able to find this post.
--
Joel Farris
"...and that's the way it oughtta be!"

****
Joel "Senpai" Farris | certified to rock score

Shai’s picture

It is a VERY small hosting company. He doesn't even have a web site right now (ironic). His name is Brian Miller and the company is called SiteMiller. All of his previous hosting was done on Windows servers. He's adding LAMP now. I'm his very first LAMP client.

He was thrilled to change the setting once we discovered the problem.

He is an absolute pleasure to work with -- but you got to realize his company is tiny. His email address is:

Brian@bmitc.com

Shai

seaneffel’s picture

This was exactly my problem. No emails were being sent to outside email accounts, but were being delivered to internal email accounts. This included new account signups, group requests, blog subscriptions, everything a user wanted but could not recieve.

We accidentally had our VPS configured to prevent PHP applications from sending anonymous emails ( like nobody@... ). Switching this setting off in our WHM server manager finally fixed it.

Thanks very much for posting that solution, you ended a week of headaches.

docStone’s picture

Contact form emails work.
I installed the smtp module just to make sure, and the test emails work from there...
but with and without the smtp module enabled, new user registration emails are not arriving...

I don't see any problems in the logs at all, it's not getting marked as spam (I'm checking) the stuff simply isn't showing up.
Fresh install of the latest drupal, admin email is set...
I have no idea why this isn't working, seems very strange.

*** some editing after more poking around...
It seems that if I send a test email to myself at my domain where drupal is installed, it's all good... but if I try to send a test email to a gmail or yahoo account, no go....

makes no sense, I can send email to gmail and yahoo via a regular mail client using smtp so it shouldn't be an issue to send from drupal?

jstienrlson’s picture

Did you manage to solve this problem? I have the exact same issue - my site-wide contact form works, but new user registrations are not being sent.

JirkaRybka’s picture

First let me say, that I'm new to this site, so correct me if I'm writing to a wrong place. Honestly, I'm a little confused about all the bugs/issues and stuff, but surely I'll get hang later. I can only speak about the Drupal 4.7.3 version, which is running on the site Naturista.cz. I didn't install this, nor am I able to set up a testing installation, I'm just helping a friend with site-administration. So take my info in this light, please.

To the subject... Recently we had quite similar problem - all the mail from Drupal failed to be sent all of a sudden, without any change done. New-password requests said something like "Unable to send mail, contact admin" and logged an error into watchdog, while all the other e-mail cases (new user registration, site-wide and personal contact-forms, new private message notification) reported a success (and logged the same in the watchdog, where applies), but the email wasn't sent either. The real trouble with such a situation is, that the problem also affects the site-wide contact form (the contact module) used for feedback to admin, so users can't report the unsuccessfull registrations, and with the logs clean, admin doesn't notice anything for a long time.

The facts are:
- All the mails were blocked by the ISP (later they confirmed disallowing the mail() funcion for us).
- The reason they did it for was "outgoing spam" caused most probably by forwarding messages from site-wide contact form (which really were spam mostly).
- Drupal 4.7.3 lacks of any error-detection on sending e-mails (except new-password request), making you think that mails are being sent (and then dropped elsewhere).

First about the error-detection: The case was, that the mail() function didn't do anything, and returned FALSE. In the new-password mailing this lead to error-message to both the user, and admin log, which is correct behavior. All the other mail-sendings (list above) in 4.7.3 contain absolutely no check on the mail() return value, just displaying a fixed "success" message even when not true.

I've patched the user.module and contact.module files, where I took the check from new-password part, and included similar checks everywhere a mail is being sent, with errors reported to both user and admin-log. After uploading this to the live site, the result immediately confirmed that mail() returned FALSE always. (That was how I found out about the ISP's blocking.)

If anyone is interested, I can send the patched files on request (or should I upload it somewhere, although I absolutely don't know how to change headers or extract the patches from full-length texts, or what else to do for a correct patch distribution?) Note that it's also a good idea to have a custom error-message (via localization possibly) for site-wide contact form errors, with admin's mail address in it, to enable emergency contact from unhappy users in that case.

About the spam-issue: After this experience, I consider it very risky to use the site-wide contact form for feedback! On a middle-popular website like ours, quite a lot of messages are submitted by anonymous users, most of them being pure spam. There's no cure to this, since the feedback must be open for everyone, in case of log-in troubles for instance. All the messages are immediately sent out as e-mail, detected as spam by the ISP, and oops - mail blocked, ruining user-registration also. (The ISP - ours at least - doesn't care about the fact that it goes to our own address; plus it's even worse when the users (possibly being robots!) check the "Send me a copy" box, making the same message being sent twice, one to the given "from" address, which is not necessarily their own!) The flood-check in Drupal (3 messages per hour) is probably insufucient measure in this case: many feedbacks versus very few other e-mails from system give still a clearly spam-winning score.

So, we were forced to do something about the feedback, before they re-enabled the mail() for us. The solution I've found is to redirect site-wide contact form to the private messages of some user (admin typically), thus avoiding any possible e-mail/spam trouble with forwarding the non-trusted messages from anonyms. With the e-mail notification about unread messages enabled, the admin knows soon anyway, and in addition the site-bug-reports may not be affected by third parties, as e-mails often are.

I did this patch also, contact me if you're interested. (Multiple feedback categories still working, but accepting just one user-name instead of multiple mail-addresses as target, removed "send me a copy" box, and removed auto-reply, requiring the privatemsg module. Admin gets private messages from Anonymous user, with return-mail inserted in the text.)

I don't know, whether these issues are being sloved elsewhere or in latest Drupal distributions, but I seem unable to find any similar help (even though reading the search-results took me hours). Please correct me if I'm wrong, or if I should post this elsewhere/in other form. I hope this post might be still useful to somebody.

EDIT: I just discovered, that there's probably no private-contact possible on this site - I checked the contact-form box in my profile, but still it doesn't work (let alone no private-messages here). That's bad, because I don't like my e-mail published, for the spam-reasons. Just for this case one exception: bewesoft (at) centrum (dot) cz

Chad_Dupuis’s picture

I've had similar problems, but I've confirmed that mine is related only to AOL email addresses - as others have pointed out above. I've contacted them to see what they can/will do about this. All email from the drupal system - new accounts, password resets, user contact forms, etc. just disappear when they go to aol accounts?? All the users (about 30) have checked their spam filters, etc. to no avail.

Chad_Dupuis’s picture

just an update, my issues of not being able to send to aol were completely resolved with the returnpath module..... http://drupal.org/project/returnpath

mimetic2’s picture

is there a patch for this for 5.1?

sandr0ck13’s picture

hi, i'm new here. i hope you can help me with my problem regarding the site wide contact form.

the situation is this, we have set categories for every mail recepient we have in different areas of the site. for example we made a category "website feedback" for feedback matters, then we set another category for "product information" etc.

these categories are then assigned with its designated Recipient email address as follows..
"website feedback" - webfed@domain.com, admin@domain.com
"product information" - prodinfo@domain.com

we have no problem with this settings since the users of our site are able to send there feedbacks to us. The problem happens when we add another receipient email like "webfed@domain.COM.PH", or "webfed@domain.NET.PH" (take note I capitalized the domain extentions)... when user use the contact form and send us feedbacks drupal say it has sent the email successfully without a single error but when we check our corresponding email address we haven't receive a single email. but when the email with ".com.ph" is removed then contact form will act again as normal.

JirkaRybka's post probably answer this problem but my concern is why is it that contact form act normal if email address only ends with ".com" or ".net" but act differently if email address ends like ".com.ph" or ".net.ph" etc?

I hope somebody can give me inputs regarding this.

Thanks!

BINAIRe’s picture

Hi,

So I had the same problem on my private dedicated server and Drupal 5.X installed. I tried tweaking every possible setting on my server thru WHM and Putty/ssh and nothing worked.

I finally resolved the problem by adding this module:

http://drupal.org/project/smtp ---> Drupal 4.6 and 4.7

http://drupal.org/node/95819 ---> Drupal 5.X

INSTALL INSTRUCTIONS FOR SMTP.MODULE

----

1. Copy smtp.module and smtp.info files to your Drupal modules/ folder.

2. Login at site administrator.

3. Activate smtp.module on the administer->modules page.

4. Fill in required settings on the administer->Site configuration->SMTP support page.

5. Enjoy.

I did exactly as per the installation notes and now everything works just fine.

I have many other scripts installed on my server and all mail forms are working well, but Drupal wasn't until I installed that SMTP Authentication module for the corresponding Drupal version, for instance, 5.X.

This problem was repeating on every single site that used Drupal script on my server.

Drupal is great, but that is an important point to fix in the core of the script in my opinion.

Best regards,

D-A-R-K

erika’s picture

Hello all
I just tried what is all said. in this post .I was able to send a mail to only administrator account only once and not to any other users.I enabled the smtp module and tried to send a test mail.I get the following error.I need help in this regard.

* SMTP.module is active.
* The configuration options have been saved.
* SMTP.module is active.
* A test E-mail has been sent to username@gmail.com. You may want to check the logs for any error messages.

    * warning: fsockopen() [function.fsockopen]: php_network_getaddresses: getaddrinfo failed: No such host is known. in C:\programs\apache2.2\htdocs\modules\smtp\smtp.module on line 1894.
    * warning: fsockopen() [function.fsockopen]: unable to connect to dayspringsoft@gmail.com:25 (Unknown error) in C:\programs\apache2.2\htdocs\modules\smtp\smtp.module on line 1894.
    * warning: fsockopen() [function.fsockopen]: unable to connect to :25 (An established connection was aborted by the software in your host machine. ) in C:\programs\apache2.2\htdocs\modules\smtp\smtp.module on line 1894.

The log msg's show

fsockopen() [<a href='function.fsockopen'>function.fsockopen</a>]: unable to connect to :25 (An established connection was aborted by the software in your host machine. ) in C:\programs\apache2.2\htdocs\modules\smtp\smtp.module on line 1894.

My firewall is turned off.I'm supposed to try using gmail not a dedicated server.I'm using drupal 5.x
Currently I'm using gmail,as I'm a newbie,

The line 1894 in smtp.module shows

  • #connect to the smtp server
    $this->smtp_conn = fsockopen($this->protocol . $host, # the host of the server
    $port, # the port to use
    $errno, # error number if any
    $errstr, # error message if any
    line 1894 - $tval); # give up after ? secs

I'm fighting against my deadline..pl help me

colibri-1’s picture

after installing SMTP
I have an error in drupal log when a mail is being send (when creating new account on website), no details. However: the mail arrives!?
BUT: the contact form is not working anymore :-(, it says mail is sent but nothing arrives.

Any help welcome!

romand@drupal.org’s picture

The same problem in drupal 5.2 (in drupal 5.1 on the same unix host contact form and registration mail work fine without smtp module).

cherylchar’s picture

Hi,

I just view most of the forum topic regarding the sending mail problems and these make me almost gonna crazy since their problems have some similarity with mine but not all and i still couldn't solve it.:-(

I used Apache2Triad and i am very new in drupal 5.x, php, and etc. Really start from scratch...
I have installed the SMTP module as suggested in other forum. And when i test to send mail, these come out.

* SMTP.module is active.
* The configuration options have been saved.
* SMTP.module is active.
* A test E-mail has been sent to username@gmail.com. You may want to check the logs for any error messages.

These error messages come out..
1. "About to send email to: username@gmail.com"
2. Error sending email: "The following From address failed: admin@localhost" From: "admin@localhost" To: "username@gmail.com"

In my php.ini [mail function],
SMTP = localhost
smtp_port = 25
sendmail_from = admin@localhost

I wonder is the problem that i used the admin@localhost to send the mail and this cause the failure or other issues?? I'm able to send mail through the personal contact form without error but just i dunno where to get the message?

Since i also very new in mySQL, this really make me feel headache. I try to understand all these stuff a.s.a.p and really hope that i m a sponge..

Thanks in advance

gpk’s picture

What are your settings for smtp.module? It is usually used to send an email via the SMTP server that your computer uses when sending regular email. Often this will be your ISP's email server. I've not used it to send email with "localhost" as the SMTP server. I can't actually remember if Apache2Triad includes a mail server, and if so, it might need some configuration to make it work properly. Easier to use your regular SMTP mail server I would say.

gpk
----
www.alexoria.co.uk

cherylchar’s picture

Apache2Triad includes Xmail so i just need to make some configuration on it should work?
Currently my smtp.module setting is:
SMTP server = localhost
SMTP port = 25

Anyway, thanks for your fast response. :-)

gpk’s picture

>Apache2Triad includes Xmail
How have you configured it? Can you send an email from your usual email client via localhost? I'd recommend just using your ISP or other internet-based SMTP server settings, at least to get things up and running. But possibly it just wants a FQDN in the "from" email address, i.e. admin@domain.com.

gpk
----
www.alexoria.co.uk

cherylchar’s picture

Sorry for very late reply since din check for the post for few days.
And i just realized that actually i will need a domain to fix my problem but since i very new on the mail workflow hence it really troubled me a lot.
But i wonder that is it necessary for me to buy a domain and is there any free domain that can let me test my mail function because it's just prototype. :-)

gpk’s picture

Domains are pretty cheap from godaddy.com < $10 USD a year. It's always useful to have a domain under your control to use for testing purposes.

Not sure about where to get freebies. Sometimes you get one with your broadband subscription or web hosting, depending on your ISP.

gpk
----
www.alexoria.co.uk

jamesJonas’s picture

Setup a simple test. Create an account in your favorite free email services. Myself I used gmail. Then walk through a registration process or any basic service you wish to test in which part of the service involves sending a member email.

What I discovered - Increase in False Positives for Spam

What I found was my mail from my server was being marked as spam. This means one needs to begin to think like a spam filter in order to get your mail to go through.

Are You Alone
Search on "False Positives" AND gmail. Take a look at the horror stories. Business closing since customer's emails are lost, since the mail is drops into the spam folder and are never forwarded to the POP accounts. Banks emails are being dropped resulting in loan defaults. People loosing domain names since notices are not being received. This is not only gmail, which is a great email service. All the email providers are increasing the filtering because that's what the we the customers have asked for.

Some Guideposts

- Know how the filter think. For example here is a list of rules that spamassasin uses: http://spamassassin.apache.org/tests_3_2_x.html

- Test Using Email Providers: Sign up for a few accounts and then test your emails.

- It is not Obvious: So here I was, using the word 'Test 1' in the topic for the email. This is on the filters list. Awckkkk

- SPF - Know how to build your SPF file inside your DNS record.
Solution: This is what I had to do to get through the gmail filter

"v=spf1 ip4:55.100.450.21 mx mx:aspmx.l.google.com mx:alt1.aspmx.l.google.com mx:alt2.aspmx.l.google.com mx:aspmx2.googlemail.com mx:aspmx3.googlemail.com ~all" [TTL=3600]

Note: I have included the IP address for my drupal server at the beginning plus my email servers at google.

- This still did not solve my problems. I'm still getting blocked for some other emails. You have to look at the entire email. Header, content, ...

- The filters will continue to evolve, thus retest periodically.

Stronk’s picture

In my install of drupal 4.7 on a lamp-box, no e-mails from my site were sent at all, even though succesful dispatches were mentioned in the drupal-event log. I tried different stuff and ended up installing the smtp-module to resolve the problem, but got an error message stating that a mail function in the devel-module had the same name as a function in the smtp-module. So after dismantling the devel-module and deleting the files from my server... all e-mails are being dispatched again, and I'm a really happy camper.

--
My girlfriend says that I need help (Therapy?)

danlunt’s picture

Be sure to remember phpmailer when installing this

chivas3’s picture

I was having similar problems: testing registrations using email addresses on the same domain as my Drupal worked just fine. Other emails failed to go out.

I installed SMTP module, activated it, and verified the settings by sending test emails to all sorts of emails on other domains. However, registering using one of those successfully tested email addresses fails. Is there something else that needs to be done to tell Drupal to use SMTP module as its sendmail proxy for registration?

gpk’s picture

No, enabling the module should be sufficient. Suggest you seek further support in the issue queue http://drupal.org/project/issues/smtp?states=all.

gpk
----
www.alexoria.co.uk

chivas3’s picture

Quick follow-up, of course, right after I posted this it suddenly started working again. Maybe something in the settings needs to cascade through?

Anyway, if you install SMTP module and test successfully, you may experience some latency before your registration functions work with the new settings.

Best,
-Drew

cliff_mvd’s picture

I have set up a machine for testing, and I want to be able to send email from Drupal to localhost accounts as well as to the outside. Here's the basic configuration:

- Centos 5x
- Drupal 6.10
- SMTP Auth module ON (phpmailer is included)
- postfix running

My postfix is working - I can use it to send to localhost accounts as well as to Yahoo accounts. BUT, I can not get Drupal and postfix to work together. The test emails (when creating new users or when activating the SMTP module) produce errors:

# warning: fsockopen() [function.fsockopen]: unable to connect to localhost.localdomain:25 (Connection refused) in /sites/all/modules/smtp/phpmailer/class.smtp.php on line 122.

# warning: fsockopen() [function.fsockopen]: php_network_getaddresses: getaddrinfo failed: Name or service not known in /sites/all/modules/smtp/phpmailer/class.smtp.php on line 122.

# warning: fsockopen() [function.fsockopen]: unable to connect to :25 (php_network_getaddresses: getaddrinfo failed: Name or service not known) in /sites/all/modules/smtp/phpmailer/class.smtp.php on line 122.

Any help on this would be greatly appreciated!

Thanks,

Cliff

cliff_mvd’s picture

It seems that drupal+postfix wasn't able to resolve the localhost.localdomain IP address. Hard-coding the IP address info has provided a workaround for now. Probably there are some postfix or other mail config files that would provide a more robust solution - if anyone can give me some hints, that'd be great.

Cliff

ericinwisconsin’s picture

Cliff, I'm no Linux, Drupal, or Postfix guru, but I've played around with all of them in my time.

Can you check your /etc/hosts file? There should be a line in there that resolves your localhost.localdomain to your IP address. That should be all that is needed. It's odd that your Postfix works at delivering local mail but your Drupal doesn't. That suggests to me that there's an issue in PHP or Apache in resolving the domain name, but not in Postfix.

Also, in Drupal, what do you have for your SMTP server name? I've always found "localhost" to be more than sufficient, but I have a line in my /etc/hosts file that resolves "localhost" too.

Chad_Dupuis’s picture

I wrote a quick article about my setup that should be helpful for you. I'm using postfix to relay the emails to another smtp server, but the configuration is generally the same for you minus that step. The article is here:

http://media.yinyanghouse.com/web-management-help-articles/postfix-relay...

tommytom’s picture

I'm getting this error when I try to register an user:
warning: mail() [function.mail]: SMTP server response: 550 Authentication is required for relay in
can anybody help ?

Narek’s picture

RetrunPath solved my issue

I was getting following error: status=bounced


http://drupal.org/project/returnpath