• Hi, Pleskians! We are running a UX testing of our upcoming product intended for server management and monitoring.
    We would like to invite you to have a call with us and have some fun checking our prototype. The agenda is pretty simple - we bring new design and some scenarios that you need to walk through and succeed. We will be watching and taking insights for further development of the design.
    If you would like to participate, please use this link to book a meeting. We will sent the link to the clickable prototype at the meeting.
  • (Plesk for Windows):
    MySQL Connector/ODBC 3.51, 5.1, and 5.3 are no longer shipped with Plesk because they have reached end of life. MariaDB Connector/ODBC 64-bit 3.2.4 is now used instead.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.

Issue Mysql 5.7.23 upgrade problem

Lorenzo Ansaloni

New Pleskian
I have a problem upgrading mysql-server-5.7 (5.7.23-0ubuntu0.16.04.1), Plesk version is 17.8.11 Update #15, this is the content of file "parallels-installation-log.txt:

Code:
[2018-08-01 13:46:24.492251] Installation started in background
[2018-08-01 13:46:24.492343]
Getting bootstrapper packages to installation list:
[2018-08-01 13:46:24.492415] Following bootstrapper packages will be installed: (empty)
[2018-08-01 13:46:24.492453] ----------------
[2018-08-01 13:46:24.492477] Getting packages to installation list:
[2018-08-01 13:46:24.492520] Following packages will be installed: dummy_obsoleter_ext-docker-0.0
[2018-08-01 13:46:24.492562] ----------------
[2018-08-01 13:46:24.492640] Checking whether the package dependencies are resolved.
[2018-08-01 13:46:24.492688] autoinstaller: read output of DEBIAN_FRONTEND=noninteractive LANG=C apt-get --assume-yes --show-upgraded --purge --no-reinstall -o APT::Get::List-Cleanup=true -o Dpkg::options::=--force-confdef -o Dpkg::options::=--force-confold -o APT::Get::AllowUnauthenticated=false -o Acquire::Retries=3 -t 'xenial*' --just-print install
[2018-08-01 13:46:25.509966] add to install list mysql-server-5.7-5.7.23-0ubuntu0.16.04.1
[2018-08-01 13:46:25.510052] add to install list mysql-server-5.7.23-0ubuntu0.16.04.1
[2018-08-01 13:46:25.536434] Check package set before installation
[2018-08-01 13:46:25.536983] The following packages from not selected components will be installed because they are required by other components' packages you selected for installation:
[2018-08-01 13:46:25.550358] Installing packages
[2018-08-01 13:46:28.799347] Bootstrapper has finished action (exec time: 0 sec.): parent_name='PLESK_17_8_11', sequence='prep', stage='execute', sequence_order='-1', operation='install', exec_cmd='touch /tmp/pp-bootstrapper-mode.flag; touch /var/lock/parallels-panel-maintenance-mode.flag; rm -f /var/lock/parallels-panel-upgrade-failure.flag; :'', m_arch='', output: ~empty
[2018-08-01 13:46:28.808844] Reading package lists...
Building dependency tree...
Reading state information...
mysql-server is already the newest version (5.7.23-0ubuntu0.16.04.1).
mysql-server-5.7 is already the newest version (5.7.23-0ubuntu0.16.04.1).
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up mysql-server-5.7 (5.7.23-0ubuntu0.16.04.1) ...
update-alternatives: warning: forcing reinstallation of alternative /etc/mysql/mysql.cnf because link group my.cnf is broken
update-alternatives: warning: not replacing /etc/mysql/my.cnf with a link
Checking if update is needed.
Checking server version.
Running queries to upgrade MySQL server.
mysql_upgrade: [ERROR] 3193: Cannot complete the operation because table is referenced by another connection.
mysql_upgrade failed with exit status 5
dpkg: error processing package mysql-server-5.7 (--configure):
 subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of mysql-server:
 mysql-server depends on mysql-server-5.7; however:
 Package mysql-server-5.7 is not configured yet.

dpkg: error processing package mysql-server (--configure):
 dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
Errors were encountered while processing:
 mysql-server-5.7
 mysql-server
E: Sub-process /usr/bin/dpkg returned an error code (1)
Bootstrapper has finished action (exec time: 7 sec.): parent_name='PLESK_17_8_11', sequence='pkgs', stage='rollback', sequence_order='1', operation='install', exec_cmd='rm -f /tmp/pp-bootstrapper-mode.flag; rm -f /var/lock/parallels-panel-maintenance-mode.flag; touch /var/lock/parallels-panel-upgrade-failure.flag; /etc/init.d/psa restart; :'', m_arch='', output: ~empty
[2018-08-01 13:47:39.474456] Execute command /opt/psa/admin/bin/send-error-report install --version 17.8.11
[2018-08-01 13:47:39.475435] Warning: Failed to attach to cgroup /sys/fs/cgroup/systemd/user/root/tasks, installer might be unexpectedly killed later by the system
[2018-08-01 13:47:39.477333] Error: An error occurred on attempt to install packages.
Attention! Your software might be inoperable.
Please contact product technical support.

I try resolve the issue via command line:

Code:
# apt -f install
Lettura elenco dei pacchetti... Fatto
Generazione albero delle dipendenze
Lettura informazioni sullo stato... Fatto
0 aggiornati, 0 installati, 0 da rimuovere e 2 non aggiornati.
2 non completamente installati o rimossi.
Dopo quest'operazione, verranno occupati 0 B di spazio su disco.
Configurazione di mysql-server-5.7 (5.7.23-0ubuntu0.16.04.1)...
update-alternatives: attenzione: viene forzata l'installazione dell'alternativa /etc/mysql/mysql.cnf poiché il gruppo my.cnf è danneggiato
update-alternatives: attenzione: /etc/mysql/my.cnf non viene sostituito con un collegamento
Checking if update is needed.
This installation of MySQL is already upgraded to 5.7.23, use --force if you still need to run mysql_upgrade
/var/lib/dpkg/info/mysql-server-5.7.postinst: riga 16:  2786 Ucciso                  mysqld --user=mysql --init-file="$1" --socket="$tmpdir/mysqld.sock" --pid-file="$tmpdir/mysqld.pid" > /dev/null 2>&1
dpkg: errore nell'elaborare il pacchetto mysql-server-5.7 (--configure):
 il sottoprocesso installato script di post-installation ha restituito lo stato di errore 137
dpkg: problemi con le dipendenze impediscono la configurazione di mysql-server:
 mysql-server dipende da mysql-server-5.7; comunque:
  Il pacchetto mysql-server-5.7 non è ancora configurato.

dpkg: errore nell'elaborare il pacchetto mysql-server (--configure):
 problemi con le dipendenze - lasciato non configurato
Segnalazione apport non scritta poiché il messaggio di errore indica la presenza di un fallimento precedente.
                                                                                                             Si sono verificati degli errori nell'elaborazione:
 mysql-server-5.7
 mysql-server
N: Viene ignorato il file "plesk.list.ai_back" nella directory "/etc/apt/sources.list.d/" poiché ha un'estensione non valida
E: Sub-process /usr/bin/dpkg returned an error code (1)

During the upgrade process if I make a ps:
Code:
root@xxxx:~# ps afx | grep mysql
 1495 pts/3    Ss+    0:00  |           \_ /usr/bin/dpkg --status-fd 70 --configure mysql-server-5.7:amd64 mysql-server:all
 1505 pts/3    S+     0:00  |               \_ /usr/bin/perl -w /usr/share/debconf/frontend /var/lib/dpkg/info/mysql-server-5.7.postinst configure 5.7.22-0ubuntu0.16.04.1
 1521 pts/3    S+     0:00  |                   \_ /bin/bash /var/lib/dpkg/info/mysql-server-5.7.postinst configure 5.7.22-0ubuntu0.16.04.1
 2786 pts/3    Sl+    0:01  |                       \_ mysqld --user=mysql --init-file=/var/lib/mysql-files/tmp.tR5lOb5b1F --socket=/tmp/tmp.np5dYcIhd0/mysqld.sock --pid-file=/tmp/tmp.np5dYcIhd0
 
The content of file /var/lib/mysql-files/tmp.tR5lOb5b1F is:
Code:
USE mysql;
ALTER USER 'root'@'localhost' IDENTIFIED WITH 'auth_socket';
UPDATE user SET password_expired='N', account_locked='N' WHERE user='root';
FLUSH PRIVILEGES;
SHUTDOWN;

but if I watch into DB mysql ther is no usera named "root", maybe this is the problem?
 
Just an idea .... is there a mix of mariadb and mysql? I read somewhere else, the table structures are different starting from mysql 5.7
 
I have no mariadb installed on the system:
Code:
# dpkg -l | grep maria
ii  plesk-libmariadbclient-1.0          1.0.0-ubuntu.16.04.171006.1040             amd64        Mariadb client library.
ii  sw-mariadb-client                   1.0.0-ubuntu16.04.17031416                 amd64        Mariadb client library

and the mysqld version was already the 5.7:

Code:
# mysqld --version
mysqld  Ver 5.7.23-0ubuntu0.16.04.1 for Linux on x86_64 ((Ubuntu))
 
@Lorenzo Ansaloni

Check if you have

1 - /etc/alternatives/my.cnf (a symlink to /etc/mysql/mysql.cnf): if it does not exist, create one,
2 - /etc/mysql/my.cnf.fallback: if it does not exist, just copy my.cnf to my.cnf.fallback

and also check how the fallback config file is written: no underscores, just a point! (read: not my.cnf_fallback or similar).

Afterwards, you can retry to upgrade the MySQL server.

Note that the above is essentially a work-around to some of the known bugs in Ubuntu MySQL packages.

However, I am not sure what exactly is causing your issue, so I am not able to do more than to give you two small work-arounds.

Hope the above helps a bit.......kind regards and keep us posted!
 
Back
Top