The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Cron jobs for controller task

Discussion in 'General Discussion' started by neveryonas, Mar 26, 2015.

  1. neveryonas

    neveryonas Registered

    Joined:
    Mar 26, 2015
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Canada
    cPanel Access Level:
    Reseller Owner
    Hello,

    I am trying to set up a Cron job through CPANEL for a mailer script on a joomla site. As specified by the vendor of the mailer program I have entered the following command into my Cron job with just an example domain name not the real one



    wget -O /dev/null "http://mywebsite.com/index.php?opti...y=d41d8cd98f00b204e9800998ecf8427e&format=raw"

    What is returned every time the CRON job runs is:

    --2015-03-26 07:25:03-- mywebsite.com/index.php?opti...8ecf8427e&format=raw
    Resolving mywebsite.com... 69.89.31.158
    Connecting to mywebsite.com|69.89.31.158|:80... connected.
    HTTP request sent, awaiting response... 200 OK
    Length: unspecified [text/html]
    Saving to: “/dev/null”

    0K 6.24M=0s

    2015-03-26 07:25:05 (6.24 MB/s) - “/dev/null” saved [41]

    I am relatively new to CRON jobs, and not sure what this means. I can see that it connects fine but not sure what "Length: unspecified [text/html]" means. Any help would be great!
     
  2. cPanelJared

    cPanelJared Technical Analyst
    Staff Member

    Joined:
    Feb 25, 2010
    Messages:
    1,842
    Likes Received:
    18
    Trophy Points:
    38
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    This is actually a question about the data wget retrieves, not cron itself.

    "Length: unspecified [text/html]" means that there is no length specified in the header sent back from the server that hosts the URL you are loading with wget. It is common for dynamically-generated pages - like the index.php script you are loading - to not return a size in their headers.

    I did a Google search for the message and I found this in the search results. It indicates that you can pass the --server-response argument to wget to see the headers that wget receives:

    http://www.unix.com/shell-programming-and-scripting/33849-how-get-page-size-url-using-wget.html

    You can also run the same command from the shell and specify a real filename after the -O switch, instead of /dev/null, and examine the file to see exactly what wget retrieves.
     
  3. Yachha

    Yachha Registered

    Joined:
    Jul 2, 2015
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    0
    Location:
    Nepal
    cPanel Access Level:
    Website Owner
    Hi,

    We are running a classified website, it's domain.com and have implemented multiple cron and is working fine.
    The cron command looks like

    wget -O /dev/null domain.com/mytestlinklinkforcron
     
    #3 Yachha, Jul 2, 2015
    Last edited by a moderator: Jul 6, 2015
  4. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    676
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    Could you elaborate on the specific issue you are facing if it's working as expected?

    Thank you.
     
Loading...

Share This Page