]> git.pld-linux.org Git - packages/mysql.git/blobdiff - mysql.init
- preserve indenting in mysqld.conf
[packages/mysql.git] / mysql.init
index f4db8e0df34e6c59a90371428b4c7b27312aaf79..ee1d731b53e6c99cb34cf1a420468a141a8392ec 100644 (file)
@@ -680,9 +680,9 @@ mysqlinit() {
        chmod 751 "$MYSQL_CLUSTER_DIR" "$MYSQL_CLUSTER_DIR/mysqldb"
 
        if [ -f /usr/share/mysql/mysqld.conf -a ! -f "$MYSQL_CLUSTER_DIR/mysqld.conf" ]; then
-           sed -e "s#datadir.*=.*#datadir      = $MYSQL_DATA_DIR#g" \
-               -e "s#pid-file.*=.*#pid-file = $MYSQL_PIDFILE#g" \
-               -e "s#socket.*=.*#socket = $MYSQL_SOCKET#g" \
+           sed -e "s#\(datadir.*\)=.*#\1= $MYSQL_DATA_DIR#g" \
+               -e "s#\(pid-file.*\)=.*#\1= $MYSQL_PIDFILE#g" \
+               -e "s#\(socket.*\)=.*#\1= $MYSQL_SOCKET#g" \
                /usr/share/mysql/mysqld.conf > "$MYSQL_CLUSTER_DIR/mysqld.conf"
            chown root:root "$MYSQL_CLUSTER_DIR/mysqld.conf"
            chmod 640 "$MYSQL_CLUSTER_DIR/mysqld.conf"
@@ -730,11 +730,11 @@ END_OF_DATA
        cat << END_OF_MSG
 
 PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL USERS!
-This is done (after starting database) with:
+This is done (after starting database; press enter when asked for password) with:
 
-/usr/bin/mysqladmin -u mysql -S $MYSQL_SOCKET password 'password'
-/usr/bin/mysqladmin -h $hostname -u mysql -S $MYSQL_SOCKET password 'password'
-/usr/bin/mysqladmin -u mysql_logrotate -S $MYSQL_SOCKET password 'password'
+/usr/bin/mysqladmin -u mysql -p -S $MYSQL_SOCKET password 'password'
+/usr/bin/mysqladmin -h $hostname -u mysql -p -S $MYSQL_SOCKET password 'password'
+/usr/bin/mysqladmin -u mysql_logrotate -p -S $MYSQL_SOCKET password 'password'
 
 NOTE: mysql_logrotate password should be placed to $MYSQL_CONFIG in
 mysqladmin section. See the manual for more instructions.
This page took 0.027291 seconds and 4 git commands to generate.