summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2023-03-17 15:03:17 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2023-03-17 15:03:17 +0200
commit4c355d4e81ac009abcfb94df4285d48c5229f958 (patch)
tree51758a1ae9e98dd596befaea2b9fc84bb78dfaac /scripts
parent090e5d8b945bb2d0dfad1193c23cdc1bd271344e (diff)
parent7343a2ceb67e4e408e24f3b28a714e106ffe804a (diff)
downloadmariadb-git-4c355d4e81ac009abcfb94df4285d48c5229f958.tar.gz
Merge 10.11 into 11.0
Diffstat (limited to 'scripts')
-rw-r--r--scripts/mysql_install_db.sh24
1 files changed, 18 insertions, 6 deletions
diff --git a/scripts/mysql_install_db.sh b/scripts/mysql_install_db.sh
index 6895c458e4a..5fc60567e11 100644
--- a/scripts/mysql_install_db.sh
+++ b/scripts/mysql_install_db.sh
@@ -17,7 +17,7 @@
# This scripts creates the MariaDB Server system tables
#
-# All unrecognized arguments to this script are passed to mysqld.
+# All unrecognized arguments to this script are passed to mariadbd.
basedir=""
builddir=""
@@ -33,6 +33,7 @@ mysqld_opt=""
user=""
group=""
silent_startup="--silent-startup"
+log_error=""
force=0
in_rpm=0
@@ -328,9 +329,9 @@ then
exit 1
fi
-# Now we can get arguments from the groups [mysqld] and [mysql_install_db]
+# Now we can get arguments from the groups [mariadbd] and [mysql_install_db]
# in the my.cfg file, then re-run to merge with command line arguments.
-parse_arguments `"$print_defaults" $defaults $defaults_group_suffix --mysqld mysql_install_db mariadb-install-db`
+parse_arguments `"$print_defaults" $defaults $defaults_group_suffix --mariadbd mysql_install_db mariadb-install-db`
parse_arguments PICK-ARGS-FROM-ARGV "$@"
@@ -533,7 +534,7 @@ then
args="$args --user=$user"
fi
-#To be enabled if/when we enable --group as an option to mysqld
+#To be enabled if/when we enable --group as an option to mariadbd
#if test -n "$group"
#then
# args="$args --group=$group"
@@ -556,7 +557,18 @@ else
filter_cmd_line="cat"
fi
-# Configure mysqld command line
+# Disable log error if the user don't have write access to the directory.
+# This is common when a user tries to install a personal mariadbd server
+if test -n $log_error
+then
+ if test ! -w $log_error
+ then
+ log_error=""
+ args="$args --skip-log-error"
+ fi
+fi
+
+# Configure mariadbd command line
mysqld_bootstrap="${MYSQLD_BOOTSTRAP-$mysqld}"
mysqld_install_cmd_line()
{
@@ -599,7 +611,7 @@ cat_sql()
fi
}
-# Create the system and help tables by passing them to "mysqld --bootstrap"
+# Create the system and help tables by passing them to "mariadbd --bootstrap"
s_echo "Installing MariaDB/MySQL system tables in '$ldata' ..."
if cat_sql | eval "$filter_cmd_line" | mysqld_install_cmd_line > /dev/null
then