0

I have a problem with the system sending Magento . Do not want to send e -mail order confirmation (e- mails about the account is sent ) . When you refresh a cron job in my web browser , these emails are sent , but I wish it would happen automatically. I installed the program sheulder which shows that the e- mails are stuck in the queue and do not want to leave. I would ask you to explain the process of how to fix this for a beginner .

1 Answer 1

1

If you haven't by now, please set up a cron job on your server which calls <magento_root>/cron.sh every 5 minutes or less. That will cause all emails to be sent.

I had a similar issue where many emails were being sent (for some reason they weren't queued) but others just didn't get out until I set up cron the right way.

If you are on Linux, just add this line to your crontab file, which you can access via the Linux command crontab -e

*/5 * * * * /bin/sh /absolute/path/to/magento/cron.sh

For more information about other operating systems and cron's role in Magento, check this site.

If you get errors regarding /proc, comment out the lines in cron.sh which check whether the process is already running.

13
  • I still don't know what i should do. In magento system option i have seted evry 5 minutes but it dont still work. I have outside server, not in my home and i dont have acces to it. Only through ftp
    – Yardi
    Commented Jan 31, 2015 at 11:40
  • @Yardi do me a favor and reread my answer. You need a cron job on your server system, has not much to do with Magento. That cron job will execute a file from magento which takes care of all jobs to be done. Once you read my answer again, are you on linux or windows or something else?
    – Yorrd
    Commented Jan 31, 2015 at 12:16
  • I working on windows, but my server is i think on linux but i dont have acces to it. I dont have cron.js too. Only in main folder i have cron.sh and cron.php. I try to set up on my server but i have that messenages: Could not open input file: /home/warmit/ftp:/WarmIT/cron.php Could not open input file: /home/warmit/ftp:/WarmIT/cron.sh
    – Yardi
    Commented Jan 31, 2015 at 12:49
  • @Yardi, sorry, it's cron.sh, typo. Please contact your hoster, usually they will allow you to set up cron jobs. Otherwise you need a script which accesses yourdomain/cron.php every minute, that will do the same. Either execute cron.sh via a cron job or send a request to the URL cron.php. For a quick solution you can also just go there with your browser, but dont forget to automate it because else no emails will be sent when you don't visit that URL frequently
    – Yorrd
    Commented Jan 31, 2015 at 12:56
  • Setting up a cronjob that executes cron.php every minute is not a good idea. You can do that with cron.sh but not the php version, since it doesn't guard against multiple instances being invoked. If you invoke cron.php, use flock(1). I realize this confuses the original poster even more, yet, many sites have totally wrecked indexes, stock amounts or failed imports have their root cause in overlapping cron.php runs.
    – user4351
    Commented Jan 31, 2015 at 13:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.