Jump to content

Domain Renewal Reminders not being sent when I expected


JamesOakley

Recommended Posts

Hmm

 

So I've got my domain renewal emails set to go out after 60 days, then 30 days, then ...

 

I had a couple of domains that were past 60 days but no emails had gone out. Then, suddenly, (when one had 52 days to go, and the other had 49), both clients got an email to let them know that their domains were due to expire in the next 60 days (such as domain X, with 49 days to go). Each client only had one domain, so WHMCS wasn't waiting to roll their multiple domains into one reminder.

 

How come? Bug or feature? Surely, the cron run on {due-date minus 60 days} should have triggered the first reminder?

Link to comment
Share on other sites

Hi James,

 

I think this comes under the heading of feature rather than bug...

 

http://docs.whmcs.com/Domains_Management#Grouped_Renewal_Reminders

 

WHMCS will automatically group together upcoming domain expiration notice emails into a single email for each client.

 

This means a client with multiple domains expiring in the same month they receive a single reminder email for them all instead of being bothered by an individual email for each domain.

 

Any domain reminder option that is set to 30 or more will send on the 11th of the month. This will group together any domains for a client that expire "in the next xx days".

 

Anything less than 30 would be sent exactly on the day that the reminder is defined. This will still group together the domains, but in the format of "the domains will expire in xx days", so only domains that have the same next due date will be grouped for these notices.

 

Once a reminder is sent, this is defined against the client domain record so another notice is not sent for the same period.

 

Notices are sent based on the next due date on the domain, not the expiry date. This is because the expiry date can be different to the next due date, if you wished to have your client renew the domain early for example.

btw - there is no way to change the date for sending the email reminder currently sent on the 11th of the month, it's coded into whmcs and can't be altered.

Link to comment
Share on other sites

Well spotted, Brian.

 

I had read that (not properly), and noticed that multiple reminders for the same client would be rolled together into one email. I had totally missed the fact that even if a client has only one domain, reminders for over 30 days would be sent on the 11th of the month.

 

TBH, that is a surprising "feature", that (IMHO) should at least be optional. I had assumed that multiple reminders would be combined by WHMCS checking to see if that client has any other domain renewals due in the next 30 days, and if so waiting until it can send both. It's counter-intuitive that it will wait until a preset day of the month to send the reminder.

 

Oh well - at least you found it in the docs, so we now know it's a feature rather than a bug!

Link to comment
Share on other sites

I know this isn't directly related - but I've found alarmingly that some customers are not getting ANY renewal reminders for domains, while others are. Looking at the WHMCS activity log and mail logs show no attempt to send out the messages at all for the domains that customers have reported this problem with. So either the cron job is failing on particular users or domains for some reason, or WHMCS is deliberately skipping these. Why might that be?

 

I have no idea when this started but I suspect it has been happening since we updated to 5.3 recently.

 

I really have no idea how to troubleshoot this. If I raise a support ticket I will just get a request to have access to my server and there is no way I'm letting these muppets loose on my server.

 

I'm using Mail Type SMTP - encoding 8bit

 

I might switch to PHP mail and see if that makes a difference.

Link to comment
Share on other sites

Hi Chris,

 

your post made me chuckle - that's always appreciated on a Friday afternoon! :)

 

i've just gone through our previous upcoming reminder emails, and I can't spot any that are obviously missing when comparing them to domains invoiced - we're using PHP Mail() 8-bit.

 

that doesn't rule out there being an issue with whmcs - just that I don't think that i'm seeing it locally.

 

two possible reasons (unlikely though) why this might be occurring for you could be that you have a hook installed that prevents email reminders to specific clients (though hopefully you'd already know if you had!), or maybe if the domains are free when renewed with hosting - I don't know how whmcs would handle renewal reminders in that case as it's not something we do.

 

I'd be tempted to suggest switching to PHP Mail() for a few weeks and seeing if there is any difference.

Link to comment
Share on other sites

Thanks Brian - When you say "i've just gone through our previous upcoming reminder emails, and I can't spot any that are obviously missing when comparing them to domains invoiced"

 

How did you do that?

 

What I mean to say is that it's seemingly impossible to identify the emails that should have been sent today. The WHMCS cron says...

 

25 Domain Renewal Notices Sent.

 

I look in the system Email message log and I count that indeed 25 emails went out.

 

But I can't easily identify what domains should have had reminders today. These would be I guess now - only domains that have a renewal date in 14 days or 7 days or tomorrow - but this terrible system doesn't even have a search option where you can easily identify and filter out domains expiring in X days. The search options in WHMCS are so weak and so fu**ing broken.

Edited by Chris74
Link to comment
Share on other sites

When a reminder is sent a piped entry is added to the "reminders" field in the "tbldomains" table. Then when a domain is renewed the piped entries are supposed to be cleared for the renewed domain. However, there is a bug where this doesn't happen and the piped entries remain.

 

What this means is the next time domain renewal notices are due to be sent out they are skipped as the reminder for say "7" days is already in the "reminders" field so WHMCS thinks it has already been sent. I suspect that you have entries from the last time the reminders were sent out prior to the last renewal (maybe last year).

 

WHMCS has confirmed this bug (case #4578 ) to us but have said they do not have a time scale for a fix. They have said "you can work around this by setting the 'reminders' field to empty." This is what we did on all domains so that at least we will not have another issue for the next year. Fingers crossed they will fix it by then!!

Link to comment
Share on other sites

Chris,

 

Thanks Brian - When you say "i've just gone through our previous upcoming reminder emails, and I can't spot any that are obviously missing when comparing them to domains invoiced"

 

How did you do that?

the "Upcoming" emails are bcc'd to us, so I just compared the domains in those emails against the domain renewal invoices...

 

What I mean to say is that it's seemingly impossible to identify the emails that should have been sent today. The WHMCS cron says...

 

25 Domain Renewal Notices Sent.

 

I look in the system Email message log and I count that indeed 25 emails went out.

 

But I can't easily identify what domains should have had reminders today. These would be I guess now - only domains that have a renewal date in 14 days or 7 days or tomorrow - but this terrible system doesn't even have a search option where you can easily identify and filter out domains expiring in X days. The search options in WHMCS are so weak and so fu**ing broken.

I have two useful widgets in my admin area - Expiring Domains and Upcoming Renewals... though the "Expiring" one is duplicated by the other, so I don't really need both.

 

the "Upcoming Renewal" widget is based on the code posted in the user contributions thread below, but i've tweaked my version to add more columns and information (e.g product type, payment method and invoice generation date etc).

 

http://forum.whmcs.com/showthread.php?43532-WHMCS-v5-0-Upcoming-Domains-and-Hosting-renewal

 

VJz1V77.png

 

so I can quickly look at that and I then know which invoices should be auto-generated next and on what date.

 

invoice date is next due date minus 14 days, so it probably wouldn't be too difficult to replicate the widget but replace existing columns with dates when 1st/2nd/3rd reminders would be sent for each domain as they're just similar calculations (next due date minus x, y or z).

Link to comment
Share on other sites

it might be worth considering taking the sql query from the widget and putting it into a report - that way you don't need to have it enabled and can just run it when required.

 

Thanks, will do that.

 

Could you possibly clarify that this is the current (5.3) and correct default domain renewal notice...

 

{if $days_until_expiry}The domain(s) listed below are due to expire within the next {$days_until_expiry} days.{else}The domain(s) listed below are going to expire in {$domain_days_until_expiry} days. Renew now before it's too late...{/if}

{if $expiring_domains}{foreach from=$expiring_domains item=domain}{$domain.name} - {$domain.nextduedate} ({$domain.days} Days)
{/foreach}{else}{$domain_name} - {$domain_next_due_date} ({$domain_days_until_nextdue} Days){/if}

Link to comment
Share on other sites

When a reminder is sent a piped entry is added to the "reminders" field in the "tbldomains" table. Then when a domain is renewed the piped entries are supposed to be cleared for the renewed domain. However, there is a bug where this doesn't happen and the piped entries remain.

 

What this means is the next time domain renewal notices are due to be sent out they are skipped as the reminder for say "7" days is already in the "reminders" field so WHMCS thinks it has already been sent. I suspect that you have entries from the last time the reminders were sent out prior to the last renewal (maybe last year).

 

WHMCS has confirmed this bug (case #4578 ) to us but have said they do not have a time scale for a fix. They have said "you can work around this by setting the 'reminders' field to empty." This is what we did on all domains so that at least we will not have another issue for the next year. Fingers crossed they will fix it by then!!

 

 

 

I only just saw this reply. Thank you - it would explain the problem I'm having.

 

Having looked into this I can explain in more detail for anyone else having this problem... Each time a reminder is sent out, the number of days from that reminder date is added to the reminders field for a domain to indicate which reminders have been sent - so an expired domain might look like this...

 

|60||30||14||7||1|

 

One that expires in 20 days will look like this...

 

|60||30|

 

If the client renews that domain before the 14 day reminder but the field doesn't get cleared, they will not receive the 60 or 30 day reminders for their domain the following year - which is why some domains get some reminders and some get none at all (those getting none will be domains that were last renewed on or after their expiry date).

 

I ran this query...

 

UPDATE tbldomains SET reminders='' where status='Active'

 

So as Pete says, this will resolve the problem temporarily.

Edited by Chris74
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated