If you are running on vservers, the Vbulletin 2.0.1 installation can be tricky. I followed these steps to get mine to work:
1. load all files and folders to your server
2. make sure you change the info in your config.php file
3. edit the install.php file in the admin folder - change the value for $onvservers=0 to $onvservers=1
4. make further changes to the install.php script with these lines from Chris Frolic:
function doqueries () {
global $DB_site,$query,$explain,$onvservers;
while (list($key,$val)=each($query)) {
echo "<p>$explain[$key]</p>\n";
echo "<!-- ".htmlspecialchars($val)." -->\n\n";
flush();
if ($onvservers==1 and substr($val, 0, 5)=="ALTER") {
$DB_site->reporterror=0;
}
// closing the database
@mysql_close();
// here's the delay
$timewaster=0;
while ($timewaster<500000) {
$timewaster=$timewaster+1;
}
// opening the database
$DB_site->connect();
$DB_site->query($val);
if ($onvservers==1 and substr($val, 0, 5)=="ALTER") {
$DB_site->link_id=0;
// closing the database
@mysql_close();
// another delay
$timewaster=0;
while ($timewaster<500000) {
$timewaster=$timewaster+1;
}
// opening the database
$DB_site->connect();
$DB_site->reporterror=1;
}
}
unset ($query);
unset ($explain);
}
5. follow these directions from joe masters:
1) Go into admin/install.php, and comment out any SQL line with "ALTER" in it (there are two: $query[]= "ALTER
TABLE access... and $query[]="ALTER TABLE searchindex... ) by putting // in front of the line. and put a // in front
of the $explain[] line below both of those, too. (otherwise the script will be confused.
2) After step 4 completes (the long list of creating tables), *DON'T* go onto the next step until you log into mysql
(type mysql [dbname] at the shell) and run the two alter lines:
ALTER TABLE access ADD UNIQUE (userid,forumid);
ALTER TABLE searchindex ADD UNIQUE (wordid,postid);
Both commands will give you errors after you run them --Don't worry about this -- it's the reason why vbulletin
can't do it automatically. But it will actually work.
3) Now continue with the rest of the installation script.
6. edit the functions.php script in the admin folder:
change lines 209, 210, 211 (add the //) change to read:
// if ($connection_status ()){
// exit;
// }
this worked for me, hope it can help save someone some aggrevation.
1. load all files and folders to your server
2. make sure you change the info in your config.php file
3. edit the install.php file in the admin folder - change the value for $onvservers=0 to $onvservers=1
4. make further changes to the install.php script with these lines from Chris Frolic:
function doqueries () {
global $DB_site,$query,$explain,$onvservers;
while (list($key,$val)=each($query)) {
echo "<p>$explain[$key]</p>\n";
echo "<!-- ".htmlspecialchars($val)." -->\n\n";
flush();
if ($onvservers==1 and substr($val, 0, 5)=="ALTER") {
$DB_site->reporterror=0;
}
// closing the database
@mysql_close();
// here's the delay
$timewaster=0;
while ($timewaster<500000) {
$timewaster=$timewaster+1;
}
// opening the database
$DB_site->connect();
$DB_site->query($val);
if ($onvservers==1 and substr($val, 0, 5)=="ALTER") {
$DB_site->link_id=0;
// closing the database
@mysql_close();
// another delay
$timewaster=0;
while ($timewaster<500000) {
$timewaster=$timewaster+1;
}
// opening the database
$DB_site->connect();
$DB_site->reporterror=1;
}
}
unset ($query);
unset ($explain);
}
5. follow these directions from joe masters:
1) Go into admin/install.php, and comment out any SQL line with "ALTER" in it (there are two: $query[]= "ALTER
TABLE access... and $query[]="ALTER TABLE searchindex... ) by putting // in front of the line. and put a // in front
of the $explain[] line below both of those, too. (otherwise the script will be confused.
2) After step 4 completes (the long list of creating tables), *DON'T* go onto the next step until you log into mysql
(type mysql [dbname] at the shell) and run the two alter lines:
ALTER TABLE access ADD UNIQUE (userid,forumid);
ALTER TABLE searchindex ADD UNIQUE (wordid,postid);
Both commands will give you errors after you run them --Don't worry about this -- it's the reason why vbulletin
can't do it automatically. But it will actually work.
3) Now continue with the rest of the installation script.
6. edit the functions.php script in the admin folder:
change lines 209, 210, 211 (add the //) change to read:
// if ($connection_status ()){
// exit;
// }
this worked for me, hope it can help save someone some aggrevation.
Comment