Update Error 1.1.20 -> 1.2.4 / Database update 207

  • I updated my Server from Wheezy -> Jessy and did a reboot.
    Deleted all Plugins in the database and on the file system, too. Stopped the i-MSCP services and started the setup.
    During the i-MSCP 1.2.4 upgrade from 1.1.20 i get this error here:


    Code
    1. [ERROR] main::setupUpdateDatabase: [ERROR] Database update 207 failed: SQLSTATE[42000]: Syntax error or access violation: 1091 Can't DROP 'traff_time'; check that column/key exists
    2. autoinstaller::Functions::install: An error occurred while performing installation steps

    So i did one i-MSCP upgrade after one 1.1.20 -> 1.2.0 -> 1.2.1 -> 1.2.2 (all are fine)
    In >=1.2.3 i-MSCP i get the "Database update 207 failed" message.

    Checked my database, there is an entry under the server_traffic table.
    Same if i use i-MSCP 1.2.4. and reconfigure everything.

    OS Debian 8.1
    i-MSCP Version 1.1.20 / 1.2.2
    Apache FPM
    Dovecot
    MySQL

  • Hello ;


    You did surely something wrong. the traff_time key which is dropped and re-added as UNIQUE key by database update 207 is here since years...


    See https://github.com/i-MSCP/imsc…atabase/database.sql#L561


    To fix your problem try the following:


    1. Execute the following queries manually

    SQL
    1. # mysql -u root -p<password>
    2. > use imscp;
    3. > ALTER TABLE server_traffic ADD KEY traff_time (traff_time)
    4. > quit;


    Once done, rerun the installer.


    BTW: This is useless to update as you did ( 1.1.20 -> 1.2.0 -> 1.2.1 -> 1.2.2)...

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • Re;


    I've added a fix to avoid to remove inexistent index (just in case). See https://github.com/i-MSCP/imsc…0042d88125f2c99700f4bc41b

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • Fixed in version 1.2.5

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206