此后它就停止并冻结了。
The following packages will be upgraded:
libmysqlclient15off mysql-client mysql-client-5.0 mysql-common
4 packages upgraded, 4 newly installed, 0 to remove and 49 not upgraded.
Need to get 38.0MB of archives. After unpacking 91.1MB will be used.
Do you want to continue? [Y/n/?] y
Writing extended state information... Done
Get:1 http://archive.ubuntu.com jaunty-updates/main mysql-common 5.1.30really5.0 .75-0ubuntu10.2 [62.9kB]
Get:2 http://archive.ubuntu.com jaunty-updates/main mysql-client 5.1.30really5.0 .75-0ubuntu10.2 [55.0kB]
Get:3 http://archive.ubuntu.com jaunty-updates/main libmysqlclient15off 5.1.30re ally5.0.75-0ubuntu10.2 [1878kB]
Get:4 http://archive.ubuntu.com jaunty-updates/main mysql-client-5.0 5.1.30reall y5.0.75-0ubuntu10.2 [8292kB]
Get:5 http://archive.ubuntu.com jaunty-updates/main mysql-server-core-5.0 5.1.30 really5.0.75-0ubuntu10.2 [3534kB]
Get:6 http://archive.ubuntu.com jaunty-updates/main mysql-server-5.0 5.1.30reall y5.0.75-0ubuntu10.2 [24.0MB]
Get:7 http://archive.ubuntu.com jaunty/main libhtml-template-perl 2.9-1 [65.8kB]
Get:8 http://archive.ubuntu.com jaunty-updates/main mysql-server 5.1.30really5.0 .75-0ubuntu10.2 [57.2kB]
Fetched 38.0MB in 3s (10.8MB/s)
Preconfiguring packages ...
(Reading database ... 17211 files and directories currently installed.)
Preparing to replace mysql-common 5.1.30really5.0.75-0ubuntu10 (using .../mysql- common_5.1.30really5.0.75-0ubuntu10.2_all.deb) ...
Unpacking replacement mysql-common ...
Preparing to replace mysql-client 5.1.30really5.0.75-0ubuntu10 (using .../mysql- client_5.1.30really5.0.75-0ubuntu10.2_all.deb) ...
Unpacking replacement mysql-client ...
Preparing to replace libmysqlclient15off 5.1.30really5.0.75-0ubuntu10 (using ... /libmysqlclient15off_5.1.30really5.0.75-0ubuntu10.2_amd64.deb) ...
Unpacking replacement libmysqlclient15off ...
Preparing to replace mysql-client-5.0 5.1.30really5.0.75-0ubuntu10 (using .../my sql-client-5.0_5.1.30really5.0.75-0ubuntu10.2_amd64.deb) ...
Unpacking replacement mysql-client-5.0 ...
Selecting previously deselected package mysql-server-core-5.0.
Unpacking mysql-server-core-5.0 (from .../mysql-server-core-5.0_5.1.30really5.0. 75-0ubuntu10.2_amd64.deb) ...
Setting up mysql-common (5.1.30really5.0.75-0ubuntu10.2) ...
Selecting previously deselected package mysql-server-5.0.
(Reading database ... 17290 files and directories currently installed.)
Unpacking mysql-server-5.0 (from .../mysql-server-5.0_5.1.30really5.0.75-0ubuntu 10.2_amd64.deb) ...
* Stopping MySQL database server mysqld [ OK ]
Selecting previously deselected package libhtml-template-perl.
Unpacking libhtml-template-perl (from .../libhtml-template-perl_2.9-1_all.deb) . ..
Selecting previously deselected package mysql-server.
Unpacking mysql-server (from .../mysql-server_5.1.30really5.0.75-0ubuntu10.2_all .deb) ...
* Stopping MySQL database server mysqld [ OK ]
Setting up libmysqlclient15off (5.1.30really5.0.75-0ubuntu10.2) ...
Setting up mysql-client-5.0 (5.1.30really5.0.75-0ubuntu10.2) ...
Setting up mysql-client (5.1.30really5.0.75-0ubuntu10.2) ...
Setting up mysql-server-core-5.0 (5.1.30really5.0.75-0ubuntu10.2) ...
Setting up mysql-server-5.0 (5.1.30really5.0.75-0ubuntu10.2) ...
* Stopping MySQL database server mysqld [ OK ]
* /etc/init.d/mysql: WARNING: /etc/mysql/my.cnf cannot be read. See README.Debi an.gz
* Starting MySQL database server mysqld [fail]
invoke-rc.d: initscript mysql, action "start" failed.
dpkg: error processing mysql-server-5.0 (--configure):
subprocess post-installation script returned error exit status 1
Setting up libhtml-template-perl (2.9-1) ...
dpkg: dependency problems prevent configuration of mysql-server:
mysql-server depends on mysql-server-5.0; however:
Package mysql-server-5.0 is not configured yet.
dpkg: error processing mysql-server (--configure):
dependency problems - leaving unconfigured
Processing triggers for libc6 ...
No apport report written because the error message indicates its a followup erro r from a previous failure.
ldconfig deferred processing now taking place
Errors were encountered while processing:
mysql-server-5.0
mysql-server
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install. Trying to recover:
Setting up mysql-server-5.0 (5.1.30really5.0.75-0ubuntu10.2) ...
* Stopping MySQL database server mysqld [ OK ]
* /etc/init.d/mysql: WARNING: /etc/mysql/my.cnf cannot be read. See README.Debi an.gz
* Starting MySQL database server mysqld [ OK ]
/etc/init.d/mysql: line 115: /etc/mysql/debian-start: No such file or directory
invoke-rc.d: initscript mysql, action "start" failed.
答案1
因为上次删除软件包时,您只是删除了它们,而不是清除它们,然后您手动删除了配置文件。因此 dpkg 认为您不需要默认配置文件(因为您删除了它),所以它不会安装新的配置文件,MySQL 会发出警报。
清除所有与 mysql 相关的包并重试。
答案2
- 彻底删除包
- 清理
apt-get
。 - 删除系统上因安装不当而遗留的所有内容。
apt-get install libmysqlclient15off mysql-client mysql-client-5.0 mysql-common
答案3
检查 /etc/mysql/my.cnf 的权限,确保其可读。否则,如建议的那样,查看 README.Debian(可能位于 /usr/share/doc/mysql-server)。