Cron

Get help with installation and running phpBB 3.1.x here. Please do not post bug reports, feature requests, or extension related questions here.
Ideas Centre
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

NOTE: phpBB 3.1.x is at its End of Life stage and support will NOT be provided after July 1st, 2018.
User avatar
Dr.Death
Registered User
Posts: 400
Joined: Fri Apr 25, 2003 10:04 am
Location: Germany
Contact:

Re: Cron

Post by Dr.Death »

Thanks for your help and your advices.

Meanwhile I moved the cron task to "drdeath.f1webtip.cron.task.email_reminder" and using no more $user->setup() call.

Next steps are trying to avoid using the Global Vars.
Doc.
User avatar
John P
Registered User
Posts: 1237
Joined: Mon Jan 21, 2008 3:55 pm
Location: Netherlands
Name: John
Contact:

Re: Cron

Post by John P »

Looks the cron is locked everytime again.

Cron_lock: 1405883613 60eb692e631ebe73
Image
Webhosting, Custom MODs, Technical management, MOD installation and Webdesign
nicofuma
3.2 Release Manager
3.2 Release Manager
Posts: 546
Joined: Sun Apr 13, 2014 1:47 am
Location: Grenoble - France

Re: Cron

Post by nicofuma »

it should be good for the lock, its value is correct (the first part of the value of the lock is a timestamps and if we are above, the lock is ignored)
Member of phpBB Development-Team
No Support via PM
User avatar
John P
Registered User
Posts: 1237
Joined: Mon Jan 21, 2008 3:55 pm
Location: Netherlands
Name: John
Contact:

Re: Cron

Post by John P »

Thanks, the first one is a timestamp, also knows what the second means?

It's strange, its later than the timestamp but nothing is happening anymore.

When I reset the cron_lock to 0 it's working again.
Image
Webhosting, Custom MODs, Technical management, MOD installation and Webdesign
nicofuma
3.2 Release Manager
3.2 Release Manager
Posts: 546
Joined: Sun Apr 13, 2014 1:47 am
Location: Grenoble - France

Re: Cron

Post by nicofuma »

It is the value cron.lock_db?
The second value is just a random id.

EDIT: The lock is ignored if we are at least one hour after the timestamps
Member of phpBB Development-Team
No Support via PM
User avatar
John P
Registered User
Posts: 1237
Joined: Mon Jan 21, 2008 3:55 pm
Location: Netherlands
Name: John
Contact:

Re: Cron

Post by John P »

Thanks for the info.

So I subtracted one hour and replaced this value in cron_lock.
Refreshing index gives a new value in cron_lock

But should the value not be zero if cron was successfully?
Image
Webhosting, Custom MODs, Technical management, MOD installation and Webdesign
nicofuma
3.2 Release Manager
3.2 Release Manager
Posts: 546
Joined: Sun Apr 13, 2014 1:47 am
Location: Grenoble - France

Re: Cron

Post by nicofuma »

indeed, it should be 0. So there is two possible reasons: the cron task isn't finished, or an error was throw by the task and the script killed (and so the lock was not released).
Member of phpBB Development-Team
No Support via PM
User avatar
John P
Registered User
Posts: 1237
Joined: Mon Jan 21, 2008 3:55 pm
Location: Netherlands
Name: John
Contact:

Re: Cron

Post by John P »

How to know which task it was?

There is no php error log, there is no log in phpbb error log?
Image
Webhosting, Custom MODs, Technical management, MOD installation and Webdesign
User avatar
John P
Registered User
Posts: 1237
Joined: Mon Jan 21, 2008 3:55 pm
Location: Netherlands
Name: John
Contact:

Re: Cron

Post by John P »

Found the problem, running cron.task.core.tidy_search it can not find class fulltext_native

Message: Fatal error: Class 'fulltext_native' not found in F:\InetPub\htdocs\phpbb31\phpbb\cron\task\core\tidy_search.php on line 62

phpBB version 3.1.0 RC3
files are in place
Image
Webhosting, Custom MODs, Technical management, MOD installation and Webdesign
nicofuma
3.2 Release Manager
3.2 Release Manager
Posts: 546
Joined: Sun Apr 13, 2014 1:47 am
Location: Grenoble - France

Re: Cron

Post by nicofuma »

what is the result of this command for you?
bin/phpbbcli.php config:get search_type
Member of phpBB Development-Team
No Support via PM
User avatar
John P
Registered User
Posts: 1237
Joined: Mon Jan 21, 2008 3:55 pm
Location: Netherlands
Name: John
Contact:

Re: Cron

Post by John P »

./bin/phpbbcli.php config:get search_type
Result: \phpbb\search\fulltext_native

Should be fulltext_native otherwise it wouldn't search for this class
Image
Webhosting, Custom MODs, Technical management, MOD installation and Webdesign
nicofuma
3.2 Release Manager
3.2 Release Manager
Posts: 546
Joined: Sun Apr 13, 2014 1:47 am
Location: Grenoble - France

Re: Cron

Post by nicofuma »

Okay, I see what is the problem => https://tracker.phpbb.com/browse/PHPBB3-12883
Thanks for helping to find the bug.
Member of phpBB Development-Team
No Support via PM
User avatar
John P
Registered User
Posts: 1237
Joined: Mon Jan 21, 2008 3:55 pm
Location: Netherlands
Name: John
Contact:

Re: Cron

Post by John P »

Working again, thanks for helping
Image
Webhosting, Custom MODs, Technical management, MOD installation and Webdesign
LavIgor
Registered User
Posts: 545
Joined: Mon Apr 28, 2014 1:47 pm

Re: Cron

Post by LavIgor »

nicofuma wrote:What is the result of the following commands?

Code: Select all

phpBB/bin/phpbbcli.php cron:list
phpBB/bin/phpbbcli.php config:get cron_lock
Is there a way to execute cron:list command without using CLI?
User avatar
John P
Registered User
Posts: 1237
Joined: Mon Jan 21, 2008 3:55 pm
Location: Netherlands
Name: John
Contact:

Re: Cron

Post by John P »

$tasks = $this->cron_manager->get_tasks();

Gives you an aray with the tasks, look at https://github.com/ForumHulp/cron_status
Image
Webhosting, Custom MODs, Technical management, MOD installation and Webdesign
Locked

Return to “[3.1.x] Support Forum”