Skip navigation
Currently Being Moderated

cfmail glitches in ColdFusion 9 (not sending, but says sent)

Feb 26, 2010 7:40 AM

I'm seeing the strange behavior with basic cfmail sends in CF9.  CF9 has an entry in the mailsent log  that is was successfully sent but on the MailEnable logs (Mailenable exists on the same server as CF and CF sends all it's l through it) there wasn't even a connection attempt.  Now  this is a my bulk  mail server and I'm probably averaging about 70,000 e-mails a day from that server and most mails go through just fine.

 

 

What i've discovered about the few that don't is they have a few things in common. Anything that goes out with a "mailworker" thread works 100% of the time.  Mail that goes out as a "scheduler" thread seems to be 50/50".   There is no spam filter involved here.  I'm just checking logs from the CF side and from the mailenable side.  CF says is was sent....mailenable doesn't ever see an attempt at that time. I've seen this on another of my CF9 servers that relays through our ISP's SMTP server.  CF send it was sent in the mail sent log, but ISP has to record of a conenction attempt let alone a full message at that time.  I think there is a CF9 cfmail bug,  I never had an issue with this on CF8 (or cf7 for that matter).  The setup was exactly the same.  These problems just started a couple mounth ago when we upgraded to CF9.

 

Anyone have any ideas, or if other people think this sounds like a bug how I can prove it to Adobe?

 

-Dan

 
Replies 1 2 Previous Next
  • Currently Being Moderated
    Oct 28, 2010 10:04 PM   in reply to booster94

    Just a note to let you know that I'm experiencing the same issue.  Hundreds of emails go out fine and then one will show up as successful in the ColdFusion mailsent logs but will not even appear in the email server logs ~ no error message, not even a connection attempt.  You make a good point about the "scheduler" thread ID and the "mailWorker" thread ID as this has only happened with "scheduler" thread IDs.  I'm on Windows 2008 Enterprise Server (32bit) with ColdFusion Standard 9.01.  The email server is running Merak/IceWarp. I am unable to duplicate the problem; it just happens randomly.  I was going to try a new email server, but if you're experiencing the same problem on a completely different email server it sounds like it very well could be ColdFusion bug. 

     

    Tom

     
    |
    Mark as:
  • Currently Being Moderated
    Oct 29, 2010 10:18 AM   in reply to booster94

    I also suspected a possible network issue, so it's interesting to know that you have the email server on the CF Server box.  I'm using cfmail to send out a notification of an external user form submission, so I can't even use a 'bcc' to catch this problem.  Since the email server is not even showing the connection from CF 9, it's as if CF 9 is just marking the email as sent without any connection to (or confirmation from) the email server.   I have screen shots from the CF 9 mailsent log and the corresponding email server log showing that there is no connection to the email server at the time CF 9 records that it successfully sent the email. Emails before and after the missing email show up in both the CF mailsent log and the email server log and go out as expected.

     

    It seems to be a rare occurrence, so it doesn't surprise me that more people haven't noticed it or they blame it on the emails getting lost in cyberspace.  In the past 3 weeks I've confirmed it happened twice, but that's only because one of my clients noticed it when they received email notification of a new form submission and then found a previous form submission in the database that they did not get an email notice for.  When I looked up the email, CF shows it as sent but it's nowhere in the email server logs.  This is bad because without the email, my clients don't know that a new form has been submitted until they login to my application and check the database; the point of the email is to let them know exactly when they have to check the database for a new form submission.

     

    Does anyone know the difference between a cfmail "mailworker" ThreadID and a "scheduler" ThreadID?   Is there any way to force cfmail to send using a "mailworker" thread?   I guess another idea would be to try spoolenable="no" for the specific cfmail tag since these are not bulk emails.

     

    Tom

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 5, 2010 6:02 AM   in reply to booster94

    +1 on problems with CFMAIL. We are using Google as our SMTP server, and I've even seen headers mixed up (a FROM address used by one mail is used in another!).

     

    Wim

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 9, 2010 10:37 AM   in reply to booster94

    I'm not sure if this will help, but I filed a bug report at:

    https://www.adobe.com/cfusion/mmform/index.cfm?name=wishform

     

    Here are two screen shots documenting the problem.

    http://www.actionlogic.com/ColdFusion9CFMAILBug01.gif

    http://www.actionlogic.com/ColdFusion9CFMAILBug02.gif

     

    The first screen shot is of the CFMail log showing an email went out successfully at 11:47am.  The second screen shot is of the email server logs showing that there wasn't even a connection attempt at 11:47am.  CFMail emails before and after 11:47am are recorded in both logs.

     

    It's too early to tell if this helped or not, but I set spoolenable="No" for the specific CFmail tag I noticed was having a problem. Since it is only a sending out a single email, performance isn't an issue.

     

    Tom

     
    |
    Mark as:
  • Currently Being Moderated
    Dec 7, 2010 4:40 AM   in reply to booster94

    We are seeing this same behavior in 8.0.1.  Emails using mailWorker threads are sent out fine and emails using scheduler threads are questionable.

     

    UPDATE:  We found that when we send emails within a cfloop of 100, the mailWorker thread is used.  When we tried a singleton or a loop of 2 or 11, the scheduler thread was used.  I imagine that the cutoff ColdFusion uses for choosing between mailWorker and scheduler is somewhere between 11 and 100, but I am not sure that knowing the exact number will help us.  The real problem is figuring why emails sent using the scheduler thread are intermittently failing, but being reported as succeeding.

     

    Message was edited by: Robert_Com99

     

    UPDATE2:  The magic number is 20.  At 19 emails in the loop, the scheduler thread is used, but as soon as we hit 20, it uses the mailWorker thread.  Can anyone else confirm this finding?

     

    Like I said earlier, I don't think that knowing this number helps us much, but I just had to know what it was.

     

    Message was edited by: Robert_Com99

     
    |
    Mark as:
  • Currently Being Moderated
    Dec 7, 2010 8:31 AM   in reply to booster94

    Very odd. I'm having the same issues too with CF9 and Windows Server 2008 x64.

     

    Successful mailsent log but no trace of it actually going out anywhere else. I'm using the same machine that CF is running to send the mail. Nothing in inetpub/mailroot folders and nothing in Coldfusion/Mail folders that would indicate it's sitting in there and not going out.

     

    Someone suggested tacking on spoolenable="No" for the cfmail tags and that didn't seem to fix anything either. I've tried both emailing to a single recipient, and a query of recipients (about 10 or so addresses) and no difference.

     

    I'm really at a loss here, especially when I have a few other CFMails through out the site that seem to be working just fine.

     
    |
    Mark as:
  • Currently Being Moderated
    Dec 7, 2010 10:30 AM   in reply to DanomiteDev

    We also tried the spoolenable=false on our server and it did have a slightly different result.  We found that the tread ID was not mailWorker or scheduler - it was jrpp-964 (I am sure this is just one instance of jrpp-XXX).  We had thought about trying this out in our production environment, but it seems that DanomiteDev has already answered the question of whether or not that will resolve the issue.  Adobe - are you out there?

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 6, 2011 1:38 PM   in reply to booster94

    Can we have ANYTHING on this issue/bug?

     

    Our company recently upgraded from MX7 to CF9 Enterprise and we are losing Client Notification Emails at random with these exact symptoms.

     

    This issue should be addressed soon if not an official response.  If not, what point is there in posting on these forums in the first place????

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 6, 2011 4:37 PM   in reply to PaulChan_77

    PaulChan_77 wrote:

     

    what point is there in posting on these forums in the first place????

     

    NOT TO GET OFFICIAL SUPPORT.

     

    The forums are to facilitate user to user help and sharing.  Adobe does not officially  monitor or comment in these forums.  Though some engineers are apparently known to moonlight in here occasionally.

     

    IF you need offical comment from Adobe, you need to go through an offical comunication channel.  Not a free to use public forum.

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 7, 2011 9:11 AM   in reply to booster94

    I went to the Adobe site and posted this as a ColdFusion bug.  The bug ID is 86933:

    http://cfbugs.adobe.com/cfbugreport/flexbugui/cfbugtracker/main.html#b ugId=86933

     

    If you click the link above, you can "Vote" and "Comment" on this bug; so if it's happening to you please vote and comment on this bug and hopefully it will get more attention.

     

    Tom

     

    ps. There is another bug report (#86905) which refers to a similar CFMAIL problem caused by the SMTP server returning an unknown user error:

    http://cfbugs.adobe.com/cfbugreport/flexbugui/cfbugtracker/main.html#b ugId=86905

    but this doesn't appear to be the case in my situation.

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 7, 2011 9:21 AM   in reply to booster94

    We grew so fed up with this (well, our clients did) and we looked for paid (unfortunately) outside sources to handle mail.

     

    We turned to postmarkapp.com and I've been really happy with their service. They even had a sample CFC and I didn't even need to roll my own. I might have tweaked it a hair though, I can't recall. Basically it sends up your message to their server wrapped in JSON. It can even handle attachments passed along as base64 (I haven't worked with that part yet though).

     

    There's some great logging and status reports and usage metrics.

     

    This takes a little effort in getting set-up. In order to minimize bounces and keep ISPs happy, you need to add some TXT records to your DNS record to authroize Postmark to send email on your behalf. Also, you can't use them as bulk-mailers, they need to be "transactional based."

     
    |
    Mark as:
  • Currently Being Moderated
    Aug 14, 2011 8:43 AM   in reply to booster94

    I only know of one coding error that can cause that to happen:

     

    If you have a comma delimted list of email address (ie. multiple emails) assigned to either the failto or replyto attributes of the cfmail tag, then your email will be logged as sent but will never actually go anywhere.  Im not sure if a process within ColdFusion swallows it without an error or if thats just a standard mail server reaction.  So, check the failto and replyto attributes on your cfmail tag.

     

    Tim

     
    |
    Mark as:
  • Denzel Papillons
    2 posts
    Oct 18, 2010
    Currently Being Moderated
    Oct 4, 2011 2:18 PM   in reply to booster94

    I experienced the same problem with <cfmail> with a bcc list of email address.  I removed the bcc list and the email was sent out without a problem.

    (ColdFusion 9.0; Windows Server 2003) I have voted on the bug list.  Thanks.  Kathleen

     
    |
    Mark as:
  • Currently Being Moderated
    Oct 7, 2011 7:15 AM   in reply to booster94

    We have a reminder_page.cfm set in CF administrator as a scheduled task that has the same symptoms - silently fails to send, spooler is empty when we check, log says sent, other logs show ran as scheduled.

     

    We tried all the things noted above to no avail, but we discovered that moving our reminder_page.cfm otuside the /www tree covered by our SSL certificate instantly solved the problem.  Under the SSL cert = no send, outside of it = sends fine.

     

    More details, see my blog at http://ethermuse.blogspot.com/2011/10/adobe-coldfusion-cf-mailer-dies. html

     
    |
    Mark as:
  • Currently Being Moderated
    Apr 15, 2012 7:20 AM   in reply to booster94

    Did anyone ever resolve this?  I'm having this exact issue now, but only on messages with an attachement.  I was working fine for several months and just started doing this a few days ago.  I've restarted the server, installed 9.0.1 and hotfix 2 all with no improvement.  CF generated emails with no attachment are sent fine, every time.  With an attachment though, I'm seeing the message in the spool, it goes away, undeliverable is empty, and the cf logs indicate the message is sent successfully.  However, our email server doesn't even show a connection was attempted.  Help!

     
    |
    Mark as:
  • Currently Being Moderated
    Aug 18, 2012 7:30 AM   in reply to Pete L.

    Was this ever resolved?  I too am having this issue. I reported the bug here: https://bugbase.adobe.com/index.cfm?event=bug&id=3313431  please vote

     
    |
    Mark as:
  • Currently Being Moderated
    Aug 19, 2012 6:50 AM   in reply to john_glynn

    In my case, it was because our Exchange server had a 10MB message size limit. Even though the message was small and the attachment was showing as 7.9MB, the total, once converted to text for emailing it was like 10.2MB and so the server was rejecting it without logging it. Once we removed that limit for the account all email was sent and recieved as expected.

     
    |
    Mark as:
  • Currently Being Moderated
    Aug 20, 2012 6:43 AM   in reply to Pete L.

    This is not our case, but even still, wouldn't that throw an error?  Or is it an error that CF just can't catch because it happens after it leaves the spool?

     
    |
    Mark as:
  • Currently Being Moderated
    Aug 20, 2012 7:04 AM   in reply to john_glynn

    CF assumed it was sent ok as it passed the message along to the email server without issue.  It was Exchange that received the message, looked at the size, and then just dropped it without further info.  Apparently that check is done after the message is sent to the email server.

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 4, 2012 3:52 AM   in reply to Pete L.

    We do have the same problem, CF says email has been sent while smtp does not receive anything, with no error messagge at all.

    But we recently moved

    from

    CF8.01 on Windows Server 2003/SQL2005 with jdk1.6.0_11

    to

    CF8.01 on Windows Server 2008/SQL2008 with jdk1.6.0_24

    I cannot believe that 2003 to 2008 is responsable of this BUT jdk from 11 to 24...................................

    Could you tell me what JDK are you using?

    In the meantime I will try to roll back to jdk1.6.0_11 but due to the fact that the error is random......

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 4, 2012 10:28 AM   in reply to EnryTheMangia

    I am running Java version 1.6.0_14

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 4, 2012 11:40 AM   in reply to john_glynn

    Out of curiousity, what are your CF mail settings?  Have you played around with those?

     

    Maybe these settings (under Mail):

     

    Maintain connection to mail server

    Spool Interval (seconds)

    Mail Delivery Threads

    Spool mail messages for delivery to

    Maximum number of messages spooled to memory

     

     

    Also, under the Error Log Severity there is a Debug option.  Not sure what that reports or how large it will make your logs if you enable it.

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 4, 2012 1:00 PM   in reply to Miguel-F

    I got these from the summary page in the administrator - but I do not know where to set some of them (i.e. Maintain Connection to Mail Server)

    Default Server Port  25   

    Connection Timeout  60 seconds  

    Spool Interval  15 seconds 

    Mail Delivery Threads  10   

    Maintain Connection to Mail Server  No   

    Max Messages Spooled to Memory  50000   

    Default CFMail Charset  UTF-8   

    Use SSL Connection  No   

    Use TLS  No   

     

    Thanks

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 4, 2012 1:21 PM   in reply to john_glynn

    I have the same config in the admin page, except for "Maintain Connection to Mail Server" that I set to ON.

    I tried also to increase the "mail delivery threads", setting it to 15 and 20...I got only more email not-sent!!!

     

    Now I'm trying something crazy.

     

    I have many different type of email (registration, order confirmation, etc).

    In some of them (like registration) there is just 1 email for FROM, 1 email as TO, 1 email as BCC (that's me to check this crazy problem.............).

    But for others (like order confirmation, there are 2 or 3 BCC (me, sales rep, datawarehouse, etc).

     

    I got problem only with the last one!!!

     

    Now I'm trying to leave just one BCC....let me see what happens and I will update you.

     

    PS: is there anybody from Adobe around there??? Please wake up, this discussion started 26-feb-2010 and we post many bug report but no feedback at all from you...

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 5, 2012 1:37 AM   in reply to EnryTheMangia

    No way, even removing the BCC the problem remains.

     

    I forgot to underline one aspect.

     

    I moved from

    CF8.01 on Windows Server 2003 32bit/SQL2005 with jdk1.6.0_11 (working ok)

    to

    CF8.01 on Windows Server 2008 64 bit/SQL2008 with jdk1.6.0_24 (not working)

     

    I don't know if hte problem is related to the underlining architecture, but....

    John, the only think that we have in common is Windows Server 2008 64 bit........

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 5, 2012 5:05 AM   in reply to EnryTheMangia

    Hi Enry,

    I am running 2008, 64bit with JDK version 1.6.0_14 and SQL 2005.  I am going to try a test.  I am wondering if the emails I am loosing happen during peak usage where the CPU runs at or near 100%.  I'll do some coldfusion image processing which usually results in high CPU usage.  While that is going on I will send some bulk email to a dozen or so email addresses of mine over and over again via cfmail and see if any get lost.  I will let you know how this goes.

    John

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 5, 2012 6:48 AM   in reply to john_glynn

    OK John, but consider that I moved my sites

    from

    a single Xeon 2Core with 4GB of Ram in 32 bit config (with no problem)

    to

    a bi-Xeon 8Core with 32GB of Ram in 64 bit config (with problems)

    So its difficult to believe that CPU performance is the point, but....you don't know if you don't try :-)

     

    In the meantime I tried to change the JVM jdk1.6.0_11 to 24 to 35 but...nothing.

     

    Now, due to the fact that I found on Sun site that -XXparameters are "...for development and not stable...", I started removing the -XXparameters from my JVM.config file

    I just removed

    -XX:-UseGCOverheadLimit

    and the result same to be good, no email lost in the last 3 hours (I send a couple of email per minute)!

     

    Now my parameters are:

    java.args=-server -Xms2048m -Xmx2048m -Dsun.io.useCanonCaches=false -XX:PermSize=512m -XX:MaxPermSize=512m -XX:+UseParallelGC -Dcoldfusion.rootDir={application.home}/ -Djava.security.policy={application.home}/servers/cfusion/cfusion-ear /cfusion-war/WEB-INF/cfusion/lib/coldfusion.policy -Djava.security.auth.policy={application.home}/servers/cfusion/cfusio n-ear/cfusion-war/WEB-INF/cfusion/lib/neo_jaas.policy

     

    Could you please tell me whiche parameters are you using? I hope you are using UseGCOverheadLimit :-)

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 5, 2012 11:00 AM   in reply to EnryTheMangia

    The problem is the Garbage Collection running on 64bit.

     

    Today I opened the Monitor in ColdFusionAdmin to check the memory usage.

    At a certain time, the momory usage drop down from 2GB to 0.3GB: from that moment, no email for 10 minutes.

    Then, when email were arriving, I clicked on "Run GC" in the admin: again, no email for some minutes!

     

    How to solve it? Difficult to say...

     

    Changing th JDK version?

    Removing XX:+UseParallelGC?

    Incresing the memory to JVM to avoid the GC?

     

    Not easy to understand...a mess!

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 5, 2012 11:04 AM   in reply to EnryTheMangia

    I'm not sure where I can edit the JVM.config file, a search for it returns nothing.  The arguments listed in the CF administrator are as follows:

     

    -server -Dsun.io.useCanonCaches=false -XX:MaxPermSize=192m -XX:+UseParallelGC -Dcoldfusion.rootDir={application.home}/../ -Dcoldfusion.libPath={application.home}/../lib

     

    What is garbage collection collecting?

     

    I agree, this is confusing and should be better supported by Adobe. 

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 5, 2012 11:17 AM   in reply to john_glynn

    The garbage collection (GC) is the process to remove from memory the classes and objects that have not been used for some time to increase the free memory available.

     

    You can find the jvm file in the LIB directory within the folder where you installed JRun: you can edit it but before you have to stop JRUN.

     

    It would be interesting to see if it happens also in your website.

    If you want to try:

    - open the monitor in CF admin

    - start memory tracking

    - click on statistics / memory usage

    If you click on the trash icon with "Run GC" and the emails stop for some minute, we find the problem!

     

    PS: how many processor do you have? I'm asking this because UseParallelGC has no effect on mono-processor systems.

    Before I had a server with 1 processor and no problem, now I have 2 and problems....while on the development machine, with 1 processor, no problem...

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 6, 2012 3:20 AM   in reply to EnryTheMangia

    Good news, my JRun is now sending regularely all emails (CFusion was sending the email to the spool folder, the email were processed but the thread within Jrun was not executed, with no error feedback, they were just waiting...).

     

    These are the operation I have done:

    - increased the maximum memory, increasing either the minimum memory to reduce operation in allocating memory

    - I removed all parameters connected with GC (UseParallelGC and UseGCOverheadLimit) from my jvm.config

    - I installed the hf801-71800 patch (I don't know if it's included in the cumulative HotFix 4)

    http://helpx.adobe.com/coldfusion/kb/patch-cfmail-error-coldfusion-8.h tml

     

    After these operation, the garbage collection is slower but works without stopping the send-email process.

     

    PS for John: I attach my jvm.config, if you have enough memory installed (at least 16GB, no less), try it

     

    java.args=-server -Xms4096m -Xmx4096m -Dsun.io.useCanonCaches=false -XX:PermSize=512m -XX:MaxPermSize=512m -Dcoldfusion.rootDir={application.home}/ -Djava.security.policy={application.home}/servers/cfusion/cfusion-ear /cfusion-war/WEB-INF/cfusion/lib/coldfusion.policy -Djava.security.auth.policy={application.home}/servers/cfusion/cfusio n-ear/cfusion-war/WEB-INF/cfusion/lib/neo_jaas.policy

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 6, 2012 6:21 AM   in reply to EnryTheMangia

    Hey Enry,

     

    This sounds like a different problem.  My Spool remains empty, mail appears to send successfully but occasionally, and seemingly at random, the e-mail fails silently - nothing is picked up in the logs and the Spool remains empty.   The spool thinks the e-mail was sent successfully.  This is an infrquent problem, which makes it very unnerving because I cannot replicate the problem.

     

    Thanks for all your research on this Enry.  I do not have enough RAM and I am running CF9 Standard, I do not think that patch is for me.

     

    I am going to try the HOT FIX, it mentions this bug fix:

    83980 Intermittently cfmail tag does not set the MessageID correctly.2

    Who knows... Cheers, John

     
    |
    Mark as:
  • Currently Being Moderated
    Dec 6, 2012 4:21 PM   in reply to booster94

    We have the exact same problem. When CFmail uses the scheduler to send the messages they are all marked as sent successfully in the mailsent.log, however any that are recorded with the same timestamp in this log never make it to the sending mail server.

     

    Has anyone tried CF10 to see if this issue is resolved. Maybe we just need to upgrade?

     
    |
    Mark as:
  • Currently Being Moderated
    Dec 7, 2012 10:11 AM   in reply to vin65Jason

    Adobe - are you reading these?

     
    |
    Mark as:
1 2 Previous Next
Actions

More Like This

  • Retrieving data ...

Bookmarked By (1)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points