gpt4 book ai didi

mysql - 系统[1] : Failed to start MySQL Community Server while installing mysql-server

转载 作者:行者123 更新时间:2023-12-04 04:16:42 35 4
gpt4 key购买 nike

当我尝试重新安装 mysql 时,出现以下错误:

sudo apt-get install mysql-server
Leyendo lista de paquetes... Hecho
Creando árbol de dependencias
Leyendo la información de estado... Hecho
mysql-server ya está en su versión más reciente (8.0.19-1debian10).
Los paquetes indicados a continuación se instalaron de forma automática y ya no son necesarios.
galera-3 libcgi-fast-perl libcgi-pm-perl libconfig-inifiles-perl
libdbd-mysql-perl libdbi-perl libfcgi-perl libhtml-template-perl
libreadline5 libterm-readkey-perl rsync socat
Utilice «sudo apt autoremove» para eliminarlos.
0 actualizados, 0 nuevos se instalarán, 0 para eliminar y 179 no actualizados.
2 no instalados del todo o eliminados.
Se utilizarán 0 B de espacio de disco adicional después de esta operación.
¿Desea continuar? [S/n] s
Configurando mysql-community-server (8.0.19-1debian10) ...
Failed to preset unit: File mysql.service: Link has been severed
/usr/bin/deb-systemd-helper: error: systemctl preset failed on mysql.service: No such file or directory
[mysql.conf:23] Line references path below legacy directory /var/run/, updating /var/run/mysqld → /run/mysqld; please update the tmpfiles.d/ drop-in file accordingly.
[mysql.conf:23] Line references path below legacy directory /var/run/, updating /var/run/mysqld → /run/mysqld; please update the tmpfiles.d/ drop-in file accordingly.
[mysql.conf:23] Line references path below legacy directory /var/run/, updating /var/run/mysqld → /run/mysqld; please update the tmpfiles.d/ drop-in file accordingly.
Failed to get unit file state for mysql.service: Link has been severed
mysql.service is a disabled or a static unit, not starting it.
Job for mysql.service failed because the control process exited with error code.
See "systemctl status mysql.service" and "journalctl -xe" for details.
invoke-rc.d: initscript mysql, action "start" failed.
● mysql.service - MySQL Community Server
Loaded: loaded (/lib/systemd/system/mysql.service; bad; vendor preset: enabled)
Active: failed (Result: exit-code) since Tue 2020-03-10 12:00:58 -03; 15ms ago
Docs: man:mysqld(8)
http://dev.mysql.com/doc/refman/en/using-systemd.html
Process: 7906 ExecStartPre=/usr/share/mysql-8.0/mysql-systemd-start pre (code=exited, status=0/SUCCESS)
Process: 7941 ExecStart=/usr/sbin/mysqld (code=exited, status=1/FAILURE)
Main PID: 7941 (code=exited, status=1/FAILURE)
Status: "Data Dictionary upgrade from MySQL 5.7 in progress"

mar 10 12:00:56 azeroth systemd[1]: Starting MySQL Community Server...
mar 10 12:00:58 azeroth systemd[1]: mysql.service: Main process exited, code=exited, status=1/FAILURE
mar 10 12:00:58 azeroth systemd[1]: mysql.service: Failed with result 'exit-code'.
mar 10 12:00:58 azeroth systemd[1]: Failed to start MySQL Community Server.
dpkg: error al procesar el paquete mysql-community-server (--configure):
el subproceso instalado paquete mysql-community-server script post-installation devolvió el código de salida de error 1
dpkg: problemas de dependencias impiden la configuración de mysql-server:
mysql-server depende de mysql-community-server (= 8.0.19-1debian10); sin embargo:
El paquete `mysql-community-server' no está configurado todavía.

dpkg: error al procesar el paquete mysql-server (--configure):
problemas de dependencias - se deja sin configurar
Se encontraron errores al procesar:
mysql-community-server
mysql-server
E: Sub-process /usr/bin/dpkg returned an error code (1)

我只知道它与 smysql-community 有关,除此之外别无其他。我已经尝试过此处列出的所有内容:https://askubuntu.com/questions/1008298/cant-start-mysql-server-database-corruption但没有任何效果。

还有:journalctl -xe 给出:

-- Support: https://www.debian.org/support
--
-- A start job for unit mysql.service has begun execution.
--
-- The job identifier is 2279.
mar 10 17:39:49 azeroth systemd[1]: mysql.service: Main process exited, code=exited, status=1/FAILURE
-- Subject: Unit process exited
-- Defined-By: systemd
-- Support: https://www.debian.org/support
--
-- An ExecStart= process belonging to unit mysql.service has exited.
--
-- The process' exit code is 'exited' and its exit status is 1.
mar 10 17:39:49 azeroth systemd[1]: mysql.service: Failed with result 'exit-code'.
-- Subject: Unit failed
-- Defined-By: systemd
-- Support: https://www.debian.org/support
--
-- The unit mysql.service has entered the 'failed' state with result 'exit-code'.
mar 10 17:39:49 azeroth systemd[1]: Failed to start MySQL Community Server.
-- Subject: A start job for unit mysql.service has failed
-- Defined-By: systemd
-- Support: https://www.debian.org/support
--
-- A start job for unit mysql.service has finished with a failure.
--
-- The job identifier is 2279 and the job result is failed.
mar 10 17:39:49 azeroth sudo[2743]: pam_unix(sudo:session): session closed for user root
mar 10 17:41:51 azeroth sudo[2805]: jenifer : TTY=pts/0 ; PWD=/home/jenifer ; USER=root ; COMMAND=/usr/bin/journalctl -xe
mar 10 17:41:51 azeroth sudo[2805]: pam_unix(sudo:session): session opened for user root by (uid=0)

我已经尝试删除 mysql-server 并使用 apt-get 重新安装它,但它给出了同样的错误。如果有人可以帮助我,我将不胜感激。

最佳答案

你可以解决这部分:

[mysql.conf:23] Line references path below legacy directory /var/run/, updating /var/run/mysqld → /run/mysqld; please update the tmpfiles.d/ drop-in file accordingly.
[mysql.conf:23] Line references path below legacy directory /var/run/, updating /var/run/mysqld → /run/mysqld; please update the tmpfiles.d/ drop-in file accordingly.
[mysql.conf:23] Line references path below legacy directory /var/run/, updating /var/run/mysqld → /run/mysqld; please update the tmpfiles.d/ drop-in file accordingly.

通过编辑mysql.conf文件并替换

/var/run/mysqld

/run/mysqld

关于mysql - 系统[1] : Failed to start MySQL Community Server while installing mysql-server,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/60620443/

35 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com