November 25, 2015 in Technical Problems
I have a question about the Background Tasks that are done immediatlly after the upgrade from 3.x to 4.1.4. So I have added
/usr/bin/php -d memory_limit=-1 -d max_execution_time=0 /var/www/html/domain.com/main/applications/core/interface/task/task.php 893483489389489ahr88
and I see it run in cron but I see essentially 0 CPU utilization and 0 mysql usage in 'top'. In 12 hours its only done Updating Attachments storage URLs1.37%Deleting legacy topic data24.95126705653%Deleting legacy post data8.9390386869871%Updating Attachments storage URLs1.6%
And 0% for everything else. So the question I have is two fold. First is it possible to run in parallel, meaning is there someway I can kick off Rebuilding SignaturesRebuilding postsRebuilding topicsRebuilding announcementsetc...
At the same time or is it sequential that it requires the deleting legacy stuff first to complete before it can run the rest? I have 24threads/64gb available and as mentioned its doing essentially nothing.
The other question does this use a "$perCycle" like the upgrader does? I increased the "perCycle" on the upgrader and it went from 36hour upgrade to a 8hour upgrade time and was utilizing 1 CPU at 100% and Mysql at 50%.
Maybe someone who understands the code better then I do but is this doing essentially a "LIMIT" or what is the array(0 , 5) specifying? So can I increase that to say 0, 500 to select 500 rows at a time to loop through?
public function run( $data, $offset )
$select = \IPS\Db::i()->select( '*', 'forums_topics', 'approved > 1', 'tid ASC', array( 0, 5 ) );
if ( !count( $select ) )
throw new \OutOfRangeException;
$done = 0;
foreach( new \IPS\Patterns\ActiveRecordIterator( $select, 'IPS\forums\Topic' ) as $topic )
return $offset + $done;
This topic is now archived and is closed to further replies.
Started 9 hours ago
Started 5 hours ago
Started November 24