簡體   English   中英

MySQL無法在Ubuntu 11.04上安裝

[英]MySQL Won't Install on Ubuntu 11.04

它之前工作正常,我在重新啟動mysql時配置了電子郵件服務器(通過/etc/init.d/mysql restart)。 我很確定我沒有觸及那里的任何東西,但我記得在此之前做了一次失敗的apt-get更新。

現在我的問題突然停止,甚至不會開始。 我在谷歌搜索,甚至遠遠地清除了所有內容並進行了新的安裝。 但它仍然不會讓我正確安裝mysql。

我已經嘗試過(刪除后 - 清除):

sudo apt-get install mysql-server-5.5 mysql-client-5.5

它會提示我輸入root密碼,但會返回以下錯誤:

Unable to set password for the MySQL "root" user                                                      

  An error occurred while setting the password for the MySQL administrative user. This may have         
  happened because the account already has a password, or because of a communication problem with the   
  MySQL server.                                                                                         

  You should check the account's password after the package installation.                               

  Please read the /usr/share/doc/mysql-server-5.5/README.Debian file for more information. 

我也有以下日志:

Selecting previously deselected package mysql-server-5.5.
(Reading database ... 117879 files and directories currently installed.)
Unpacking mysql-server-5.5 (from .../mysql-server-5.5_5.5.32-0ubuntu0.12.04.1_amd64.deb) ...
Processing triggers for man-db ...
Processing triggers for ureadahead ...
Setting up mysql-server-5.5 (5.5.32-0ubuntu0.12.04.1) ...
130830 14:13:26 [ERROR] Can't find messagefile '/usr/share/mysql/errmsg.sys'
start: Job failed to start
invoke-rc.d: initscript mysql, action "start" failed.
dpkg: error processing mysql-server-5.5 (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 mysql-server-5.5
E: Sub-process /usr/bin/dpkg returned an error code (1)

任何幫助? 提前致謝。

這個問題是通過卸載解決了同樣的問題,但在此之前他試圖設置密碼是問題 ,然后他試圖在聊天中解決它,也許當你嘗試設置密碼時它會被解決,只是試試

更新:在終端中鍵入以下命令,以便完全刪除mysql。

sudo apt-get remove --purge mysql-server mysql-client mysql-common
sudo apt-get autoremove
sudo apt-get autoclean

如果存在,您還需要通過鍵入以下命令來刪除/ var / lib / mysql文件夾

sudo rm -rf /var/lib/mysql

然后按照官方的ubuntu文檔進行安裝。 並且不要忘記在安裝過程中設置mysql密碼。

另請參閱此問題,它類似於您在安裝過程中遇到的錯誤。

我遇到了這個問題。 也許aptitude有一些配置包。 我覺得這個干擾問題雖然,這種方法是清除命令。 試試跑步。

  1. 檢查安裝的mysql包

    dpkg --get-selections | grep mysql

  2. 去掉

    apt-get remove --purge [安裝包]
    apt-get autoremove
    apt-get autoclean
    aptitude purge [已安裝包]
    能力清潔
    能力更新
    aptitude -f install
    aptitude全面升級

  3. 安裝

    apt-get install mysql-server

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM