This is my first question.
I ran this script,
<cfloop from=1 to=300 index="i">
Sending email #i# <br>
<cfmail to="test#email.com" from="test#email.com" subject="Bulk email test - #i#">
#now()#
</cfmail>
</cfloop>
I received 300 email in 90 minutes. Why it is slow ?
I was getting email not in sequence. For example , 'Bulk email test -7' ,'Bulk email test -232' ,'Bulk email test -86' etc. What is causing it ?
Is there some kind of setting for it ?
Thanks
Found the solution. Many undelivered email from 2010 existed in the spool.Cleared the spool and everything is working fine.
Related
I'm getting hundreds/thousands of emails on my catch all address for my domain, with the subject "Returned mail: see transcript for details".
I am trying to catch these emails with spam assassin (SA) to mark them as spam, but the SA rule only works if I email a test email to my domain with that text in the subject. The actual spam mails are not marked... only the once I send myself as a test.
I have tried (in local.cf):
header LOCAL_SUBJECT_RETURNED_MAIL Subject =~ m/Returned mail/i
score LOCAL_SUBJECT_RETURNED_MAIL 10.0
header LOCAL_SUBJECT_RETURNED Subject =~ /\bReturned\b/i
score LOCAL_SUBJECT_RETURNED 10.0
Again... the rules are working, yet it looks like the spam emails come in without being scanned by spam assassin.
Does anyone have any idea on what I could try?
Things I've tried/done
I enabled php mail logging on my system, to ensure it's not being send through a script on my domain. Log is empty, so that's good.
The reason why spamassassin is not catching these emails (backscatter), is because they don't come through spamassasin, because they come from the mailer deamon inside my domain/webserver.
Test mail I send myself:
Received: from localhost by server.myprovider.net
with SpamAssassin (version 3.2.4);
Backscatter spam:
Return-Path:
Received: from localhost (localhost)
As you can see, it doesn't come through spamassassin, hence, no rules are triggered...
I am trying to fetching mail from gmail ..but i am facing a serious problem during saving mail into database. the body content are comming with "=" after saving when continous line. as bellow ---
1206979905221152897hs_cos_wrapper m=
2897hs_cos_wrapper_widget m_1206979905221152897hs_cos_wrapp=
er_type style=3D"color:inherit;font-size:inherit;line-height:inh=
<p style=3D"margin-bottom:1em">All my best,<br> Mitchell</p>=
<p style=3D"margin-bottom:1em">P.S. If you ha just reply t=
il.=C2=A0When you're ready to upgrade, head to the <a href=3D=
"http://wwv.lucidchart.com/e1t/c/qYC2Db8rk0/*W9fFq-316bx3F=
W8CWyzp3DpNLV0/5/f18dQhb0S1Wd2Rwh5hbnMC51QVv9W7Hwjq86wWWGZW7=
vQrRW6Qxg9Z686lDXN2rRW6BC5sBzW5SYlQv675mnXW4CmKYY8D95T9=
1QPK5fVJjqh62qGt4tW59CYkB2GJgtzW2CnNzP4Nl11wW25fJr-6rNw=
1bGRVbJk6q3v7J8mW27C-VC1FY2gGN6MVfyPPzMd8W1BHsPt6vz=
pHt1q4V4_W16sdWz6QH55-N7mZJVzgBNVkW5XTLDH4mr1_8W5XVC028=
8wcs95JMf33W8qC3t312Syl5W1wRxFp1C1pg3W2xZfwK4jjGmtW6KV-4P3DmD0SMzTM2=
rW1htky14LlZRgW1xhbdr802V94W6DjZCs5DKYwwW8pqCdK8p4315W5TcLJb4l7QQ3W1hW=
SzKlg-8W6306Xl4bGXglVJJ2MB7GT0xLN58Q5QDyl2mZW6W8_KH4B6wtPW6_h=
ndB5y83PqVFwc094vFyxmW5mSySS97kT7Df4wGTd902">pricing page=
</a>.</p></div>
how can i sefe from this prolem?
I am using the below code block in CF9 to get all the mail data,
<cfimap
action="GETHEADERONLY"
name="LOCAL.checkEmail"
secure="true"
folder="Inbox"
server="#ImportAquireMailServer#"
username="#ImportAquireUsername#"
password="#ImportAquirePassword#" />
This query object provides the information about all the mails present in inbox. While doing so it takes a lot of time and also times out frequently.
Is there any way to get the latest mail only, so that it will not provide the information about all the mails and will also not run into time out situation?
Please help.
you may need to update the read messages to "read" like:
<cfimap action="MarkRead" connection = "Conn" messagenumber="#getHeaders.messagenumber#">
after the message id done with work.
so you can query the latest messages as:
<cfquery dbtype="query" name="getMails">
select * from getHeaders
where seen=<cfqueryparam value="no" cfsqltype="cf_sql_varchar">
</cfquery>also you can filter with received date
you can refer http://shemy-coldfusion.blogspot.in/2013/03/coldfusion-code-to-get-multiple-mail.html
I am having problems with this website, it isn't sending any emails. Basically when someone places a order, it sends a comfirmation email. I don't see any problems with the code but I believe this is the right place to be looking for the problem. Can some one help me please?
<cfquery name="getUser" datasource="personal2009">
SELECT * FROM site_users WHERE id = '#session.id#'
</cfquery>
<cfoutput>
<cfmail to="#site_email#" from="#site_email#" subject="Website International Order Request">
#getUser.title# #getUser.Firstname# #getUser.Surname# has requested to deliver an order to an international address.
Their contact details are:
#getUser.Address1#
#getUser.Address2#
#getUser.Town#
#getUser.Postcode#
#getUser.Country#
#getUser.Tel#
#getUser.email#
The delivery address requested is:
#formtitle# #formFirstname# #formSurname#
#formAddress1#
#formAddress2#
#formTown#
#formPostcode#
The order details are:
<cfset thisrow = 0><cfoutput><cfset thisrow = thisrow + 1><cfset tot = 0><cfloop index="list" from="1" to="#session.numincart#"><CFQUERY NAME="ind" DATASOURCE="personal2009" maxrows=1>SELECT * FROM products WHERE id = #listgetat(session.cart, list)#</CFQUERY>
Product Name: #ind.product_name#
Price: £#decimalformat(listgetat(session.price, list))#<cfset multiply2 = #listgetat(session.quant, list)#>
Quantity: #listgetat(session.quant, list)#
</cfloop></cfoutput>
Thank you
</cfmail>
</cfoutput>
<cfset session.endemail = '1'>
Depending on what your hosting environment looks like, I may suggest altering your cfmail tag to the following:
<cfmail to="#site_email#" from="#site_email#" subject="Website International Order Request" server="#server#" username="#username#" password="#password#">
1) If you don't have access to the CFADMIN, you are unable to track your mail path. Specifying your own server/username/password will allow you to send email with your own SMTP server and rule that out.
2) Even if your host has CFMAIL setup with a SMTP default server, it may be possible that they have not setup SMTP relaying correctly. The outcome is your mail gets sent through coldfusion but rejected by the smtp server.
3) Even if your host has CFMAIL setup and SMTP relaying setup, the last possibility could be SPAM filters on the receiving end. If you have SPAM filters that look at SPF/Domain Keys/other criteria, they could be blocking to emails too.
Specifying your own server/username/password is usually the best bet to troubleshooting email issues.
I have a simple email sender for user account activation. Depending on which email address I use, I get significantly different response times: University email - 1 minute, Gmail - 3-4 hours, Yahoo - 1 or 2 days -- which seems bizarre. Has anyone else seen this phenomenon?
EDIT:
There weren't many responses (even for a bounty), but I'll try to explain my problem more clearly.
This probably isn't greylsting -- If I so a simple:
php mail ($to, $subject, $body) // this delivers instantly.
My cakephp code:
function __sendActivationEmail($id) {
$User = $this->User->read ( null, $id );
$this->set ( 'suffix_url', $User ['User'] ['id'] . '/' . $this->User->getActivationHash () );
$this->set ( 'username', $User ['User'] ['username'] );
$this->Email->to = $User ['User'] ['email'];
$this->Email->subject = 'Test.com - ' . __ ( 'please confirm your email address', true );
$this->Email->from = 'noreply#test.com';
$this->Email->template = 'user_confirm';
$this->Email->sendAs = 'text';
$this->Email->delivery = 'mail';
$this->Email->send ();
}
Causes delays from 13 minutes (ok; we'll deal with it) to 5-6 hours (less okay, since this is an activation email). For some of my users, it works instantly, but for other users (of the same service provider, i.e., gmail, it sees these delays).
Any clues?
The code looks fine, but it of course doesn't tell anything about the mail server's configuration.
3-4 hours I would put down to Greylisting, but 1-2 days is definitely too much. Is this reproducible? How many addresses have you tried this with?
What do the full headers of the (received) mails look like? The "received from: .... "path should tell you at which point it took 1-2 days to deliver.
Maybe you can install PHPMailer as a Vendor and create a Component called "Mail"...
And don't forget to authenticate with your SMTP server! :)
Ignore the whole PHP element of it for a moment.
If its a linux server for example, send a mail from the command line e.g. mail myemail#me.com
see if the same thing is happening that way. Its quite likely its a server configuration issue not a php or cakePHP issue.
Look up a few basics like having a FQDN and maybe look into setting up SPF records for your email. Make sure the emails are coming from your domain name not someone elses e.g. not the users email.
Also check if you have email spam software set up that could be grey listing you email on the way out (unlikely but possible). the mostly like thing is the destination spam filter is delaying it. Try send to a gmail account and see if it gets through fine or goes into spam.
Do all this without touching PHP, if all is going fine there then set up a basic php script to do a basic email not using CakePHP, if that works fine then you know its CakePHP etc but I doubt it.
So after further digging, I realized that it was our server host's problem. We use Slicehost, and it just so happens that a range of ips that had been blacklisted included our own ip. We got our name off the list, and we're good to go.