Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-3670

LP:484127 - Installing mariadb-server-5.1 fails when upgrading from mysql with different innodb_log_file_size and replacing /etc/mysql/my.cnf

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:

      Description

      I upgraded an Ubuntu 8.04 mysql-server-5.0 to mariadb-server-5.1 (5.1.39-ourdelta67). When asked, I choose to install the version of /etc/mysql/my.cnf from the new package, replacing my own.

      The install failed, since the old mysql config used a non-default value for innodb_log_file_size. InnoDB refuses to start when the size in .cnf is different than actual size of logs on disk.

      Now this situation is actually user error. I am not sure the package should try to be clever and automagically handle a non-default innodb_log_file_size. A user that changes this should be aware of the consequences. I feel uncomfortable with alternatives like trying to pick out the value from the old config and setting in the new one, or deleting the old innodb log files during install.

      However, I think we could still improve this situation for the user, by at least allowing the install to succeed, even if the server will then not be able to start until the .cnf is fixed. Currently, the mysqld --bootstrap commands needed to update system tables etc. fails, leaving a broken install that must be fixed with apt-get install --fix-broken or similar.

      I suggest to make this more robust by running the mysqld --bootstrap commands with innodb and pbxt disabled:

      MYSQL_BOOTSTRAP="/usr/sbin/mysqld --bootstrap --user=mysql --skip-grant-tables --innodb=OFF --pbxt=OFF --default-storage-engine=myisam"

      This should allow install to succeed. The user would not have to fix a broken package install (but still need to fix the my.cnf before being able to start the server, of course).

        Gliffy Diagrams

          Attachments

            Activity

            Hide
            arjenlentz Arjen Lentz added a comment -

            Re: [Bug 484127] [NEW] Installing mariadb-server-5.1 fails when upgrading from mysql with different innodb_log_file_size and replacing /etc/mysql/my.cnf
            Hi Kristian

            On 17/11/2009, at 8:47 PM, Kristian Nielsen wrote:
            > I suggest to make this more robust by running the mysqld --bootstrap
            > commands with innodb and pbxt disabled:
            >
            > MYSQL_BOOTSTRAP="/usr/sbin/mysqld -bootstrap --user=mysql --skip
            > grant-tables --innodb=OFF --pbxt=OFF --default-storage-engine=myisam"

            Sounds good.

            There's a feature request for XtraDB, to have XtraDB able to increase
            log file size.

            As part of my original feature request was to have XtraDB just use the
            actual log file size, rather than complain about the config setting.

            Cheers,
            Arjen.

            Arjen Lentz, Exec.Director @ Open Query (http://openquery.com)
            Exceptional Services for MySQL at a fixed budget.

            Follow our blog at http://openquery.com/blog/
            OurDelta: packages for MySQL and MariaDB @ http://ourdelta.org

            Show
            arjenlentz Arjen Lentz added a comment - Re: [Bug 484127] [NEW] Installing mariadb-server-5.1 fails when upgrading from mysql with different innodb_log_file_size and replacing /etc/mysql/my.cnf Hi Kristian On 17/11/2009, at 8:47 PM, Kristian Nielsen wrote: > I suggest to make this more robust by running the mysqld --bootstrap > commands with innodb and pbxt disabled: > > MYSQL_BOOTSTRAP="/usr/sbin/mysqld - bootstrap --user=mysql --skip > grant-tables --innodb=OFF --pbxt=OFF --default-storage-engine=myisam" Sounds good. There's a feature request for XtraDB, to have XtraDB able to increase log file size. As part of my original feature request was to have XtraDB just use the actual log file size, rather than complain about the config setting. Cheers, Arjen. – Arjen Lentz, Exec.Director @ Open Query ( http://openquery.com ) Exceptional Services for MySQL at a fixed budget. Follow our blog at http://openquery.com/blog/ OurDelta: packages for MySQL and MariaDB @ http://ourdelta.org
            Hide
            monty Michael Widenius added a comment -

            Re: Installing mariadb-server-5.1 fails when upgrading from mysql with different innodb_log_file_size and replacing /etc/mysql/my.cnf
            Agree with Kristian's proposal.

            Show
            monty Michael Widenius added a comment - Re: Installing mariadb-server-5.1 fails when upgrading from mysql with different innodb_log_file_size and replacing /etc/mysql/my.cnf Agree with Kristian's proposal.
            Hide
            hakanküçükyılmaz Hakan Küçükyılmaz added a comment -

            Re: Installing mariadb-server-5.1 fails when upgrading from mysql with different innodb_log_file_size and replacing /etc/mysql/my.cnf
            For 5.1 we should get a successful install, even if the configuration for InnoDB or other engines is broken.

            Show
            hakanküçükyılmaz Hakan Küçükyılmaz added a comment - Re: Installing mariadb-server-5.1 fails when upgrading from mysql with different innodb_log_file_size and replacing /etc/mysql/my.cnf For 5.1 we should get a successful install, even if the configuration for InnoDB or other engines is broken.
            Hide
            ratzpo Rasmus Johansson added a comment -

            Launchpad bug id: 484127

            Show
            ratzpo Rasmus Johansson added a comment - Launchpad bug id: 484127

              People

              • Assignee:
                knielsen Kristian Nielsen
                Reporter:
                knielsen Kristian Nielsen
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: