簡體   English   中英

MySQL安裝問題

[英]Mysql installation issue

我遇到此問題,我卸載了MYSQL服務器,但無法將其重新安裝。 我已經嘗試了所有方法,但是似乎沒有用。 任何人都可以幫助我。 我嘗試了以下方法:我嘗試了所有這些,想知道空間可能是問題嗎? sudo apt-get清除mysql服務器mysql客戶端mysql公用mysql服務器核心5.5 mysql客戶端核心5.5

 sudo apt-get autoremove

 sudo apt-get autoclean  


ubuntu@ip-172-31-0-5:~$ sudo service mysql start
mysql: unrecognized service
ubuntu@ip-172-31-0-5:~$ sudo apt-get install mysql-server
Reading package lists... Done
Building dependency tree       
Reading state information... Done
mysql-server is already the newest version.
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
mysql-server : Depends: mysql-server-5.5 but it is not going to be  installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
ubuntu@ip-172-31-0-5:~$ mysql -u root -p
Enter password: 
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
ubuntu@ip-172-31-0-5:~$ 
ubuntu@ip-172-31-0-5:~$ sudo service mysql start
mysql: unrecognized service
ubuntu@ip-172-31-0-5:~$ 
ubuntu@ip-172-31-0-5:~$ sudo apt-get -f install
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following extra packages will be installed:
mysql-server-5.5
Suggested packages:
tinyca mailx
The following NEW packages will be installed:
mysql-server-5.5
0 upgraded, 1 newly installed, 0 to remove and 11 not upgraded.
8 not fully installed or removed.
Need to get 0 B/1845 kB of archives.
After this operation, 32.7 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LC_TIME = "en_GB.UTF-8",
LC_MONETARY = "en_GB.UTF-8",
LC_ADDRESS = "en_GB.UTF-8",
LC_TELEPHONE = "en_GB.UTF-8",
LC_NAME = "en_GB.UTF-8",
LC_MEASUREMENT = "en_GB.UTF-8",
LC_IDENTIFICATION = "en_GB.UTF-8",
LC_NUMERIC = "en_GB.UTF-8",
LC_PAPER = "en_GB.UTF-8",
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
locale: Cannot set LC_ALL to default locale: No such file or directory
Preconfiguring packages ...
/usr/bin/locale: Cannot set LC_ALL to default locale: No such file or directory
(Reading database ... 201373 files and directories currently installed.)
Preparing to unpack .../mysql-server- 5.5_5.5.49-0ubuntu0.14.04.1_amd64.deb ...
locale: Cannot set LC_ALL to default locale: No such file or directory
/usr/bin/locale: Cannot set LC_ALL to default locale: No such file or directory
egrep: /etc/mysql/: No such file or directory
ERROR: There's not enough space in /var/lib/mysql/
dpkg: error processing archive /var/cache/apt/archives/mysql-server-5.5_5.5.49-0ubuntu0.14.04.1_amd64.deb (--unpack):
subprocess new pre-installation script returned error exit status 1
locale: Cannot set LC_ALL to default locale: No such file or directory
Errors were encountered while processing:
/var/cache/apt/archives/mysql-server-5.5_5.5.49-0ubuntu0.14.04.1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
ubuntu@ip-172-31-0-5:~$ mysql -u root -p
Enter password: 
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
ubuntu@ip-172-31-0-5:~$ 

看起來您的MySQL磁盤空間可能用完了。 當您運行apt-get -f install ,它包含以下錯誤:

ERROR: There's not enough space in /var/lib/mysql/

您將需要釋放一些空間,以便apt-get可以正確安裝MySQL。 釋放空間后,重新運行apt-get -f install ,希望MySQL能夠正常運行。

暫無
暫無

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

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