OTRS5 Database Check Script Error After Upgrade

Moderator: crythias

Locked
mrhaag
Znuny newbie
Posts: 18
Joined: 17 Jun 2011, 14:27
Znuny Version: 4.0.12
Real Name: Michael R. Haag
Company: Madison County, NY
Location: Madison County, NY

OTRS5 Database Check Script Error After Upgrade

Post by mrhaag »

I tried to upgrade using the RPM file on CentOS from version 4 to 5. I receive an error from the database check script during upgrade:

When I check my OTRS database I find I do have the table "scheduler_task", but the script does not find it.

(This text is copied from a German forum thread viewtopic.php?t=29995 about what seems to be the same issue because I do not have the text of the error on my own system. I am not using the beta as they are.)



:~/bin$ perl otrs.Console.pl Maint::Database::Check
Trying to connect to database 'DBI:mysql:database=otrs;host=localhost;' with user 'otrs'...
[Thu Aug 20 15:49:15 2015] otrs.Console.pl: DBD::mysql::st execute failed: Table 'otrs.scheduler_task' doesn't exist at /opt/otrs-5.0.0.beta2/Kernel/System/DB.pm line 666.
ERROR: OTRS-otrs.Console.pl-Maint::Database::Check-10 Perl: 5.18.2 OS: linux Time: Thu Aug 20 15:49:15 2015

Message: Table 'otrs.scheduler_task' doesn't exist, SQL: 'SELECT * FROM scheduler_task LIMIT 1'

Traceback (6672):
Module: Kernel::System::Console::Command::Maint::Database::Check::Run Line: 52
Module: (eval) Line: 441
Module: Kernel::System::Console::BaseCommand::Execute Line: 435
Module: Kernel::System::Console::InterfaceConsole::Run Line: 86
Module: otrs.Console.pl Line: 38

Error: Connection was successful, but table scheduler_task is missing.
OTRS 5.0.14 on CentOS release 6.7 (Final) with mysql Ver 15.1 Distrib 5.5.47-MariaDB database connected to an Active Directory for Agents and Customers.
mrhaag
Znuny newbie
Posts: 18
Joined: 17 Jun 2011, 14:27
Znuny Version: 4.0.12
Real Name: Michael R. Haag
Company: Madison County, NY
Location: Madison County, NY

Re: OTRS5 Database Check Script Error After Upgrade

Post by mrhaag »

Answering my own question: I use a separate database server. The database import step in the upgrade documentation:

http://otrs.github.io/doc/manual/admin/ ... ading.html

shell> cd /opt/otrs/
shell> cat scripts/DBUpdate-to-5.mysql.sql | mysql -p -f -u root otrs
shell> bin/otrs.Console.pl Maint::Database::Check

That script targets the database on the server on which the RPM is installed. I believe my error is due to the fact that I am not logged into my separate database server, importing the script into that server's OTRS database (which is the one I am connecting to via my setting in /opt/otrs/Kernel/Config.pm).

Perhaps the documentation would be better if it warned users employing a separate DB server at step 6.1.

I am sure the upgrade will complete without error after I fix the problem in my upgrade process. I will post again if any further problems occur.
OTRS 5.0.14 on CentOS release 6.7 (Final) with mysql Ver 15.1 Distrib 5.5.47-MariaDB database connected to an Active Directory for Agents and Customers.
Locked