Menu

#4655 (ok 4.3.5) Undefined index: collation_connection

4.3.4
fixed
None
1
2015-01-05
2014-12-17
No

After selecting a database:

Notice in ./libraries/Header.class.php#227
Undefined index: collation_connection

Backtrace

./libraries/Header.class.php#257: PMA_Header->getJsParams()
./libraries/Header.class.php#208: PMA_Header->getJsParamsCode()
./libraries/Header.class.php#136: PMA_Header->_addDefaultScripts()
./libraries/Response.class.php#102: PMA_Header->construct()
./libraries/Response.class.php#131: PMA_Response->
construct()
./libraries/common.inc.php#1065: PMA_Response::getInstance()
./index.php#12: require_once(./libraries/common.inc.php)

Notice in ./index.php#212
Undefined variable: collation_connection

Backtrace

Also, I did tick "Automatically send report next time" but it's still asking me..

Discussion

1 2 > >> (Page 1 of 2)
  • Marc Delisle

    Marc Delisle - 2014-12-18

    Olaf,
    can you reproduce this at will? I cannot.

     
  • Olaf van der Spek

    It does happen every single time on one particular machine, making pMA totally unusable.
    Doesn't happen on another machine. Perhaps it's related to MySQL / PHP versions?
    5.5.40-0+wheezy1
    5.4.35-0+deb7u2

     
  • Marc Delisle

    Marc Delisle - 2014-12-18

    Well, this notice is output due to error displaying activated, either in php.ini or in phpMyAdmin configuration. Aside from the message, are there problems with phpMyAdmin usage on this machine.

     
  • Olaf van der Spek

    I don't think it's PHP displaying the error.

     
  • Olaf van der Spek

    pMA is totally unusable as I can't select a DB.

     
  • Marc Delisle

    Marc Delisle - 2014-12-24
    • assigned_to: Marc Delisle
     
  • Marc Delisle

    Marc Delisle - 2014-12-24

    Olaf,
    I believe that this happens on a machine that has no config.inc.php, can you confirm?

     
    • Olaf van der Spek

      No, a config file does exist:

      --- config.sample.inc.php 2014-12-21 12:41:09.000000000 +0100
      +++ config.inc.php 2014-12-13 14:37:14.809195388 +0100
      @@ -14,7 +14,7 @@
      * This is needed for cookie based authentication to encrypt password in
      * cookie
      /
      -$cfg['blowfish_secret'] = ''; /
      YOU MUST FILL IN THIS FOR COOKIE AUTH! /
      +$cfg['blowfish_secret'] = 'a8b7c6d'; /
      YOU MUST FILL IN THIS FOR COOKIE AUTH! */

      /
      * Servers configuration
      @@ -26,7 +26,7 @@
      /
      $i++;
      / Authentication type /
      -$cfg['Servers'][$i]['auth_type'] = 'cookie';
      +$cfg['Servers'][$i]['auth_type'] = 'http';
      / Server parameters /
      $cfg['Servers'][$i]['host'] = 'localhost';
      $cfg['Servers'][$i]['connect_type'] = 'tcp';

       

      Last edit: Olaf van der Spek 2014-12-26
  • Marc Delisle

    Marc Delisle - 2014-12-24

    Olaf,
    please try the attached patch (tested on 4.3.3).

     
  • Olaf van der Spek

    Would you like me to try the patch file or the bigger git patch?

     
  • Marc Delisle

    Marc Delisle - 2014-12-26

    In practice it's the same; the bigger one is bigger only because of the unit tests.

     
  • Marc Delisle

    Marc Delisle - 2014-12-29
    • summary: Undefined index: collation_connection --> (ok 4.3.4) Undefined index: collation_connection
    • status: open --> resolved
    • Priority: 5 --> 1
     
  • Marc Delisle

    Marc Delisle - 2014-12-29
    • Status: resolved --> fixed
     
  • Olaf van der Spek

    Still broken in 4.3.4:
    Notice in ./libraries/Header.class.php#227
    Undefined index: collation_connection

    Backtrace

    ./libraries/Header.class.php#257: PMA_Header->getJsParams()
    ./libraries/Header.class.php#208: PMA_Header->getJsParamsCode()
    ./libraries/Header.class.php#136: PMA_Header->_addDefaultScripts()
    ./libraries/Response.class.php#102: PMA_Header->construct()
    ./libraries/Response.class.php#131: PMA_Response->
    construct()
    ./libraries/common.inc.php#1064: PMA_Response::getInstance()
    ./index.php#12: require_once(./libraries/common.inc.php)

    Notice in ./index.php#212
    Undefined variable: collation_connection

    Backtrace

     
  • Marc Delisle

    Marc Delisle - 2014-12-30

    Olaf,
    please try this second patch.

     
  • aommundsen

    aommundsen - 2015-01-01

    I have the same errors after upgrading from 4.2.13.1 to 4.3.4, but it only happended on first log in after upgrade. Then it would not happen again until I cleared all cache and history in Firefox browser, then it happen again.

    But everything seems to work correctly. I temporary solved the problem by setting "SendErrorReports" in config.inc.php to value: never - after doing that it does not show those errors anymore.

    If it helps I am running PHP 5.6.4 as mod_php with mod_ruid2

     
  • Chris Hallgren

    Chris Hallgren - 2015-01-02

    I am getting this when I try to login. And I cannot login. I'm always presented with "Cannot log in to the MySQL server"

    Notice in ./libraries/Header.class.php#227
    Undefined index: collation_connection

    Backtrace

    ./libraries/Header.class.php#257: PMA_Header->getJsParams()
    ./libraries/Header.class.php#208: PMA_Header->getJsParamsCode()
    ./libraries/Header.class.php#136: PMA_Header->_addDefaultScripts()
    ./libraries/Response.class.php#102: PMA_Header->construct()
    ./libraries/Response.class.php#131: PMA_Response->
    construct()
    ./libraries/plugins/auth/AuthenticationCookie.class.php#67: PMA_Response::getInstance()
    ./libraries/plugins/auth/AuthenticationCookie.class.php#710: AuthenticationCookie->auth()
    ./libraries/DatabaseInterface.class.php#2446: AuthenticationCookie->authFails()
    ./libraries/common.inc.php#987: PMA_DatabaseInterface->connect(
    string *,
    string *
    ,
    boolean false,
    )
    ./index.php#12: require_once(./libraries/common.inc.php)

     
  • Marc Delisle

    Marc Delisle - 2015-01-02

    To aommundsen and Chris Hallgren: did you try my second patch (attached above) ?

     
  • aommundsen

    aommundsen - 2015-01-02

    @Marc, sorry I did not test you patch. But I have tested it now, and it works and completely solve the problem for me. No more errors with patch bug4655-b.patch. Thanks!

     
  • Olaf van der Spek

    Errors disappeared even before applying the patch but it's still not working.
    Whatever I click, I keep getting returned to the home screen.

     
    • Marc Delisle

      Marc Delisle - 2015-01-02

      Olaf,
      please clarify. You no longer see the notice about collation_connection on this particular machine?

       
  • aommundsen

    aommundsen - 2015-01-02

    @Olaf, please note that you will only see the error the first time you log in, then you will not see the error again until you clear cache in your web browser.

    For me the patch works perfectly, and I can recreate the bug if I remove the patch, then the errors come back, and i re-apply the patch, and the errors are gone. Also everything seems to work correct for me. So maybe Olaf has another completely different bug not relate to the reported error, that is my guess.

     
  • Olaf van der Spek

    @Marc
    No, I don't, don't know why. But the problem is still the same, I can't get past the home screen.

     
    • Marc Delisle

      Marc Delisle - 2015-01-02

      @Olaf did you try to clear your browser cache as suggested by aommundsen?

      Did you look at your web server's error log to find a clue there?

       
1 2 > >> (Page 1 of 2)