Please help me with cron jobs

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • jimtsik
    Private First Class

    • Mar 2007
    • 6

    Please help me with cron jobs

    I want to run the following file ..

    /etc/cron_backup.sh

    which is taking backup and emails it to my gmail account .

    What is the right command to enter at the cpanel via unix-style ?

    Thank you in advance
  • navaldesign
    General & Forum Moderator

    • Oct 2005
    • 12080

    #2
    Re: Please help me with cron jobs

    Hi Δημητρη,

    I'm not sure about your .sh script. It should be php. In this case, the command should be:

    cd '/home/username/public_html/etc/'; php -q 'cron_backup.php' > /dev/null
    Navaldesign
    Logger Lite: Low Cost, Customizable, multifeatured Login script
    Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
    DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
    Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!

    Comment

    • jimtsik
      Private First Class

      • Mar 2007
      • 6

      #3
      Re: Please help me with cron jobs

      Thank you very much , i finally found a very nice php script that it makes backup my database and emails it to my gmail !!!

      Comment

      • playmode
        Private First Class

        • Mar 2008
        • 7

        #4
        Re: Please help me with cron jobs

        Hello,

        I tried setting up the cron jobs using the following command line:

        " home/azbirjx/public_html/purchase-credits.php "

        and

        cd '/ home/azbirjx/public_html/'; php -q 'purchase-credits.php' > /dev/null ;



        In both cases I received similar emails with the following error message:


        From: Cron Daemon [root@voda22.voda22.com]
        To: admin@auditionbase.com
        Subject: Cron <azbirjx@voda22> home/azbirjx/public_html/purchase-credits.php

        /bin/sh: home/azbirjx/public_html/purchase-credits.php: No such file or directory

        and

        From: Cron Daemon [root@voda22.voda22.com]
        To: admin@auditionbase.com
        Subject: Cron <azbirjx@voda22> cd '/ home/azbirjx/public_html/'; php -q 'purchase-credits.php' > /dev/null ;

        /bin/sh: line 0: cd: / home/azbirjx/public_html/: No such file or directory


        What is the problem and how can it be resolved???

        John

        Comment

        • navaldesign
          General & Forum Moderator

          • Oct 2005
          • 12080

          #5
          Re: Please help me with cron jobs

          Your command line is wrong: there is a blank space after / and before home so it resuts in the above error.

          Correct one: cd '/home/azbirjx/public_html/'; php -q 'purchase-credits.php' > /dev/null ;


          Pleeeeease! Dont make multiple posts on the same issue: you posted here, in the CronJobs tutorial, AND in my private messages section!!
          Navaldesign
          Logger Lite: Low Cost, Customizable, multifeatured Login script
          Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
          DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
          Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!

          Comment

          • playmode
            Private First Class

            • Mar 2008
            • 7

            #6
            Re: Please help me with cron jobs

            Thank you Naval design!! your the best!!

            Comment

            Working...
            X