1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Alternatives: Hostgator Restriction On Cron Jobs

Discussion in 'General Programming Chat' started by userlogsin, Feb 13, 2010.

  1. userlogsin

    userlogsin Jr. VIP Jr. VIP Premium Member

    Joined:
    Feb 14, 2009
    Messages:
    240
    Likes Received:
    23
    Location:
    On your screen...lol
    Hi Friends

    I use h*stgator and have a Baby Croc. package.

    I need a text file to be updated every 5 minutes. What I did was to make a php file that updates the text file everytime it is run. In order to do so I wanted to set up a cron every 5 minutes. But h*stgator says that I cannot run a cron sooner than 15 minutes.

    I don't want them to come up and ban my account so am looking for other alternatives.

    Can anyone tell if what other alternatives do I have to get this done (update a text file every 5 minutes.). I dont want to upgrade my account there to VPS.

    Any help would be appreciated.
     
  2. userlogsin

    userlogsin Jr. VIP Jr. VIP Premium Member

    Joined:
    Feb 14, 2009
    Messages:
    240
    Likes Received:
    23
    Location:
    On your screen...lol
    I know. But are there no other options.


     
  3. Jagged55

    Jagged55 Power Member

    Joined:
    Mar 27, 2008
    Messages:
    747
    Likes Received:
    325
    Occupation:
    Internet Marketing
    Location:
    Canada
    What about services like this one? I have never used them and can't say for sure that this is a trusted one but it might work. I am sure there are other sites like this one also

    Code:
    http://www.setcronjob.com/
     
    • Thanks Thanks x 1
  4. userlogsin

    userlogsin Jr. VIP Jr. VIP Premium Member

    Joined:
    Feb 14, 2009
    Messages:
    240
    Likes Received:
    23
    Location:
    On your screen...lol
    This looks great. Have registered. lets see how it goes.


     
  5. userlogsin

    userlogsin Jr. VIP Jr. VIP Premium Member

    Joined:
    Feb 14, 2009
    Messages:
    240
    Likes Received:
    23
    Location:
    On your screen...lol
    I have checked the site (free account),. Does not work for me. Wish it did.
     
  6. userlogsin

    userlogsin Jr. VIP Jr. VIP Premium Member

    Joined:
    Feb 14, 2009
    Messages:
    240
    Likes Received:
    23
    Location:
    On your screen...lol
    I was suggested to create two cron jobs, each of which will fire up a two php pages (copies) started at different intervals.

    Still looking for more ideas. Let me know if anyone of you can think of anything else.
     
  7. MuonTrail

    MuonTrail Registered Member

    Joined:
    Mar 5, 2009
    Messages:
    96
    Likes Received:
    93
    Setup multiple crons like you just mentioned. Or stick with the one cron and change your script to do its thing, sleep for 5 minutes, and then repeat.
     
    • Thanks Thanks x 1
  8. FreakStone

    FreakStone BANNED BANNED

    Joined:
    Jun 26, 2009
    Messages:
    53
    Likes Received:
    8
    Your better off getting a vps for $5 a month.
     
    • Thanks Thanks x 1
  9. userlogsin

    userlogsin Jr. VIP Jr. VIP Premium Member

    Joined:
    Feb 14, 2009
    Messages:
    240
    Likes Received:
    23
    Location:
    On your screen...lol
    Where would you get a VPS for $5 a month
     
  10. dirtybirdy

    dirtybirdy Newbie

    Joined:
    Feb 8, 2010
    Messages:
    1
    Likes Received:
    1
    Simulate cron with a PHP script which runs on every hit on the main page.

    Hit -> Script checks last run time -> If more than 5 minutes ago then run update -> log time.
     
    • Thanks Thanks x 1
  11. userlogsin

    userlogsin Jr. VIP Jr. VIP Premium Member

    Joined:
    Feb 14, 2009
    Messages:
    240
    Likes Received:
    23
    Location:
    On your screen...lol
    That is a nice idea. Exactly what I needed. Will save system resource as well as money. coooll...
     
  12. birdiebob

    birdiebob Junior Member

    Joined:
    Apr 1, 2008
    Messages:
    100
    Likes Received:
    26
    I had the same experience ..they wiped out my contents without telling me . so , you think I can upgrade and not have that problem? dont really want to move hosting for that domain.
     
  13. userlogsin

    userlogsin Jr. VIP Jr. VIP Premium Member

    Joined:
    Feb 14, 2009
    Messages:
    240
    Likes Received:
    23
    Location:
    On your screen...lol
    I spoke to them about changing the hosting to a VPS but they do not provide support for smaller packages. The best way would be to use their backup feature.
    Backup the site --> Download the contents to Hard Drive --> Sign up for a better package --> Use backup to reinstall site on new server -->Change name servers and wait till it is changed --> Once done close the other account.

    tis would ensure that you dont have to spend a lot of time manually moving hosting. It would also ensure that your site has ZERO downtime.