Possible Duplicate:
Scripted install of MySQL on Ubuntu

I wrote script for LAMP auto installation, but it hangs when installs MySQL, because mysql-server asks for new mysql root password. How can I skip this step? P.S. I use command apt-get install -y mysql-server

link|improve this question

69% accept rate
feedback

closed as exact duplicate by womble, Iain, crb, pauska, jscott Jul 12 '11 at 11:48

This question covers exactly the same ground as earlier questions on this topic; its answers may be merged with another identical question. See the FAQ for guidance on how to improve it.

1 Answer

You can "preseed" the value of any debconf variable (see the manpage for debconf-set-selections; the keys you want are mysql-server/root_password and mysql-server/root_password_again) or, because the question is non-critical, you can skip it by either setting your debconf priority higher or just setting your DEBIAN_FRONTEND=noninteractive.

link|improve this answer
feedback

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