Can't get mysql working out of the box

Harald Gröne h.groene at gmx.net
Fri Sep 10 19:25:02 CEST 2004


Hi!

I'm installing a mysql server with fai 2.6.1 (sarge environment+local sarge 
mirror). But mysql doesn't work after reboot.
After a "dpkg-reconfigure mysql-server" by hand everthing runs perfectly.
So what's wrong with my /usr/local/share/fai/scripts/MYSQL/S10 script below?

			Ciao'
				Harry


---SNIP--- 
#!/bin/sh

# copy custom databases
ftar /var/lib/mysql
# 1st try to get it work
$ROOTCMD sh -c "echo \n\n\n | dpkg-reconfigure mysql-server 2<&0"
# make sure mysql exists
$ROOTCMD useradd -g mysql mysql
# make sure, databases have the right owner
$ROOTCMD chown -R mysql.mysql /var/lib/mysql
# last try to get it work
$ROOTCMD sh -c "echo \n\n\n | /usr/sbin/dpkg-reconfigure mysql-server 2<&0"
# give up with a smile
exit 0
---SNAP---

-- 
Harald Gröne
Ostenhellweg 49
59192 Bergkamen
Germany

+49 2389 2965
Fax: +49 2389 2969
mail: h.groene at gmx.net



More information about the linux-fai mailing list