cancel
Showing results for 
Search instead for 
Did you mean: 

Can not set up Cronjobs via SSH

Can not set up Cronjobs via SSH

Hi all,

 

I am using Magento 1.9.01 version. 

If customers register on my site, they get an e-mail -> its okay.

But if they order something, they do not get confirmation e-mail and also if I send it via admin panel, also invoices -> not okay.

 

I do not have cPanel and downloaded putty and logged it with SSH. On the internet are a lot of codes for seting up cronjobs, each 5 minutes, system is sending e-mails.. but

 

I entered this code at first: 

crontab -e

 

Than this code with my own code:

*/5 * * * * /var/www/pfad/zu/magento/cron.sh

 Result: No such file or directory

 

Whats wrong?

 

Regards,

5 REPLIES 5

Re: Can not set up Cronjobs via SSH

Anyone an idea?

Re: Can not set up Cronjobs via SSH

hi,

Your cron should probably look something like one of these.. the first part e.g. the */5 * * * * means that the cron will run *every* 5 minutes.

 

The second pard.. e.g /bin/sh (etc..) is the execution path or path to PHP on your sever - these can usually be provided by your host since they can be different depending on your server setup.

 

The 3rd part . e.g. /[magento_path]/cron.php (or cron.sh) is the full path to the cron file on your server.

 

*/5 * * * * /bin/sh /[magento_path]/cron.sh 
*/5 * * * * /bin/bash /[magento_path]/cron.sh 
*/5 * * * * /usr/bin/php /[magento_path]/cron.php 
*/5 * * * * /usr/local/bin/php -f /[magento_path]/cron.php

Feel free to try the 4 setups above - however I would recommend contacting your host and they can inform you how to set the cron correctly depending on your setup.

Problem solved? Click Accept as Solution!
Magento Certified Developer Plus | www.iwebsolutions.co.uk | Magento Small Business Partner

Re: Can not set up Cronjobs via SSH

Just an addition to the above; you mentioned you used PuTTY to connect to your server.. once you've located your cron.php file.. e.g cd yoursite/public_html - then you can type pwd and this wil give you the full path to the current directory you are in - this is useful for checking that the path to your cron file is correct (the 3rd part of the cron setup)

Problem solved? Click Accept as Solution!
Magento Certified Developer Plus | www.iwebsolutions.co.uk | Magento Small Business Partner

Re: Can not set up Cronjobs via SSH

Hi there,

 

thanks for your answers - I will try it out today.

 

I know my path -> checked it with info.php Smiley Wink

 

Regards,

Re: Can not set up Cronjobs via SSH

Hi,

From the info you sent me in your PM - you could try the following (the forums wouldn't validate the HTML when I tried to send you this via the PM)

 

*/5 * * * * /usr/lib/php5.4 /kunden/homepages/39/d444325443/htdocs/herison/cron.php

 

Problem solved? Click Accept as Solution!
Magento Certified Developer Plus | www.iwebsolutions.co.uk | Magento Small Business Partner