All pastes #896679 Raw Edit

Untitled

public text v1 · immutable
·published 2008-02-08 21:46 UTC
rendered paste body

$max = $maxdata[0];
$n = mysql_num_rows($qry);
$x = $max / 3000 + 1;
$first = 0;
for ($i = 1; $i <= $x; $i++) {
        if ($first == 0) {
                $start = $min;
                $first = 1;
        } else {
                $start = $start + 3000;
        }
        $end = $start + 3000 - 1;
        #echo "/usr/local/bin/php forked.php start=$start end=$end > /dev/null  
\n";
        exec("/usr/local/bin/php forked.php start=$start end=$end > /dev/null &"
);
}