Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I broke my mysql and now I want to completely reinstall it. I tried:

$ sudo apt-get install --reinstall mysql-server
$ sudo apt-get remove --purge mysql-client mysql-server

But always I see popup with proposal to change root password, I change it and got an error that I can change it..

$ sudo apt-get remove --purge mysql-client mysql-server
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package mysql-client is not installed, so not removed
Package mysql-server is not installed, so not removed
The following packages were automatically installed and are no longer required:
  libmygpo-qt1 libqtscript4-network libqtscript4-gui libtag-extras1 libqtscript4-sql libqtscript4-xml
  amarok-utils amarok-common libqtscript4-uitools liblastfm0 libloudmouth1-0 libqtscript4-core
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up mysql-server-5.5 (5.5.28-0ubuntu0.12.04.2) ...
121114 19:04:03 [Note] Plugin 'FEDERATED' is disabled.
121114 19:04:03 InnoDB: The InnoDB memory heap is disabled
121114 19:04:03 InnoDB: Mutexes and rw_locks use GCC atomic builtins
121114 19:04:03 InnoDB: Compressed tables use zlib 1.2.3.4
121114 19:04:03 InnoDB: Initializing buffer pool, size = 128.0M
121114 19:04:03 InnoDB: Completed initialization of buffer pool
InnoDB: Error: auto-extending data file ./ibdata1 is of a different size
InnoDB: 0 pages (rounded down to MB) than specified in the .cnf file:
InnoDB: initial 640 pages, max 0 (relevant if non-zero) pages!
121114 19:04:03 InnoDB: Could not open or create data files.
121114 19:04:03 InnoDB: If you tried to add new data files, and it failed here,
121114 19:04:03 InnoDB: you should now edit innodb_data_file_path in my.cnf back
121114 19:04:03 InnoDB: to what it was, and remove the new ibdata files InnoDB created
121114 19:04:03 InnoDB: in this failed attempt. InnoDB only wrote those files full of
121114 19:04:03 InnoDB: zeros, but did not yet use them in any way. But be careful: do not
121114 19:04:03 InnoDB: remove old data files which contain your precious data!
121114 19:04:03 [ERROR] Plugin 'InnoDB' init function returned error.
121114 19:04:03 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
121114 19:04:03 [ERROR] Unknown/unsupported storage engine: InnoDB
121114 19:04:03 [ERROR] Aborting

121114 19:04:03 [Note] /usr/sbin/mysqld: Shutdown complete

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)

It is good for me that I have not any important databases, but..

EDIT

$ sudo apt-get remove mysql-server
[sudo] password for teplyakov: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages will be REMOVED:
  mysql-server
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
2 not fully installed or removed.
After this operation, 115 kB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 303491 files and directories currently installed.)
Removing mysql-server ...
Setting up mysql-server-5.5 (5.5.28-0ubuntu0.12.04.2) ...
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)

I'm especially confused with it:

Removing mysql-server ...
Setting up mysql-server-5.5 (5.5.28-0ubuntu0.12.04.2) ...
start: Job failed to start
share|improve this question
add comment

1 Answer

Here I founded some voodoo tricks that helped me, maybe useful for you : https://bugs.launchpad.net/ubuntu/+source/mysql-5.5/+bug/989353

I removed the following packages and then reinstalled mysql-server :

sudo apt-get --purge remove mysql-server-5.1 mysql-server-5.5
sudo apt-get install mysql-server
share|improve this answer
    
Welcome to Ask Ubuntu! Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference. –  hhlp Nov 28 '12 at 16:00
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.