Hello everyone,
i have an issue, the website worked excellent few months, but today I got an error on MYSQ:

Fatal error: Uncaught mysqli_sql_exception: No such file or directory in /www/server/phpmyadmin/phpmyadmin_a195f0ba8f73bbab/libraries/classes/Dbi/DbiMysqli.php:125 Stack trace: #0 /www/server/phpmyadmin/phpmyadmin_a195f0ba8f73bbab/libraries/classes/Dbi/DbiMysqli.php(125): mysqli->real_connect() #1 /www/server/phpmyadmin/phpmyadmin_a195f0ba8f73bbab/libraries/classes/DatabaseInterface.php(2631): PhpMyAdmin\Dbi\DbiMysqli->connect() #2 /www/server/phpmyadmin/phpmyadmin_a195f0ba8f73bbab/libraries/common.inc.php(380): PhpMyAdmin\DatabaseInterface->connect() #3 /www/server/phpmyadmin/phpmyadmin_a195f0ba8f73bbab/index.php(23): require_once('...') #4 {main} thrown in /www/server/phpmyadmin/phpmyadmin_a195f0ba8f73bbab/libraries/classes/Dbi/DbiMysqli.php on line 125

  • aaPanel_Kern replied to this.
  • decen
    There are no mysql-bin.000037 mysql-bin.000036 mysql-bin.000035 files in this directory.
    Try to remove the file mysql-bin.index and restart mysql
    mv /www/server/data/mysql-bin.index /tmp/mysql-bin.index
    /etc/init.d/mysqld restart

    decen
    Hi, what is your phpmyadmin version? What PHP version does phpmyadmin choose?

      decen
      Hello, is it OK to choose 8.0-7.4 for the php version of phpmyadmin?
      8.1 does not support phpmyadmin5.0

        aaPanel_Kern

        Thanks for the advice, I'll install PHP 8.0 and try to switch.
        If this will helps, I'll message you later.

        aaPanel_Kern

        That seems to help, Phpmyadmin works, but MySQL can't start, here is the screen

        also i got error thru phpmyadmin: Cannot log in to the MySQL server

          decen
          Execute the command to see what errors are displayed in the mysql log
          cat /www/server/data/*.err|grep -i -C 10 error

            decen
            Hi, have you done anything? Or did the server lose power? Prompt mysql-bin.000037 file does not exist
            Try to delete ./mysql-bin.000037 from the content of this /www/server/data/mysql-bin.index file, and then restart mysql. Can it be solved?
            It can be operated in the "File" interface of the panel
            cp /www/server/data/mysql-bin.index /www/server/data/mysql-bin.index
            /etc/init.d/mysqld restart

              aaPanel_Kern

              Deleted mysql-bin.000037 from the /www/server/data/mysql-bin.index file.
              Restarted MySQL. Didn't help

              As I understand server can't connect to MySQL,

                decen
                look again
                Execute the command to see what errors are displayed in the mysql log
                cat /www/server/data/*.err|grep -i -C 10 error

                  aaPanel_Kern

                  Yesterday upgraded apt-get upgrade:

                  Start-Date: 2022-08-02 18:02:27
                  Commandline: apt-get upgrade
                  Requested-By: ubuntu (1000)
                  Upgrade: update-notifier-common:amd64 (3.192.30.10, 3.192.30.11), apt:amd64 (2.0.8, 2.0.9), libkmod2:amd64 (27-1ubuntu2, 27-1ubuntu2.1), snapd:amd64 (2.54.3+20.04.1ubuntu0.3, 2.55.5+20.04), ubuntu-advantage-tools:amd64 (27.820.04.1, 27.920.04.1), isc-dhcp-common:amd64 (4.4.1-2.1ubuntu5.20.04.2, 4.4.1-2.1ubuntu5.20.04.3), libapt-pkg6.0:amd64 (2.0.8, 2.0.9), kmod:amd64 (27-1ubuntu2, 27-1ubuntu2.1), ec2-hibinit-agent:amd64 (1.0.0-0ubuntu9.1, 1.0.0-0ubuntu9.2), libkeyutils1:amd64 (1.6-6ubuntu1, 1.6-6ubuntu1.1), apt-utils:amd64 (2.0.8, 2.0.9), unattended-upgrades:amd64 (2.3ubuntu0.1, 2.3ubuntu0.3), isc-dhcp-client:amd64 (4.4.1-2.1ubuntu5.20.04.2, 4.4.1-2.1ubuntu5.20.04.3)
                  End-Date: 2022-08-02 18:03:08

                  Maybe after that MySQL stoped working

                    decen
                    Check out what mysql-bin files are in your directory, and can you tell me what you have done before?
                    ls /www/server/data/mysql-bin*

                      decen

                      Execute the command check out what mysql-bin files are in your directory
                      ls /www/server/data/mysql-bin*