postinst fails when installing on a low memory system

Bug #1311387 reported by Colin Charles on 2014-04-22
28
This bug affects 10 people
Affects Status Importance Assigned to Milestone
mysql-5.6 (Ubuntu)
Low
Unassigned

Bug Description

If you install Ubuntu 14.04 LTS on a t1.micro instance on amazon (613MB ram), you cannot simply do a: sudo apt-get install mysql-server-5.6.

You get an error:
start: Job failed to start
invoke-rc.d: initscript mysql, action "start" failed.
dpkg: error processing package mysql-server-5.6 (--configure):
 subprocess installed post-installation script returned error exit status 1
Setting up mysql-common-5.6 (5.6.16-1~exp1) ...
Processing triggers for libc-bin (2.19-0ubuntu6) ...
Errors were encountered while processing:
 mysql-server-5.6
E: Sub-process /usr/bin/dpkg returned an error code (1)

This is because you need to set innodb_buffer_pool_size = 64M (or even 96M or 128M) in /etc/mysql/my.cnf

I think the default clearly should ship with something like that, to provide a good out-of-the-box experience for users

James Page (james-page) wrote :

I think the default in 5.6 changed from 8M to 128M - which would explain why this does not impact 5.5.

Changed in mysql-5.6 (Ubuntu):
status: New → Triaged
importance: Undecided → Low
Robie Basak (racb) on 2015-11-13
Changed in mysql-5.6 (Ubuntu):
assignee: nobody → Robie Basak (racb)
Robie Basak (racb) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better.

Unfortunately, we have to ship _some_ default, even if it is not the most appropriate in all cases. I think it's most appropriate to ship the default that upstream consider best, and for 5.6 it is 128 MB. This does mean that sysadmin intervention will be required to make mysql-server-5.6 work on a t1.micro instance, but I don't see any reasonable way around this (lowering innodb_buffer_pool_size would harm performance by default on more common mysql-server-5.6 deployments, AIUI).

Having said that, I just noticed that you got a dpkg install error, which I don't think should happen. We need to look into failing to start the daemon more gracefully.

summary: - add a small default innodb_buffer_pool_size
+ postinst fails when installing on a low memory system
Changed in mysql-5.6 (Ubuntu):
assignee: Robie Basak (racb) → nobody

Another work around is to disable "performance_schema" This was not enabled by default in the 5.5 packages AFAIK. Disabling it allows MySql 5.6 to install/start on a 512mb server for me.

Interestingly, using 5.6.27-0ubuntu0.14.04.1 on 14.04 on a 512mb server consistently fails to install while 5.6.27-0ubuntu1 with 15.10 doesn't. I don't see any obvious configuration difference scanning the diff though.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers