Bravo List

Bravo List (http://www.bvlist.com/index.php)
-   BT.Manager (phpMyBitTorrent) (http://www.bvlist.com/forumdisplay.php?f=23)
-   -   [PMBT] Server Transfer Errors (http://www.bvlist.com/showthread.php?t=5582)

Giorgatzelos 3rd November 2010 01:48

[PMBT] Server Transfer Errors
 
After transfering my pmbt site to other server i have issues...

1. my torrents stop seeding...then go red and give error message:"failure cannot connect to database", but not all...it does it to all torrents but not at the same time...

some seed others not and when i refresh it some times gives me "here seems to be a problem with the database server, sorry for the inconvenience. We should be back shortly."

i entered the old database at the new phpmyadmin as latin1...

2. At admin.php i get that error at the bottom

Code:

Warning: exec() has been disabled for security reasons in /home/archect4/public_html/admin.php on line 325


Tracker Load: (0%)
Current Users: NA
Current Load: NA
Load 15 mins ago: --
Load 30 mins ago: --
Operating System:


3.In addition when someone gives password to login it goes to user.php not to index.php...

joeroberts 3rd November 2010 04:06

error 1 is caused By the PMBT not being able to connect to the database

This is caused By a few things

1. Data base over load
2. no connection to Data base (this is only a problem on external Data bases)

error 2

In admin.php remove lines 251 - 415
PHP Code:

OpenTable("load");
if (
strtoupper(substr(PHP_OS03)) == "WIN") {
if (
class_exists("COM")) {
    function 
mkprettytime2($s){
    
$t['week'] = '';
    
$t['month'] = '';
        foreach (array(
"60:sec","60:min","24:hour","1:day") as $x) {
            
$y explode(":"$x);
            if (
$y[0] > 1) {
                
$v $s $y[0];
                
$s floor($s $y[0]);
            }
            else
                
$v $s;
            
$t[$y[1]] = $v;
        }

        if (isset(
$t['week']) || $t['week'] > || $t['week'] == 0$wk " weeks";
        else 
$wk " week";
        if (
$t['day'] > || $t['day'] == 0$day " days";
        else 
$day " day";
        if (
$t['hour'] > || $t['hour'] == 0$hr " hrs";
        else 
$hr " hr";
        if (
$t['min'] > || $t['min'] == 0$min " mins";
        else 
$min " min";
        if (
$t['sec'] > || $t['sec'] == 0$sec " secs";
        else 
$sec " sec";

        if (
$t["month"])
            return 
"{$t['month']}$mth {$t['week']}$wk {$t['day']}$day ".sprintf("%d$hr %02d$min %02d$sec"$t["hour"], $t["min"], $t["sec"], $f["month"]);
        if (
$t["week"])
            return 
"{$t['week']}$wk {$t['day']}$day ".sprintf("%d$hr %02d$min %02d$sec"$t["hour"], $t["min"], $t["sec"], $f["month"]);
        if (
$t["day"])
            return 
"{$t['day']}$day ".sprintf("%d$hr %02d$min %02d$sec"$t["hour"], $t["min"], $t["sec"]);
        if (
$t["hour"])
            return 
sprintf("%d$hr %02d$min %02d$sec"$t["hour"], $t["min"], $t["sec"]);
        if (
$t["min"])
            return 
sprintf("%d$min %02d$sec"$t["min"], $t["sec"]);
        return 
$t["sec"].$sec;
    }
if(
version_compare('4.50.0'PHP_VERSION) == 1) {
    
$wmi = new COM("Winmgmts://");
    
$cpus $wmi->InstancesOf("Win32_Processor");
    
$os $wmi->InstancesOf("Win32_OperatingSystem");
    
$os $os->Next();
    
$os $os->Caption." - ".$os->CSDVersion." ".$os->Version;
    
$system $wmi->InstancesOf("Win32_ComputerSystem");
    
$system $system->Next();
    
$cpucount $system->NumberOfProcessors;
    
    
$ram $wmi->InstancesOf("Win32_LogicalMemoryConfiguration");
    
$ram $ram->Next();
    
$ramtotal $ram->TotalPhysicalMemory*1024;
    
    
$ram $wmi->InstancesOf("Win32_PerfRawData_PerfOS_Memory");
    
$ram $ram->Next();
    
$ramused $ramtotal-$ram->AvailableBytes;
    
$ramused mksize($ramused);
    
$ramtotal mksize($ramtotal);
    
    
$uptime $wmi->InstancesOf("Win32_PerfFormattedData_PerfOS_System");
    
$uptime $uptime->Next();
    
$uptime mkprettytime2($uptime->SystemUpTime);

    while (
$cpu $cpus->Next()) {
        
$cpus1[] = $cpu->LoadPercentage;
        
$totalusage += $cpu->LoadPercentage;
    }
    
    
$totalusage round($totalusage/$cpucount2);    
}else{    
$wmi = new COM("Winmgmts://");
    
$cpus $wmi->InstancesOf("Win32_Processor");
    
$os $wmi->InstancesOf("Win32_OperatingSystem");
                        foreach(
$os as $op) {
                        
$os $op->Caption." - ".$op->CSDVersion." - ".$op->Version ;
                    }
    
$system $wmi->InstancesOf("Win32_ComputerSystem");
    foreach(
$system as $systemin){
    
$cpucount $systemin->NumberOfProcessors;
    }    
    
$ram $wmi->InstancesOf("Win32_LogicalMemoryConfiguration");
    foreach(
$ram as $ramin){
    
$ramtotal $ramin->TotalPhysicalMemory*1024;
    }        
    
$ram $wmi->InstancesOf("Win32_PerfRawData_PerfOS_Memory");
    foreach(
$ram as $ramin){
    
$ramused $ramtotal-$ramin->AvailableBytes;
    }        
    
$ramused mksize($ramused);
    
$ramtotal mksize($ramtotal);
    
    
$uptime $wmi->InstancesOf("Win32_PerfFormattedData_PerfOS_System");
    foreach(
$uptime as $uptimein){
    
$uptime mkprettytime2($uptimein->SystemUpTime);
    }        
$i=0;
$totalusage='';
                    foreach(
$cpus as $cpu) {
        
$cpus1[] = $cpu->LoadPercentage;
        
$totalusage += $cpu->LoadPercentage;

                        
$i++;

                    }
    
    
$totalusage round($totalusage/$cpucount2);    
}
    echo 
"<p><b>OS:</b> $os<BR>";
    echo 
"<b>Number of CPUs:</b> $cpucount<BR>";
    for (
$i=0;$i<count($cpus1);$i++)
        echo 
"<b>CPU".(($i == 0)? '1' $i)." Usage:</b> $cpus1[$i]%<BR>";
    echo 
"<b>Total CPU Usage:</b> $totalusage%<BR>";
    echo 
"<B>RAM Usage:</b> $ramused/$ramtotal<BR>";
    echo 
"<b>Uptime:</b> $uptime</p>";
}
}else{
// Users and load information
$reguptime trim(exec("uptime"));
if (
$reguptime) {
  if (
preg_match("/, *(\d) (users?), .*: (.*), (.*), (.*)/"$reguptime$uptime)) {
    
$users[0] = $uptime[1];
    
$users[1] = $uptime[2];
    
$loadnow $uptime[3];
    
$load15 $uptime[4];
    
$load30 $uptime[5];
  }
} else {
  
$users[0] = "NA";
  
$users[1] = "--";
  
$loadnow "NA";
  
$load15 "--";
  
$load30 "--";
}

$percent min(100round(exec('ps ax | grep -c apache') / 256 30 ));
echo 
"<B>Tracker Load:</B> ($percent%)";

echo(
"<b>Current Users:</b> $users[0]");
echo(
"<b>Current Load:</b> $loadnow<b>Load 15 mins ago:</b> $load15<b>Load 30 mins ago:</b> $load30<hr>");

// Operating system
$fp = @fopen("/proc/version""r");
echo 
$fp;
if (
$fp) {
  
$temp = @fgets($fp);
  
fclose($fp);
echo 
$temp;
  if (
preg_match("/version (.*?) /"$temp$osarray)) {
    
$kernel $osarray[1];
    
preg_match("/[0-9]{5,} (\((.* *)\)\))/"$temp$osarray);
    
$flavour $osarray[2];
    
$operatingsystem $flavour." (".PHP_OS." ".$kernel.")";
    if (
preg_match("/SMP/"$buf)) {
      
$operatingsystem .= " (SMP)";
    }
  } else {
    
$result "(N/A)";
  }
} else {
  
$result "(N/A)";
}

echo(
"<b>Operating System:</b>$operatingsystem");
}
CloseTable(); 

error 3 user.php is where they go to conferm account user and pass and then they should be redirected back to the page in whitch they started.
now are they going to that page and it just stops?
this can be caused by having the phpBB3 forum set to active and not having it installed.

Giorgatzelos 4th November 2010 17:42

Dear Joe i did what you told me to and fixed one problem...
error 1 --->still exists.
error 2 --->fixed
error 3 --->yes it stops at user.php and it gives a pink frame with message:
PHP Code:

phpMyBitTorrent Error 

In addition when i try to enter to the forum it gives error:
PHP Code:

Fatal error:  require() [function.require]: Failed opening required '/home/archect4/public_html/phpBB3/config.php' (include_path='.:/usr/lib/php:/usr/local/lib/php'in /home/archect4/public_html/phpBB3/common.php on line 128 

...is it permissios error?or coding error?...i do not know...

daffy 4th November 2010 18:08

if you moev your site mate, you wil have to give permissions back to the correct files and folders, "that error you have is the cause of it"

Quote:

Originally Posted by pmbt setup

avatars/user = 777
cache = 777
imdb-images = 777
include/configdata.php = 777
UserFiles = 777
phpBB3/config.php = 777
phpBB3/cache = 777
phpBB3/files = 777
phpBB3/images/avatars/upload = 777
phpBB3/store = 777
torrent = 777 (assuming this is the directory you are using for torrents)



Giorgatzelos 4th November 2010 22:03

Quote:

Originally Posted by daffy (Post 25463)
if you moev your site mate, you wil have to give permissions back to the correct files and folders, "that error you have is the cause of it"


i did all these you said but i have one question though...when i upload my sql do i have to select sql compatibility or set it to NONE...and under what character set utf-8?

joeroberts 5th November 2010 02:02

Quote:

Originally Posted by Giorgatzelos (Post 25472)
i did all these you said but i have one question though...when i upload my sql do i have to select sql compatibility or set it to NONE...and under what character set utf-8?

as long as you did a complete data base back up all you have to do is drop in the back up and the backup well do the rest.

Giorgatzelos 5th November 2010 03:00

I setup tracker again...but after installing forum i've got this error message at the bottom...of the forum...

Code:

Fatal error:  Call to undefined method dbal_mysqli::sql_numrows() in /home/archect4/public_html/include/cleanup.php on line 58

joeroberts 5th November 2010 06:29

open phpBB3/includes/db/dball.php and find
PHP Code:

}

/**
* This variable holds the class name to use later
*/
$sql_db = (!empty($dbms)) ? 'dbal_' basename($dbms) : 'dbal';

?> 

and add before
PHP Code:

        function sql_numrows($query_id 0)
        {
                if(!
$query_id)
                {
                        
$query_id $this->query_result;
                }
                if(
$query_id)
                {
                        
$result = @mysql_num_rows($query_id);
                        return 
$result;
                }
                else
                {
                        return 
false;
                }
        } 



All times are GMT +2. The time now is 12:45.

Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2024, vBulletin Solutions Inc.