+ Reply to Thread
Results 1 to 6 of 6

Thread: Path to get

  1. #1
    jcolburn is offline x10Hosting Member jcolburn is an unknown quantity at this point
    Join Date
    Aug 2009
    Posts
    3

    Path to get

    what is the path to "get"?


    Let me explain a little,.. I've just installed Elgg,..

    Here is step 4 to the installation:
    Code:
    4. Install your crontab (UNIX ONLY)
    
    Cron is a UNIX command which allows programs to be run at set 
    times of the day.
    
    If you want to take advantage of some of the maintenance 
    functions such as log rotation or garbage collection, you must 
    install a cron tab to trigger these events.
    
    We have provided an example crontab as /crontab.example. Edit this 
    with a text editor to provide the details of your site, rename it
    to another filename (eg 'crontab.mine') and install it with the 
    following command:
    
       			crontab crontab.mine 
       			
    Substitute your filename for 'crontab.mine'.
    Here's crontab.example:
    Code:
    # Crontab example.
    #
    # This file is an example of triggering Elgg cron events. Modify and register events 
    # as appropriate.
    #
    # See http://docs.elgg.org/wiki/Cron for more information
    #
    # @author Marcus Povey
    
    # Location of GET (see: http://docs.elgg.org/wiki/What_is_get)
    GET='/usr/bin/GET'
    
    # Location of your site (don't forget the trailing slash!)
    ELGG='http://www.example.com/'
    
    # The crontab
    # Don't edit below this line!
    @reboot $GET ${ELGG}pg/cron/reboot/
    * * * * * $GET ${ELGG}pg/cron/minute/
    */5 * * * * $GET ${ELGG}pg/cron/fiveminute/
    15,30,45,59 * * * * $GET ${ELGG}pg/cron/fifteenmin/
    30,59 * * * * $GET ${ELGG}pg/cron/halfhour/
    @hourly $GET ${ELGG}pg/cron/hourly/
    @daily $GET ${ELGG}pg/cron/daily/
    @weekly $GET ${ELGG}pg/cron/weekly/
    @monthly $GET ${ELGG}pg/cron/monthly/
    @yearly $GET ${ELGG}pg/cron/yearly/
    I know '/usr/bin/get' won't work,.. cuz cron is blow`n up my mail box,..

    Edit:
    After having over 700 new email messages from cron:



    Im obviouly removing my cronjobs for the moment.
    But, I really could use some help here,..
    Last edited by jcolburn; 09-12-2009 at 09:23 AM. Reason: Automerged Doublepost

  2. #2
    descalzo's Avatar
    descalzo is offline Grim Squeaker descalzo has a brilliant futuredescalzo has a brilliant futuredescalzo has a brilliant future
    Join Date
    Jul 2009
    Location
    Ankh-Morpork
    Posts
    7,636

    Re: Path to get

    Unix commands are case sensative. It is GET, not get.

    Not sure if they have it enabled. All it does is grab a webpage. Since your cronjobs are not using the page, you could just substitute a php or perl script that retrieves the page/script (I assume that the page you are retrieving is doing the real cron job).

    You have one listed to run every minute. I think the admins do not want them to run that often.

    Crons We allow crons but they can not call a script hosted somewhere else and you must not have more than 1 running every 5 minutes.
    Last edited by descalzo; 09-12-2009 at 02:46 PM.
    Nothing is always absolutely so.

  3. #3
    jcolburn is offline x10Hosting Member jcolburn is an unknown quantity at this point
    Join Date
    Aug 2009
    Posts
    3

    Re: Path to get

    I'm aware that GET != get. I've tried /usr/bin/GET, it didn't work either. So, I figure it's a path error. I've also tried both get & GET without a path.

    I know what GET does. I'm not familiar with its syntax, as I usually use wget.

    I was unaware of x10's stance on cronjobs. Thank you for that tidbit of info.
    Last edited by jcolburn; 09-13-2009 at 10:33 AM.

  4. #4
    descalzo's Avatar
    descalzo is offline Grim Squeaker descalzo has a brilliant futuredescalzo has a brilliant futuredescalzo has a brilliant future
    Join Date
    Jul 2009
    Location
    Ankh-Morpork
    Posts
    7,636

    Re: Path to get

    Sorry, did not mean to get pedantic.

    Apparently GET not on the system (at least not in /usr or /bin paths) but

    /usr/bin/wget

    is.
    Nothing is always absolutely so.

  5. #5
    jcolburn is offline x10Hosting Member jcolburn is an unknown quantity at this point
    Join Date
    Aug 2009
    Posts
    3

    Re: Path to get

    Shorly after my last post, I decided to use wget. It works well.

    For those who dont know and are interested, this is what I did & why.

    My current cronjobs look simular to this:
    Code:
    */5 * * * * wget --quiet --output-document=/dev/null http://www.joecolburn.co.cc/pg/cron/minute/
    */10 * * * * wget --quiet --output-document=/dev/null http://www.joecolburn.co.cc/pg/cron/fiveminute/
    */15 * * * * wget --quiet --output-document=/dev/null http://www.joecolburn.co.cc/pg/cron/fifteenmin/
    30,59 * * * * wget --quiet --output-document=/dev/null http://www.joecolburn.co.cc/pg/cron/halfhour/
    0 * * * * wget --quiet --output-document=/dev/null http://www.joecolburn.co.cc/pg/cron/hourly/
    0 0 * * * wget --quiet --output-document=/dev/null http://www.joecolburn.co.cc/pg/cron/daily/
    0 0 * * 0 wget --quiet --output-document=/dev/null http://www.joecolburn.co.cc/pg/cron/weekly/
    0 0 1 * * wget --quiet --output-document=/dev/null http://www.joecolburn.co.cc/pg/cron/monthly/
    0 0 1 1 * wget --quiet --output-document=/dev/null http://www.joecolburn.co.cc/pg/cron/yearly/
    I changed the run times to conform to x10Hosting's cron rules (thanks Descalzo, I was compleatly unaware of that rule).

    I used the following options:

    --quiet
    When used at the command line, wget prints on the screen, as a cronjob the standard output gets sent to your email. With this option, the standard output gets turned off completely, so you dont get any e-mails from it.

    --output-document=/dev/null
    "--output-document=" changes the name of the file downloaded to what or where ever you choose. I used /dev/null so I dont have a root directory full of index.html.###

    For more information on wget you can get the manual here.
    Last edited by jcolburn; 09-15-2009 at 10:50 AM.

  6. #6
    descalzo's Avatar
    descalzo is offline Grim Squeaker descalzo has a brilliant futuredescalzo has a brilliant futuredescalzo has a brilliant future
    Join Date
    Jul 2009
    Location
    Ankh-Morpork
    Posts
    7,636

    Re: Path to get

    Interesting way to run cron jobs. But it looks like a possible headache/security problem if someone/thing started requesting those pages over the web.

    Add: If it becomes a problem, perhaps password protect the directory and then use the wget options:

    ‘--http-user=user’
    ‘--http-password=password’
    Last edited by descalzo; 09-15-2009 at 11:04 AM.
    Nothing is always absolutely so.

+ Reply to Thread

Similar Threads

  1. Path to Perl on web server?
    By emailtoarpit in forum Scripts & 3rd Party Apps
    Replies: 1
    Last Post: 08-21-2009, 11:02 AM
  2. Flash AS3 - Dialog Box (Returns Full File Path)
    By masterjake in forum Programming Help
    Replies: 4
    Last Post: 07-28-2009, 06:46 PM
  3. Domain change and SESSION PATH unwritable
    By sedlo in forum Free Hosting
    Replies: 2
    Last Post: 09-27-2007, 10:33 AM
  4. Path to files
    By estado3 in forum Free Hosting
    Replies: 2
    Last Post: 07-07-2007, 10:36 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers