1

I'm trying to install mysql-server package, but I have this error message:

/home/nikitasorokin# apt-get install mysql-server
Reading package lists... Done
Building dependency tree       
Reading state information... Done
mysql-server is already the newest version.
The following packages were automatically installed and are no longer required:
  libaio1 ndn-mysql5-helper
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 5 not upgraded.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up mysql-server-5.5 (5.5.46-0ubuntu0.12.04.2) ...151108 11:54:25 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead.
151108 11:54:25 [Note] /usr/sbin/mysqld (mysqld 5.5.46-0ubuntu0.12.04.2) starting as process 14876 ...
start: Job failed to start
invoke-rc.d: initscript mysql, action "start" failed.
dpkg: error processing package mysql-server-5.5 (--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.5; however:
  Package mysql-server-5.5 is not configured yet.

dpkg: error processing package mysql-server (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 mysql-server-5.5
 mysql-server
E: Sub-process /usr/bin/dpkg returned an error code (1)

Apt-cache

/home/nikitasorokin# apt-cache policy mysql-server-5.5
mysql-server-5.5:
  Installed: 5.5.46-0ubuntu0.12.04.2
  Candidate: 5.5.46-0ubuntu0.12.04.2
  Version table:
 *** 5.5.46-0ubuntu0.12.04.2 0
        500 http://mirror.newdream.net/ubuntu/ precise-updates/main amd64 Packages
        500 http://mirror.newdream.net/ubuntu/ precise-security/main amd64 Packages
        100 /var/lib/dpkg/status
 5.5.22-0ubuntu1 0
        500 http://mirror.newdream.net/ubuntu/ precise/main amd64 Packages

Thanks in advance!

  • [Edit] your question and add the output of apt-cache policy mysql-server-5.5 – A.B. Nov 08 '15 at 21:30
  • Try running 'mysqld' from command line and check staking and /var/log/mysql/... files for any error messages – Thomas Ward Nov 08 '15 at 22:34
  • root@ps481138:/home/nikitasorokin# mysqld 151108 16:09:50 [Warning] Using unique option prefix key_buffer instead of key_buffer_size is deprecated and will be removed in a future release. Please use the full name instead. 151108 16:09:50 [Note] mysqld (mysqld 5.5.46-0ubuntu0.12.04.2) starting as process 6750 ... and then nothing... – Nikita Sorokine Nov 09 '15 at 00:10

2 Answers2

0

Here's a step by step procedure to install mysql in Ubuntu 12.04. The repository is given in question by OP. Here's how to add that repository

sudo add-apt-repository 'deb http://ppa.launchpad.net/ondrej/mysql-5.6/ubuntu precise main'

The question is marked solved so I assume It's a successful solution.

7_R3X
  • 1,151
  • 1
  • 16
  • 31
  • Unfortunately this solution doesn't work for me. I have persisted error, which I've marked before – Nikita Sorokine Nov 08 '15 at 20:17
  • @7_R3X Don't link other questions as your answer, click flag under the question and flag it as a duplicate, so it goes to the review queue. – Mark Kirby Nov 08 '15 at 20:35
  • At my opinion it is not a dublicate: my problem is quite different – Nikita Sorokine Nov 08 '15 at 20:36
  • @NikitaSorokine I am not saying it is, just saying this answer is just copied from another one on the site and that is discourage, just because one user flags a question does not mean it is a duplicate, five users with enough rep must all agree. Anyway I am making an answer – Mark Kirby Nov 08 '15 at 20:56
0

Start by taking a step backwards and purge whatever partial install the system is finding.

sudo apt-get remove --purge mysql-server

Follow that with an attempt to get rid of any busted config files.

sudo apt-get autoremove 

Now you're starting fresh. You shouldn't have to add the repository. Just try

sudo apt-get install msyql-server 

In fact, I'm pretty sure that MySql server and client are both available through the Software Center as far back as Precise.