Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I am setting up a new MySQL Slave and I can't start mysql after replacing the datadir (/db/mysql) with the innobackupex backup from the master.

I have given the directory the permissions with:

sudo chown -R mysql:mysql /db/mysql

I'm on Ubuntu 12.04 and MySQL 5.5.24

Output of syslog:

Oct 29 11:30:58 pling kernel: [592726.361193] type=1400 audit(1351506658.659:15238): 
    apparmor="STATUS" operation="profile_replace" name="/usr/sbin/mysqld" pid=2180 
    comm="apparmor_parser"
Oct 29 11:30:59 pling kernel: [592727.427746] init: mysql main process (2184) 
    terminated with status 1
Oct 29 11:30:59 pling kernel: [592727.427777] init: mysql main process ended, 
    respawning
Oct 29 11:31:00 pling kernel: [592728.386459] init: mysql post-start process (2185) 
    terminated with status 1
Oct 29 11:31:00 pling kernel: [592728.395562] type=1400 audit(1351506660.699:15239): 
    apparmor="STATUS" operation="profile_replace" name="/usr/sbin/mysqld" pid=2232 
    comm="apparmor_parser"
Oct 29 11:31:01 pling kernel: [592729.461727] init: mysql main process (2236) 
    terminated with status 1
Oct 29 11:31:01 pling kernel: [592729.461757] init: mysql main process ended, 
    respawning
Oct 29 11:31:02 pling kernel: [592730.421094] init: mysql post-start process (2237) 
    terminated with status 1
Oct 29 11:31:02 pling kernel: [592730.430515] type=1400 audit(1351506662.739:15240): 
    apparmor="STATUS" operation="profile_replace" name="/usr/sbin/mysqld" pid=2284 
    comm="apparmor_parser"
Oct 29 11:31:03 pling kernel: [592731.495980] init: mysql main process (2288) 
    terminated with status 1
Oct 29 11:31:03 pling kernel: [592731.496012] init: mysql respawning too fast, stopped

MySQL successfully ran after I changed the default datadir and updated apparmor's config. The problem occurred after replacing the datadir with the backup.

Do you have any suggestion on how to fix this?

share|improve this question

closed as too localized by Derek Downey, Paul White, Jack Douglas Oct 31 '12 at 10:03

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

    
I solved the problem by running: sudo dpkg-reconfigure mysql-server-5.5 –  RAH Oct 29 '12 at 10:50
2  
I'm not sure if this question should stay here or it should be migrated to SF. But you should post your solution as an answer (you can accept it, too!), if it solved your problem. –  ypercube Oct 31 '12 at 6:39
    
thanks for posting your solution—I'll close the question now as the solution is very specific to your issue and not likely to help others. –  Jack Douglas Oct 31 '12 at 10:03

1 Answer 1

up vote 1 down vote accepted

I solved the problem by running:

sudo dpkg-reconfigure mysql-server-5.5 
share|improve this answer

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