Jump to content
xisto Community
Nameless_

Cron Questions... Cron Not Working? What Is It? All on my MAMP local webserver...

Recommended Posts

Hi people, sorry for taking up your time. This will be very short, I promise.

I don't know if it is just me or anything, but after I downloaded Drupal onto my local MAMP webserver, the cron module thingy isn't really working... This is the error message received:

 

In Administer: Cron has not run. Please visit the status report for more information.

 

And in the status report... everything is working fine apart from this:

 

Cron maintenance tasks

Never run

Cron has not run. For more information, see the online handbook entry for configuring cron jobs. You can run cron manually.

 

 

Drupal core update status

No update data availableNo information is available about potential new releases for currently installed modules and themes. To check for updates, you may need to run cron or you can check manually. Please note that checking for available updates can take a long time, so please be patient.

I don't really know what has gone wrong... but, would someone explain what has gone wrong, and what is cron anyway? What does cron do?

 

For more reference, however, I have followed c0mputerwhiz1's youtube tutorial in installing drupal onto my local webserver. This is the link here: http://forums.xisto.com/no_longer_exists/

 

Thanks for all the help, people.

Share this post


Link to post
Share on other sites

cron jobs are tasks to trigger scripts at certain time periods when you want certain scripts runnow i have never used drupal so i don't know specifically what cron jobs would be run except maybe backup or mail management.maybe what you are reading isn't even any error message and just letting you know that no cron jobs have been run.this can be a posibility without assuming anything.with that said, go to the drupal site and post in their forums for the answer.what i would do quickly myself is to see if drupal has tried to set up any cron jobs. why don't you go in to your cpanel. under the advanced area(i believe) , you will see cron jobs. go in there and see if any scripts are meant to run.i can google a couple things for you but you should really start knowing how to google answers yourself so you can get your answers that are possibly available to you quicker.ok. editing this post after a little investigation....what i found out is that drupal installs with a maintanance file which is usually yourdomain.com/cron.php. to run mainantence manuall, it's as easy as just going to that part of your site. just enter it in to your web browser. if it's a small site, you don't have to run it that often. maybe once a week or even once a month. so you would still have to enter the url to trigger the mainanence. personally, i don't know what's in that file or what specific jobs will be triggered. you can look for yourself.to run it automatically(i would suggest maybe once a week for now), you should go in to your cpanel and if that cron job isn't there, add it. cpanel makes it easy for even a beginner to run a task at a specific time.you can set it to run weekly at midnight or daily at any given time....etc. it's a really neat feature if you've never heard of cron jobs before. i've never used them myself since i never really had the need. i am a newbie myself but i hope this information helps.sounds to me, according to the message you posted, it was just letting you know that no cron jobs ran. not that any cron jobs NEED to run. but i would try to set up that cron.php file to run automatically since drupal seems to think it's important for maintanence purposes.but lastly, i do have to say that the title you gave this thread is misleading. it's not the fact that cron jobs aren't working in your case. it's the case that cron jobs aren't running at all because you yourself haven't run any....including cron.php i thought because of the title, you were getting errors in cron jobs or mysql. but this isn't the case.you know, a little investigation on your part would probably most likely solve any problem you have. if you want to trial and error things and see what webhosting services has to offer, you also need to learn to undue any mistakes and also trouble shoot problems that other people probably already had in the past(you will probably not be the first to experience any specific problem) and google the problem and look within the first two pages of the SPECIFIC search. i solve 95% of all my problems and questions just doing THAT.plus, nameless, it's a good feeling when you have a problem and didn't have to ask anyone for a solution when you have solved a problem on your own. it really is a good feeling. i suggest you start trying it.

Edited by anwiii (see edit history)

Share this post


Link to post
Share on other sites

My cron file? Here it is:
This is found in my cron.php file

<?php// $Id: cron.php,v 1.36 2006/08/09 07:42:55 dries Exp $/** * @file * Handles incoming requests to fire off regularly-scheduled tasks (cron jobs). */include_once './includes/bootstrap.inc';drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);drupal_cron_run();

It looks rather short though. I don't whether the problem is because of it being hosted on a local MAMP webserver and not an online, real one, but anyway, it is said that if I click "run cron manually", then the error wouldn't show up. Of course, that means that I will have to do it myself, and since I don't even know what cron is and what it does, I wouldn't be able to do that myself.

@anwii: For clarification, this is on a local webserver, not on a proper cPanel.

@jlhaslip: what do you mean by have tabs between data? I'm new at coding, though I can make some certain very simple changes, like change the footer of a template, so I don't know what you mean.

Share this post


Link to post
Share on other sites

just run the file manually and see what happens. have you even run the file? what was the point in creating your own server anyway? are you just fidgeting around?

seriously dude, you need to just get your own website up and running. ANY website...and have it online live no matter what you think of it at first and start making those simple changes day to day that will allow this website to be a part of you and what you created. there is no such thing as perfection so stop thinking that everything has to be perfect. the flip side is...you are learning through all the stuff you are trying to experiment on. BUT the real question is....what is learning if you can't put it to good use.

so just create something online that you already know how to do. and go from there. learn as you go. don't just learn and still act confused what you want to do

as far as your cron jobs, there is absolutely nothing wrong from what i have seen in this thread. you have just failed to activate any. so simply, if you just run that file, cron.php, you should be fine. just do it manually. even if you don't run that file, you should be fine. there are no errors and everything was installed properly and everything is working properly.

My cron file? Here it is:This is found in my cron.php file

<?php// $Id: cron.php,v 1.36 2006/08/09 07:42:55 dries Exp $/** * @file * Handles incoming requests to fire off regularly-scheduled tasks (cron jobs). */include_once './includes/bootstrap.inc';drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);drupal_cron_run();

It looks rather short though. I don't whether the problem is because of it being hosted on a local MAMP webserver and not an online, real one, but anyway, it is said that if I click "run cron manually", then the error wouldn't show up. Of course, that means that I will have to do it myself, and since I don't even know what cron is and what it does, I wouldn't be able to do that myself.

@anwii: For clarification, this is on a local webserver, not on a proper cPanel.

@jlhaslip: what do you mean by have tabs between data? I'm new at coding, though I can make some certain very simple changes, like change the footer of a template, so I don't know what you mean.

Share this post


Link to post
Share on other sites

just run the file manually and see what happens. have you even run the file? what was the point in creating your own server anyway? are you just fidgeting around?
seriously dude, you need to just get your own website up and running. ANY website...and have it online live no matter what you think of it at first and start making those simple changes day to day that will allow this website to be a part of you and what you created. there is no such thing as perfection so stop thinking that everything has to be perfect. the flip side is...you are learning through all the stuff you are trying to experiment on. BUT the real question is....what is learning if you can't put it to good use.

so just create something online that you already know how to do. and go from there. learn as you go. don't just learn and still act confused what you want to do

as far as your cron jobs, there is absolutely nothing wrong from what i have seen in this thread. you have just failed to activate any. so simply, if you just run that file, cron.php, you should be fine. just do it manually. even if you don't run that file, you should be fine. there are no errors and everything was installed properly and everything is working properly.


Haha, I suppose you always give the best advice, don't you? I want thinking of making the whole site on my local webserver first before putting it up online, but I suppose you are right... Hmm... I still have to do everything again on my online site anyway, don't I?

Anyway, I'll have to give it a few days more. I only started on my own personal site today on my local webserver, so I only found out the template that I am going to use today, and I still have to know what exactly I am going to put on my site and see if things work properly. I also have to see what modules I have to install and all that. Plus, there are a few more questions I need answered before I get my site up properly... :)

But I promise you, anwii... I know that I've been trying to postpone this a long as possible, but I've got a time limit to follow and once I get everything done I will do as you say... :D Thanks for the advice though. I just need a bit more time... :(

Share this post


Link to post
Share on other sites

I've been wondering... how do WordPress, Joomla, Drupal etc. schedule their jobs when on a Microsoft Windows environment, where we don't have cron? I haven't seen then create any tasks in the Windows task scheduler. Do the tasks even run at all?BTW, as we're discussing a PHP-based application here, there's something I've been wanting to ask about PHP. I've been developing on PHP for a while and one of the things I dislike about it is that PHP doesn't have a global storage area that I can use. Sure, I can store to the database or to a file or to any other location, but that's extra work - it would be nice if the kind developers could write a session-like collection for storing data common to all users. ASP.NET has it, and so does JSP - they even have many developers using it so it must mean that it's a useful feature, isn't it? I use it to store a couple of variables that I read at startup in an ASP.NET application instead of having to query the database each time. I know somebody is going to mention about databases having really good caches and their ability to store the table data in memory, but think about parsing a SELECT query each and every time a user request went to the server. The database server may have to calculate the execution plan once but it still have to compare the strings and ensure that it's the same as the statement for which it has a cached execution plan.I'd also like to mention that ASP.NET has a scheduler-like functionality which is actually a workaround. By placing an object into the ASP.NET cache with a specified time interval and a callback function, the cache is cleared sometime after the time interval (I know it might take longer but it does at some point in time) and then the callback function is invoked. This callback function can contain code for scheduled activities instead of creating a cron job or a scheduled task.

Share this post


Link to post
Share on other sites

The OP is running a MAMP server, which is a Unix/Linux-based Apache stack on a Mac. I think the cron is set up for that package, but maybe not. Perhaps PM to Alex the Mod to find out. He is running a Mac also.

[edit]
http://forums.xisto.com/no_longer_exists/
[/edit]

Share this post


Link to post
Share on other sites

yea, windows doesn't use cron jobs. you have to go through the task scheduler. same principle.

I've been wondering... how do WordPress, Joomla, Drupal etc. schedule their jobs when on a Microsoft Windows environment, where we don't have cron? I haven't seen then create any tasks in the Windows task scheduler. Do the tasks even run at all?

Share this post


Link to post
Share on other sites

Haha, OK... thanks for the help though. I suppose it doesn't really matter as long as cron is working properly on my public site, but that has yet to come... I am not up to that stage yet. Anyhow, if cron is just for updating the latest version of Drupal, then I'm not that worried, as long as it is not neccessary and life threatening to my site if it isn't working properly, I should be able to survive...I don't think that I am the only one wrong with the cron job thing, I've seen other threads where Drupal on MAMP doesn't have a working cron job too... so I don't think that I am unique in this case... which is good. :) I doubt Alex will reply though. Wait... who's alex?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.