vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Scheduled Task - Run Every 5 Seconds (https://vborg.vbsupport.ru/showthread.php?t=316060)

Paul M 12-17-2014 12:15 AM

Quote:

Originally Posted by Mko (Post 2527499)
so that Scheduled Tasks hopefully would execute even if nobody is viewing the Forum Index.

The default vb cron does not rely on someone viewing the forum index, it is part of the footer, so runs off any page.

ozzy47 12-17-2014 10:24 AM

This is true, unless of course it is a custom page, and you did not include the footer on it. :)

Easy5s.net 06-27-2015 07:03 AM

Please let me know, I've set up a cron to run every minute as above. If no one is accessing the site, the cron does not run?

kh99 06-27-2015 09:16 AM

Quote:

Originally Posted by Easy5s.net (Post 2548722)
Please let me know, I've set up a cron to run every minute as above. If no one is accessing the site, the cron does not run?

That's correct, it won't run if no one is accessing the site. There has been mention before of using an actual cron job to run the scheduled tasks. If you search here and at vbulletin.com you should find something about it. I can't remember the details but it might have been as easy as setting it up to run the cron.php script.

Easy5s.net 06-27-2015 12:10 PM

I have search more one 1h in vb.com but not find :(

TheLastSuperman 06-27-2015 05:27 PM

Quote:

Originally Posted by kh99 (Post 2548723)
That's correct, it won't run if no one is accessing the site. There has been mention before of using an actual cron job to run the scheduled tasks. If you search here and at vbulletin.com you should find something about it. I can't remember the details but it might have been as easy as setting it up to run the cron.php script.

Quote:

Originally Posted by Easy5s.net (Post 2548736)
I have search more one 1h in vb.com but not find :(

I believe Kevin (kh99) meant to convey that unless your site has actual traffic 24/7/365 the cron job may or may not always run every minute (or 5/10/15/etc/etc) FROM vBulletin IF no traffic is on the site. vBulletin runs cron jobs based on activity, so if no visitors are on your site the cron from vBulletin will not run every minute.... now if they login and stay 15mins or if they login then leave (session timeout will show them and keep cron going for at least 15-30mins based on your setting) the vB cron jobs will only run while the site thinks 1 or more people are actually online (members or guests).

Try as Kevin suggested and setup an actual cron in cpanel versus vBulletin, when you set it up to run from cpanel it will run every minute whether your site has someone on it or not UNLESS the server restarts or has an issue but generally should not.

https://documentation.cpanel.net/display/ALD/Cron+Jobs

Easy5s.net 06-28-2015 09:42 AM

Cron can run when google bot visit?

TheLastSuperman 06-28-2015 05:06 PM

Quote:

Originally Posted by Easy5s.net (Post 2548801)
Cron can run when google bot visit?

Yes! Despite only being a bot its still an "unregistered" user to the system whether it knew it was a bot or not it still knew someone/something is on the site so cron will run then.

There is no guarantee on it running from vBulletin cron unless activity is ALWAYS present on the site, this is why we mentioned running cron from cpanel.


All times are GMT. The time now is 05:51 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01037 seconds
  • Memory Usage 1,729KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete