Thread "Error while updating database"

Tabs

  • Deleted
    Deleted | 16. Mar 2018, 08:26
    Edited on: 16. Mar 2018, 08:40 - by Deleted
    Error while updating database
    Hi,

    I'm trying to upgrade from 5.0.0 to 5.3.2 with a fresh installation (5.3.2).

    I created the DB (mysql  Ver 15.1 Distrib 10.1.26-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2) and importet the data from the old installation (5.0.0).

    In ilias 5.3.2 I try to create a new client by using the copy of the old database.
    This leads to the upgrade database wizard.

    And now trouble begins...
    The update runs fine except for update 4870 (or 4953 - this is shown when I restart the wizard with the same database).
    This update always results in an error.

    PDOException (42000)
    SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; max key length is 767 bytes

    Any help would be great. Thanks a lot. Best regards, Richard.

    Environment & details:
    GET Datacmdgateway
    POST Datadb_typeMySQL 5.5.x or higher (InnoDB engine)db_version10.1.26-MariaDB-0+deb9u1db_host127.0.0.1db_nameiliasdb_userrootdb_port
    curv4870filev5250update_break5000cmdArray ( [updateDatabase] => Update Database )
    Filesempty
    CookiesilClientIdILIASMySQLSESSID1f5851291e537567f8db2a663669c5ea
    Sessionlang
    ClientIdILIAS01mysqlpost_varsArray ( [cmd] => Array ( [db] => Next ) ) referer/setup/setup.php?cmd=dbreferer_ref_id0auth1auth_pathhttp://learnitneuaccess_modeadmindisplay_modesetupdb_typeinnodb
    Server/Request DataHTTP_HOSTlearnitneuHTTP_USER_AGENTMozilla/5.0 (Windows NT 10.0; Win64; x64; rv:57.0) Gecko/20100101 Firefox/57.0HTTP_ACCEPTtext/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8HTTP_ACCEPT_LANGUAGEde,en-US;q=0.7,en;q=0.3HTTP_ACCEPT_ENCODINGgzip, deflateHTTP_REFERERhttp://learnitneu/setup/setup.php?cmd=gatewayCONTENT_TYPEapplication/x-www-form-urlencodedCONTENT_LENGTH220HTTP_COOKIEilClientId=ILIASMySQL; SESSID=1f5851291e537567f8db2a663669c5eaHTTP_CONNECTIONkeep-aliveHTTP_UPGRADE_INSECURE_REQUESTS1PATH/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/binSERVER_SIGNATURE<address>Apache/2.4.25 (Debian) Server at learnitneu Port 80</address> SERVER_SOFTWAREApache/2.4.25 (Debian)SERVER_NAMElearnitneuSERVER_ADDR10.127.102.58SERVER_PORT80REMOTE_ADDR10.64.106.51DOCUMENT_ROOT/var/www/vhosts/learnit/ilias/activeREQUEST_SCHEMEhttpCONTEXT_PREFIX
    CONTEXT_DOCUMENT_ROOT/var/www/vhosts/learnit/ilias/activeSERVER_ADMINwebmaster@localhostSCRIPT_FILENAME/var/www/vhosts/learnit/ilias/active/setup/setup.phpREMOTE_PORT57045GATEWAY_INTERFACECGI/1.1SERVER_PROTOCOLHTTP/1.1REQUEST_METHODPOSTQUERY_STRINGcmd=gatewayREQUEST_URI/setup/setup.php?cmd=gatewaySCRIPT_NAME/setup/setup.phpPHP_SELF/setup/setup.phpREQUEST_TIME_FLOAT1521183829.39REQUEST_TIME1521183829
    Environment Variablesempty
    Registered Handlers
    0. ilDelegatingHandler
    1. Whoops\Handler\CallbackHandler
  • Deleted
    Deleted | 17. Oct 2019, 08:00
    Re: Error while updating database
    Did you ever found a solution? I have the same problem here.
  • Deleted
    Deleted | 2. Apr 2020, 09:33
    1071 Specified key was too long
    I have same problem too :(
    it seems because of index limit of innodb engin, but database installation with MyISAM stops at same point as innodb

    [error] 26584#26584: *10 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught PDOException: SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; max key length is 767 bytes in /var/www/html/lms/Services/Database/classes/PDO/Manager/class.ilDBPdoManager.php:156

    Stack trace:

    #0 /var/www/html/lms/Services/Database/classes/PDO/Manager/class.ilDBPdoManager.php(156): PDO->exec('ALTER TABLE `ba...')

    #1 /var/www/html/lms/Services/Database/classes/PDO/class.ilDBPdo.php(378): ilDBPdoManager->createConstraint('`badge_image_te...', '`PRIMARY_idx`', Array)

    #2 /var/www/html/lms/setup/sql/ilDBTemplate.php(1663): ilDBPdo->addPrimaryKey('badge_image_tem...', Array)

    #3 /var/www/html/lms/setup/classes/class.ilDbSetup.php(261): setupILIASDatabase()

    #4 /var/www/html/lms/setup/classes/class.ilSetup.php(243): ilDbSetup->installDatabase()

    #5 /var/www/html/lms/setup/classes/class.ilSetupGUI.php(2664): ilSetup->installDatabase()

    #6 /var/www/html/lms/setup/classes/class.ilSetupGUI.php(440): ilSetupGUI->installDatabase()

    #7 /var/www/html/l" while reading response header from upstream, client: 192.168.1.6, server: lms.e2ee.ir, request: "POST /setup/setup.php?cmd=gateway HTTP/1.1", upstream: "fastcgi://unix:/var/run/php/php7.2-fpm.sock:", host: "192.168.1.69", referrer: "http://192.168.1.69/setup/setup.php?cmd=db&client_id=Bonyanian&back=clientlist"



  • wolfganghuebsch
    wolfganghuebsch | wolfganghuebsch (Moderation) | 5. Apr 2020, 22:43
    Re: 1071 Specified key was too long
    What is your OS, Server and PHP version?
  • Deleted
    Deleted | 11. Oct 2021, 09:37
    Re
    I have the same Problem updateing from 5.4 to 7.x
    is there any solution to this ?
  • Deleted
    Deleted | 11. Oct 2021, 13:50
    Re: Re
    resolved
  • ILIAS_LM
    ILIAS_LM | ILIAS_LM (Moderation) | 12. Oct 2021, 09:12
    Re (2): Re
    Would you mind giving a hint for others in need?
  • utesche
    utesche | utesche | 12. Oct 2021, 09:17
    Re: Re (2): Re
    ... I think the solution is mentioned by this post:  https://docu.ilias.de/goto_docu_frm_1875_7843.html