After migration (setup/installer) - Database update 114 & 122 failed

  • Hey there,
    the migration script works now, but after starting the imscp-installer, I get following error:


    ISPCP: 1.0.7
    i-MSCP: 1.1.14
    Debian Wheezy x64
    dovecot, fpm


    Think there's a bug with the updater script?


    Thanks

  • Update:
    I've added an protected column to the domain_dns table

    Code
    1. mysql -u root -p -e 'ALTER TABLE domain_dns ADD protected VARCHAR(255)' ispcp


    But now I get following error:

    Code
    1. main::setupUpdateDatabase: [ERROR] Database update 122 failed: SQLSTATE[42S22]:
    2. Column not found: 1054 Unknown column 'subdomain_url_forward' in 'subdomain'
    3. autoinstaller::Functions::install: An error occured while performing
    4. installation steps
    5. iMSCP::Debug::END: Exit code: 1


    Is there a general problem with the db updater?

  • Update 2:
    Added subdomain_url_forward column to the subdomain table and subdomain_alias_url_forward to the subdomain_alias table. Works now :)


    Code
    1. mysql -u root -p -e 'ALTER TABLE subdomain ADD subdomain_url_forward VARCHAR(255) DEFAULT "no" AFTER subdomain_mount' ispcp


    Code
    1. mysql -u root -p -e 'ALTER TABLE subdomain_alias ADD subdomain_alias_url_forward VARCHAR(255) DEFAULT "no" AFTER subdomain_alias_mount' ispcp
  • Hello ;


    I'll check all this.

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

  • @Ninos


    I don't know how you migrated exactly but:


    I've looked at the ispCP 1.0.7 database schema and all columns you mention are present.


    Regarding i-MSCP database updates:


    Columns usage

    • The database update 114 uses the domain_dns.protected column but do not modify it
    • The database update 122 uses the subdomain.subdomain_url_forward column but do not modify it
    • The database update 122 uses the subdomain_alias.subdomain_alias_url_forward column but do not modify it


    Columns change/deletion

    • The column domain_dns.protected is only renamed at database update 151 (protected to owned_by)
    • The column subdomain.subdomain_url_forward is never removed by i-MSCP
    • The column subdomain_alias.subdomain_alias_url_forward is never renamed by i-MSCP


    The only thing that can explain your problem is that you didn't update from ispCP 1.0.7 (at least, the db schema was not updated from the one provided by i-MSCP 1.0.7)
    I'll do a fresh install of ispCP 1.0.7, run the migration script and then run the i-MSCP setup script to confirm but I'm pretty sure already.

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

  • Thanks for your check. It was the 1.0.7, here the output of the backuped ispcp.conf

    Code
    1. BuildDate = 20100819
    2. Version = 1.0.7 OMEGA
    3. CodeName = Priamos


    May something went wrong with the update from an older ispcp version to the 1.0.7. (So it's not a problem due imscp :D)

  • @Ninos


    Surely, what was the ispCP version from which you updated to ispCP 1.0.7 ? Having the Version 1.0.7 in the ispcp.conf file doesn't mean that the schema is updated correctly ;)

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

  • It was a customer server. So I don't know, what happend before. It's possible, that they skipped at least one step :D

  • @Ninos


    I'll do the migration test to be sure but... I hate lose time for such a thing (even if I know that the migration script was poorly written) ;


    Anyway, thank for your help.

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

  • I'm sry. If I would know, that they skipped one step I woudn't create this thread :/