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.

Cronjob best solution

Discussion in 'General Discussion' started by MikeMc, Feb 25, 2003.

  1. MikeMc

    MikeMc Well-Known Member

    Joined:
    May 8, 2002
    Messages:
    161
    Likes Received:
    0
    Trophy Points:
    16
    Hi,

    could you tell me which solution is the best for calling an url via cpanel cronjobs?

    - lynx
    - GET
    - wget
    - fetch

    Thank you
     
  2. jimcarter

    jimcarter Well-Known Member

    Joined:
    Jun 30, 2002
    Messages:
    152
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    UK
    I use curl,
    But I have found that using wget is more reliable, but it is a pain when you get a load of downloaded files in your home directory, so I usually add another cron job to delete the file after downloading it,
    Thanks
     
  3. gic

    gic Well-Known Member

    Joined:
    Jun 28, 2002
    Messages:
    69
    Likes Received:
    0
    Trophy Points:
    6
    Couldn't you just add > /dev/null to the end instead of making a new cron job to do this? I am not very good with this, but I have see this before.
     
  4. ecoutez

    ecoutez Well-Known Member

    Joined:
    May 23, 2002
    Messages:
    152
    Likes Received:
    0
    Trophy Points:
    0
    wget has a --delete-after option which already takes care of this. ie:

    0,15,30,45 * * * * root /usr/bin/wget --delete-after http://username:password@some.website.tld/script.php > /dev/null

    - Jason
     
Loading...

Share This Page