PhpSwitcher nach Update fehler

  • Hallo,

    wollte mal PHPSwitcher updaten auf version 5.05 jetzt kommt da Unerwarteter Fehler und dieser Hinweis:

    SQLSTATE[42000]: Syntax error or access violation: 1091 Can't DROP 'version_confdir_path_prev'; check that column/key exists

    kann mir jemand bitte Helfen dieses Problem zu lösen.

    Vielen Dank

    Gruss BigBen

  • Hi,

    I don't have this plugin, but you just need to find version_confdir_path_prev in the source and where you found drop before this name you must insert the "if exists".

    You will found something like this:

    drop column `version_confdir_path_prev`

    modify to this:

    drop column if exists `version_confdir_path_prev`

    OS: Debian Buster

    i-MSCP: GIT 1.5.3-maintenance branch

  • Hi first of all thanks

    That does not work drop column if exists

    now I have this message

    Plugin::PhpSwitcher::enable: DBD::mysql::db do failed: Unknown column 'version_name' in 'field list' at /var/www/imscp/gui/plugins/PhpSwitcher/backend/ line 1505, <$fh> line 184

    and when I click on retery it comes

    SQLSTATE [42000]: Syntax error or access violation: 1091 Can't DROP 'version_confdir_path_prev'; check that column / key exists

  • Hello BigBen

    Do you have the latest i-mscp version installed?

    Are you able to install the version you already used before? Don't forget to make a backup before.

    For me it looks like the database (or rather the tables for the phpswitcher plugin) is inconsistency.

    Currently I don't use the plugin but have worked with it a while, so I can't exactly say what's the problem.

  • Which OS / mySQL / i-MSCP version do you use?

    Colud you check the version of the database?

    1. SELECT `value` FROM `imscp`.`config` where name='DATABASE_REVISION';

    OS: Debian Buster

    i-MSCP: GIT 1.5.3-maintenance branch

  • I checked this server tonight. The problem was caused by the /var/www/imscp/gui/plugins/PhpSwitcher/sql/*

    Maybe there was an sql error when BigBen updated the PhpSwitcher, but lot of sql executed before the error. So the next time when he tired the installation again then he has got another error because columns was droped already at the first update. We deleted the sql files until the actual error and retry the install again and again while this folder will be empty. After all sql executed the PhpSwitcher works again.

    So if you have similar error then check that sqls and you will found the error.

    OS: Debian Buster

    i-MSCP: GIT 1.5.3-maintenance branch

  • I have the same problem, tried to update from 4.0.3 to 5.0.5, "unerwarteter Fehler".
    Tried to update to 5.0.0, also doesnt work. Going back to 4.0.3 seemed to work after a second reload of the plugin.

    Another try to go from 4.0.3 to 5.0.0 gives out the following error, any idea how to fix it?

    1. Ein unerwarteter Fehler ist aufgetreten:
    2. Plugin::PhpSwitcher::update: Died at /var/www/imscp/gui/plugins/PhpSwitcher/backend/ line 1209.
  • Das wäre Zeile 1209 von Version 5.0.0?

    ok - da geht's um zwei apt-get Aufrufe:


    1. /usr/bin/apt-get --quiet update


    1. /usr/bin/apt-get -y --auto-remove --no-install-recommends --quiet install cowbuilder devscripts eatmydata equivs quilt

    schlägt fehl...

    Versuch, die mal manuell auszuführen...