Jump to content
Dmitry

Installation failed to create the core tables

Recommended Posts

Hello World!

I'm trying to follow Installation of Revive Adserver, yet running into following error:

Installation failed to create the core tables

./var/debug.log:

Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_account_preference_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table account_preference_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_account_user_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table account_user_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_account_user_permission_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table account_user_permission_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_accounts
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table accounts
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_acls
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table acls
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_acls_channel
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table acls_channel
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_ad_category_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table ad_category_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_ad_zone_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table ad_zone_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_affiliates
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table affiliates
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_affiliates_extra
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table affiliates_extra
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_agency
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table agency
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_application_variable
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table application_variable
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_audit
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table audit
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_banners
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table banners
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_campaigns
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table campaigns
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_campaigns_trackers
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table campaigns_trackers
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_category
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table category
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_channel
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table channel
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_clients
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table clients
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_intermediate_ad
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_intermediate_ad
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_intermediate_ad_connection
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_intermediate_ad_connection
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_intermediate_ad_variable_value
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_intermediate_ad_variable_value
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_raw_ad_click
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_raw_ad_click
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_raw_ad_impression
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_raw_ad_impression
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_raw_ad_request
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_raw_ad_request
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_raw_tracker_impression
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_raw_tracker_impression
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_raw_tracker_variable_value
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_raw_tracker_variable_value
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_summary_ad_hourly
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_summary_ad_hourly
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_summary_ad_zone_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_summary_ad_zone_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_summary_channel_daily
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_summary_channel_daily
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_data_summary_zone_impression_history
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table data_summary_zone_impression_history
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_images
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table images
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_log_maintenance_forecasting
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table log_maintenance_forecasting
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_log_maintenance_priority
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table log_maintenance_priority
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_log_maintenance_statistics
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table log_maintenance_statistics
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_password_recovery
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table password_recovery
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_placement_zone_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table placement_zone_assoc
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_preferences
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table preferences
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_session
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table session
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_targetstats
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table targetstats
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_tracker_append
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table tracker_append
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_trackers
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table trackers
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_userlog
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table userlog
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_users
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table users
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_variable_publisher
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table variable_publisher
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_variables
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table variables
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop table rv_zones
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to drop the table zones
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  Unable to create the table application_variable
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [    error]  _doQuery: [Error message: Could not execute statement]
[Last executed query: CREATE TABLE `rv_application_variable` (`name` VARCHAR(255) DEFAULT '' NOT NULL, `value` TEXT NOT NULL, PRIMARY KEY (name)) ENGINE = MYISAM]
[Native code: 1071]
[Native message: Specified key was too long; max key length is 1000 bytes]
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [  warning]  count(): Parameter must be an array or an object that implements Countable
Jun 11 16:50:43 +0000 OX-5cffdbe30efaf [  warning]  count(): Parameter must be an array or an object that implements Countable

I also tried to follow https://github.com/revive-adserver/revive-adserver/issues/740#issuecomment-407480288 , without any luck(

Please advise.

Thank you in advance.

Edited by Dmitry

Share this post


Link to post
Share on other sites
20 hours ago, andrewatfornax said:

The issue is that the user you are using to connect to the database with does not have all of the required permissions to create the database and tables...

See your database documentation for details on how to do that!

may I ask what made you think that? and/or which database  documentation are you referring too? I followed https://www.revive-adserver.com/support/installation/ (part 3)

# mysql -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 100
Server version: 8.0.13 Source distribution

Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> CREATE USER 'revive_adserver'@'localhost' IDENTIFIED BY 'XXX';
Query OK, 0 rows affected (0.06 sec)

mysql> GRANT ALL ON revive_adserver_3.* TO 'revive_adserver'@'localhost';
Query OK, 0 rows affected (0.03 sec)

mysql> USE mysql;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> SELECT * FROM user WHERE User='revive_adserver'\G;
*************************** 1. row ***************************
                    Host: localhost
                    User: revive_adserver
             Select_priv: N
             Insert_priv: N
             Update_priv: N
             Delete_priv: N
             Create_priv: N
               Drop_priv: N
             Reload_priv: N
           Shutdown_priv: N
            Process_priv: N
               File_priv: N
              Grant_priv: N
         References_priv: N
              Index_priv: N
              Alter_priv: N
            Show_db_priv: N
              Super_priv: N
   Create_tmp_table_priv: N
        Lock_tables_priv: N
            Execute_priv: N
         Repl_slave_priv: N
        Repl_client_priv: N
        Create_view_priv: N
          Show_view_priv: N
     Create_routine_priv: N
      Alter_routine_priv: N
        Create_user_priv: N
              Event_priv: N
            Trigger_priv: N
  Create_tablespace_priv: N
                ssl_type:
              ssl_cipher:
             x509_issuer:
            x509_subject:
           max_questions: 0
             max_updates: 0
         max_connections: 0
    max_user_connections: 0
                  plugin: mysql_native_password
   authentication_string: XXX
        password_expired: N
   password_last_changed: 2019-06-17 17:21:40
       password_lifetime: NULL
          account_locked: N
        Create_role_priv: N
          Drop_role_priv: N
  Password_reuse_history: NULL
     Password_reuse_time: NULL
Password_require_current: NULL
1 row in set (0.00 sec)

ERROR:
No query specified

mysql> SELECT * FROM db WHERE User='revive_adserver'\G;
*************************** 1. row ***************************
                 Host: localhost
                   Db: revive_adserver_3
                 User: revive_adserver
          Select_priv: Y
          Insert_priv: Y
          Update_priv: Y
          Delete_priv: Y
          Create_priv: Y
            Drop_priv: Y
           Grant_priv: N
      References_priv: Y
           Index_priv: Y
           Alter_priv: Y
Create_tmp_table_priv: Y
     Lock_tables_priv: Y
     Create_view_priv: Y
       Show_view_priv: Y
  Create_routine_priv: Y
   Alter_routine_priv: Y
         Execute_priv: Y
           Event_priv: Y
         Trigger_priv: Y
1 row in set (0.00 sec)

ERROR:
No query specified

mysql> CREATE DATABASE revive_adserver_3;
Query OK, 1 row affected (0.02 sec)

mysql> ^DBye
#

even though following message appears:

Installation failed to create the core tables

database IS created along with few tables:

# mysql -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 103
Server version: 8.0.13 Source distribution

Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> USE revive_adserver_3;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> SHOW TABLES;
+-----------------------------+
| Tables_in_revive_adserver_3 |
+-----------------------------+
| rv_database_action          |
| rv_upgrade_action           |
+-----------------------------+
2 rows in set (0.00 sec)

mysql> ^DBye
#

 

Edited by Dmitry

Share this post


Link to post
Share on other sites

Hi @Dmitry,

Ah, all the messages about unable to do things made me think that the most common cause of this is that the user that you're connecting as doesn't have sufficient permissions. It would be worth trying with the root database account, just to be sure.

Potentially, it's treating the connection as not from "localhost" for example.

Otherwise, it might be an issue with strict mode being enabled in the database?

Share this post


Link to post
Share on other sites
On 6/29/2019 at 5:56 AM, andrewatfornax said:

Hi @Dmitry,

Ah, all the messages about unable to do things made me think that the most common cause of this is that the user that you're connecting as doesn't have sufficient permissions. It would be worth trying with the root database account, just to be sure.

Potentially, it's treating the connection as not from "localhost" for example.

Otherwise, it might be an issue with strict mode being enabled in the database?

As I stated in my earlier posts, user has sufficient privileges for specific database, I also did try with root with same results(

regards to strict mode: I'm using mysql database out of the box (w/ default values):

mysql> SHOW VARIABLES LIKE 'sql_mode'\G;
*************************** 1. row ***************************
Variable_name: sql_mode
        Value: ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION
1 row in set (0.00 sec)

ERROR:
No query specified

mysql>

I also tried to remove "STRICT_TRANS_TABLES", yet still no luck(

Edited by Dmitry

Share this post


Link to post
Share on other sites

I also tried to remove all modes from sql_mode, still same thing... in fact it kind of made it even worse... as database wouldn't get created, but even if I create database manually, I end up with same 2 tables as before and "Installation failed to create the core tables " message on screen...

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.




×
×
  • Create New...