create file cv.php with content:
PHP Code:
<?php
error_reporting(E_ALL & ~E_NOTICE);
define('THIS_SCRIPT', 'cv');
define('CSRF_PROTECTION', false);
require_once('./global.php');
function change_table_engine($engine_from, $engine_to, $show_output = false, $test_mode = false)
{
global $vbulletin;
$engine_from_lc = strtolower($engine_from);
$engine_to_lc = strtolower($engine_to);
$tables = $vbulletin->db->query_read("SHOW TABLE STATUS");
while($temp = $vbulletin->db->fetch_array($tables))
{
if(strtolower($temp['Engine']) == $engine_from_lc AND $engine_from_lc != $engine_to_lc AND !in_array(strtolower($temp['Engine']), array('heap', 'memory')))
{
if($show_output)
{
print "Alter Engine of table: $temp[Name] - $temp[Engine] to $engine_to<br />\n";
vbflush();
}
if(!$test_mode)
{
$vbulletin->db->query_write("ALTER TABLE " . TABLE_PREFIX . "{$temp[Name]} ENGINE = $engine_to");
}
}
}
}
change_table_engine('MyISAM', 'InnoDB', true);
?>
change args in the line
PHP Code:
change_table_engine('MyISAM', 'InnoDB', true);
1 arg = convert FROM
2 arg = convert TO
3 arg = show or no output (optional, default = false)
4 arg = test mode. if set to
true - no changes in DB (optional, default = false)
close forum
make Data Base backup
upload file to forum root and execute in browser
confirm chages in DB
delete file
open forum