summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorVladislav Vaintroub <wlad@mariadb.com>2021-03-09 17:17:03 +0100
committerVladislav Vaintroub <wlad@mariadb.com>2021-03-18 08:02:49 +0100
commitfce1a53d55c5e6767c4f1c15683252311fda63ba (patch)
treeba511e99b6bdab9c2ce0ed142dd155499281cb30 /scripts
parent5ce22bac076151869066340dcd98895d66964b73 (diff)
downloadmariadb-git-fce1a53d55c5e6767c4f1c15683252311fda63ba.tar.gz
MDEV-9077 sys schema . use 'mariadb.sys'@'localhost' as definer for viewsbb-10.6-MDEV-9077
Diffstat (limited to 'scripts')
-rw-r--r--scripts/sys_schema/functions/extract_schema_from_file_name.sql2
-rw-r--r--scripts/sys_schema/functions/extract_table_from_file_name.sql2
-rw-r--r--scripts/sys_schema/functions/format_bytes.sql2
-rw-r--r--scripts/sys_schema/functions/format_path.sql2
-rw-r--r--scripts/sys_schema/functions/format_path_57.sql2
-rw-r--r--scripts/sys_schema/functions/format_statement.sql2
-rw-r--r--scripts/sys_schema/functions/format_time.sql2
-rw-r--r--scripts/sys_schema/functions/list_add.sql2
-rw-r--r--scripts/sys_schema/functions/list_drop.sql2
-rw-r--r--scripts/sys_schema/functions/ps_is_account_enabled.sql2
-rw-r--r--scripts/sys_schema/functions/ps_is_account_enabled_57.sql2
-rw-r--r--scripts/sys_schema/functions/ps_is_consumer_enabled.sql2
-rw-r--r--scripts/sys_schema/functions/ps_is_instrument_default_enabled.sql2
-rw-r--r--scripts/sys_schema/functions/ps_is_instrument_default_timed.sql2
-rw-r--r--scripts/sys_schema/functions/ps_is_thread_instrumented.sql2
-rw-r--r--scripts/sys_schema/functions/ps_thread_account.sql2
-rw-r--r--scripts/sys_schema/functions/ps_thread_id.sql2
-rw-r--r--scripts/sys_schema/functions/ps_thread_stack.sql2
-rw-r--r--scripts/sys_schema/functions/ps_thread_trx_info.sql2
-rw-r--r--scripts/sys_schema/functions/quote_identifier.sql2
-rw-r--r--scripts/sys_schema/functions/sys_get_config.sql2
-rw-r--r--scripts/sys_schema/functions/version_major.sql2
-rw-r--r--scripts/sys_schema/functions/version_minor.sql2
-rw-r--r--scripts/sys_schema/functions/version_patch.sql2
-rw-r--r--scripts/sys_schema/procedures/create_synonym_db.sql2
-rw-r--r--scripts/sys_schema/procedures/diagnostics.sql2
-rw-r--r--scripts/sys_schema/procedures/execute_prepared_stmt.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_disable_background_threads.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_disable_consumer.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_disable_instrument.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_disable_thread.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_enable_background_threads.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_enable_consumer.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_enable_instrument.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_enable_thread.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_reload_saved.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_reset_to_default.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_reset_to_default_57.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_save.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_show_disabled.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_show_disabled_consumers.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_show_disabled_instruments.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_show_enabled.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_show_enabled_consumers.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_setup_show_enabled_instruments.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_statement_avg_latency_histogram.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_trace_statement_digest.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_trace_thread.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_trace_thread_57.sql2
-rw-r--r--scripts/sys_schema/procedures/ps_truncate_all_tables.sql2
-rw-r--r--scripts/sys_schema/procedures/statement_performance_analyzer.sql2
-rw-r--r--scripts/sys_schema/procedures/table_exists.sql2
-rw-r--r--scripts/sys_schema/templates/function.sql2
-rw-r--r--scripts/sys_schema/templates/procedure.sql2
-rw-r--r--scripts/sys_schema/views/i_s/innodb_buffer_stats_by_schema.sql2
-rw-r--r--scripts/sys_schema/views/i_s/innodb_buffer_stats_by_table.sql2
-rw-r--r--scripts/sys_schema/views/i_s/innodb_lock_waits.sql2
-rw-r--r--scripts/sys_schema/views/i_s/schema_auto_increment_columns.sql2
-rw-r--r--scripts/sys_schema/views/i_s/schema_object_overview.sql2
-rw-r--r--scripts/sys_schema/views/i_s/schema_redundant_indexes.sql2
-rw-r--r--scripts/sys_schema/views/i_s/x_innodb_buffer_stats_by_schema.sql2
-rw-r--r--scripts/sys_schema/views/i_s/x_innodb_buffer_stats_by_table.sql2
-rw-r--r--scripts/sys_schema/views/i_s/x_innodb_lock_waits.sql2
-rw-r--r--scripts/sys_schema/views/i_s/x_schema_flattened_keys.sql2
-rw-r--r--scripts/sys_schema/views/p_s/host_summary.sql2
-rw-r--r--scripts/sys_schema/views/p_s/host_summary_57.sql2
-rw-r--r--scripts/sys_schema/views/p_s/host_summary_by_file_io.sql2
-rw-r--r--scripts/sys_schema/views/p_s/host_summary_by_file_io_type.sql2
-rw-r--r--scripts/sys_schema/views/p_s/host_summary_by_stages.sql2
-rw-r--r--scripts/sys_schema/views/p_s/host_summary_by_statement_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/host_summary_by_statement_type.sql2
-rw-r--r--scripts/sys_schema/views/p_s/io_by_thread_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/io_global_by_file_by_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/io_global_by_file_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/io_global_by_wait_by_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/io_global_by_wait_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/latest_file_io.sql2
-rw-r--r--scripts/sys_schema/views/p_s/memory_by_host_by_current_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/memory_by_thread_by_current_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/memory_by_user_by_current_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/memory_global_by_current_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/memory_global_total.sql2
-rw-r--r--scripts/sys_schema/views/p_s/metrics.sql2
-rw-r--r--scripts/sys_schema/views/p_s/metrics_56.sql2
-rw-r--r--scripts/sys_schema/views/p_s/processlist.sql2
-rw-r--r--scripts/sys_schema/views/p_s/processlist_57.sql2
-rw-r--r--scripts/sys_schema/views/p_s/ps_check_lost_instrumentation.sql2
-rw-r--r--scripts/sys_schema/views/p_s/ps_check_lost_instrumentation_57.sql2
-rw-r--r--scripts/sys_schema/views/p_s/schema_index_statistics.sql2
-rw-r--r--scripts/sys_schema/views/p_s/schema_table_lock_waits.sql2
-rw-r--r--scripts/sys_schema/views/p_s/schema_table_statistics.sql2
-rw-r--r--scripts/sys_schema/views/p_s/schema_table_statistics_with_buffer.sql2
-rw-r--r--scripts/sys_schema/views/p_s/schema_tables_with_full_table_scans.sql2
-rw-r--r--scripts/sys_schema/views/p_s/schema_unused_indexes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/session_ssl_status.sql2
-rw-r--r--scripts/sys_schema/views/p_s/sessions.sql2
-rw-r--r--scripts/sys_schema/views/p_s/statement_analysis.sql2
-rw-r--r--scripts/sys_schema/views/p_s/statements_with_errors_or_warnings.sql2
-rw-r--r--scripts/sys_schema/views/p_s/statements_with_full_table_scans.sql2
-rw-r--r--scripts/sys_schema/views/p_s/statements_with_runtimes_in_95th_percentile.sql2
-rw-r--r--scripts/sys_schema/views/p_s/statements_with_sorting.sql2
-rw-r--r--scripts/sys_schema/views/p_s/statements_with_temp_tables.sql2
-rw-r--r--scripts/sys_schema/views/p_s/user_summary.sql2
-rw-r--r--scripts/sys_schema/views/p_s/user_summary_57.sql2
-rw-r--r--scripts/sys_schema/views/p_s/user_summary_by_file_io.sql2
-rw-r--r--scripts/sys_schema/views/p_s/user_summary_by_file_io_type.sql2
-rw-r--r--scripts/sys_schema/views/p_s/user_summary_by_stages.sql2
-rw-r--r--scripts/sys_schema/views/p_s/user_summary_by_statement_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/user_summary_by_statement_type.sql2
-rw-r--r--scripts/sys_schema/views/p_s/wait_classes_global_by_avg_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/wait_classes_global_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/waits_by_host_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/waits_by_user_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/waits_global_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_host_summary.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_host_summary_57.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_host_summary_by_file_io.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_host_summary_by_file_io_type.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_host_summary_by_stages.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_host_summary_by_statement_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_host_summary_by_statement_type.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_io_by_thread_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_io_global_by_file_by_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_io_global_by_file_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_io_global_by_wait_by_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_io_global_by_wait_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_latest_file_io.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_memory_by_host_by_current_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_memory_by_thread_by_current_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_memory_by_user_by_current_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_memory_global_by_current_bytes.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_memory_global_total.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_processlist.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_processlist_57.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_ps_digest_95th_percentile_by_avg_us.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_ps_digest_avg_latency_distribution.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_ps_schema_table_statistics_io.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_schema_index_statistics.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_schema_table_lock_waits.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_schema_table_statistics.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_schema_table_statistics_with_buffer.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_schema_tables_with_full_table_scans.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_sessions.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_statement_analysis.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_statements_with_errors_or_warnings.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_statements_with_full_table_scans.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_statements_with_runtimes_in_95th_percentile.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_statements_with_sorting.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_statements_with_temp_tables.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_user_summary.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_user_summary_57.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_user_summary_by_file_io.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_user_summary_by_file_io_type.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_user_summary_by_stages.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_user_summary_by_statement_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_user_summary_by_statement_type.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_wait_classes_global_by_avg_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_wait_classes_global_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_waits_by_host_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_waits_by_user_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/p_s/x_waits_global_by_latency.sql2
-rw-r--r--scripts/sys_schema/views/version.sql2
162 files changed, 162 insertions, 162 deletions
diff --git a/scripts/sys_schema/functions/extract_schema_from_file_name.sql b/scripts/sys_schema/functions/extract_schema_from_file_name.sql
index 4e30af58fd8..92c127f9551 100644
--- a/scripts/sys_schema/functions/extract_schema_from_file_name.sql
+++ b/scripts/sys_schema/functions/extract_schema_from_file_name.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS extract_schema_from_file_name;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION extract_schema_from_file_name (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION extract_schema_from_file_name (
path VARCHAR(512)
)
RETURNS VARCHAR(64)
diff --git a/scripts/sys_schema/functions/extract_table_from_file_name.sql b/scripts/sys_schema/functions/extract_table_from_file_name.sql
index 3f34409eeb2..54f925681c2 100644
--- a/scripts/sys_schema/functions/extract_table_from_file_name.sql
+++ b/scripts/sys_schema/functions/extract_table_from_file_name.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS extract_table_from_file_name;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION extract_table_from_file_name (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION extract_table_from_file_name (
path VARCHAR(512)
)
RETURNS VARCHAR(64)
diff --git a/scripts/sys_schema/functions/format_bytes.sql b/scripts/sys_schema/functions/format_bytes.sql
index dfe4105ea92..361aa39a639 100644
--- a/scripts/sys_schema/functions/format_bytes.sql
+++ b/scripts/sys_schema/functions/format_bytes.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS format_bytes;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION format_bytes (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION format_bytes (
-- We feed in and return TEXT here, as aggregates of
-- bytes can return numbers larger than BIGINT UNSIGNED
bytes TEXT
diff --git a/scripts/sys_schema/functions/format_path.sql b/scripts/sys_schema/functions/format_path.sql
index 59704d11c2b..426bfb1dac8 100644
--- a/scripts/sys_schema/functions/format_path.sql
+++ b/scripts/sys_schema/functions/format_path.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS format_path;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION format_path (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION format_path (
in_path VARCHAR(512)
)
RETURNS VARCHAR(512) CHARSET UTF8
diff --git a/scripts/sys_schema/functions/format_path_57.sql b/scripts/sys_schema/functions/format_path_57.sql
index 61c496fd605..2bb8b72395e 100644
--- a/scripts/sys_schema/functions/format_path_57.sql
+++ b/scripts/sys_schema/functions/format_path_57.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS format_path;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION format_path (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION format_path (
in_path VARCHAR(512)
)
RETURNS VARCHAR(512) CHARSET UTF8
diff --git a/scripts/sys_schema/functions/format_statement.sql b/scripts/sys_schema/functions/format_statement.sql
index 98a60489199..8e434b24bc2 100644
--- a/scripts/sys_schema/functions/format_statement.sql
+++ b/scripts/sys_schema/functions/format_statement.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS format_statement;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION format_statement (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION format_statement (
statement LONGTEXT
)
RETURNS LONGTEXT
diff --git a/scripts/sys_schema/functions/format_time.sql b/scripts/sys_schema/functions/format_time.sql
index 72c7b78abf0..f828f791e96 100644
--- a/scripts/sys_schema/functions/format_time.sql
+++ b/scripts/sys_schema/functions/format_time.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS format_time;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION format_time (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION format_time (
-- We feed in and return TEXT here, as aggregates of
-- picoseconds can return numbers larger than BIGINT UNSIGNED
picoseconds TEXT
diff --git a/scripts/sys_schema/functions/list_add.sql b/scripts/sys_schema/functions/list_add.sql
index 0d4eeb9afd6..6079fbc584c 100644
--- a/scripts/sys_schema/functions/list_add.sql
+++ b/scripts/sys_schema/functions/list_add.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS list_add;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION list_add (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION list_add (
in_list TEXT,
in_add_value TEXT
)
diff --git a/scripts/sys_schema/functions/list_drop.sql b/scripts/sys_schema/functions/list_drop.sql
index 62298936f1a..eccce7ed47c 100644
--- a/scripts/sys_schema/functions/list_drop.sql
+++ b/scripts/sys_schema/functions/list_drop.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS list_drop;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION list_drop (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION list_drop (
in_list TEXT,
in_drop_value TEXT
)
diff --git a/scripts/sys_schema/functions/ps_is_account_enabled.sql b/scripts/sys_schema/functions/ps_is_account_enabled.sql
index 127baad1aca..a4bcecc4c41 100644
--- a/scripts/sys_schema/functions/ps_is_account_enabled.sql
+++ b/scripts/sys_schema/functions/ps_is_account_enabled.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS ps_is_account_enabled;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION ps_is_account_enabled (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION ps_is_account_enabled (
in_host VARCHAR(60),
in_user VARCHAR(16)
)
diff --git a/scripts/sys_schema/functions/ps_is_account_enabled_57.sql b/scripts/sys_schema/functions/ps_is_account_enabled_57.sql
index 3b832793174..12480716d00 100644
--- a/scripts/sys_schema/functions/ps_is_account_enabled_57.sql
+++ b/scripts/sys_schema/functions/ps_is_account_enabled_57.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS ps_is_account_enabled;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION ps_is_account_enabled (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION ps_is_account_enabled (
in_host VARCHAR(60),
in_user VARCHAR(32)
)
diff --git a/scripts/sys_schema/functions/ps_is_consumer_enabled.sql b/scripts/sys_schema/functions/ps_is_consumer_enabled.sql
index f81b8d2f20c..c9290a9c919 100644
--- a/scripts/sys_schema/functions/ps_is_consumer_enabled.sql
+++ b/scripts/sys_schema/functions/ps_is_consumer_enabled.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS ps_is_consumer_enabled;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION ps_is_consumer_enabled (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION ps_is_consumer_enabled (
in_consumer varchar(64)
)
RETURNS enum('YES', 'NO')
diff --git a/scripts/sys_schema/functions/ps_is_instrument_default_enabled.sql b/scripts/sys_schema/functions/ps_is_instrument_default_enabled.sql
index 19041e4a08b..2d79a1611ea 100644
--- a/scripts/sys_schema/functions/ps_is_instrument_default_enabled.sql
+++ b/scripts/sys_schema/functions/ps_is_instrument_default_enabled.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS ps_is_instrument_default_enabled;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION ps_is_instrument_default_enabled (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION ps_is_instrument_default_enabled (
in_instrument VARCHAR(128)
)
RETURNS ENUM('YES', 'NO')
diff --git a/scripts/sys_schema/functions/ps_is_instrument_default_timed.sql b/scripts/sys_schema/functions/ps_is_instrument_default_timed.sql
index 36c9ee44347..d78e324d719 100644
--- a/scripts/sys_schema/functions/ps_is_instrument_default_timed.sql
+++ b/scripts/sys_schema/functions/ps_is_instrument_default_timed.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS ps_is_instrument_default_timed;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION ps_is_instrument_default_timed (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION ps_is_instrument_default_timed (
in_instrument VARCHAR(128)
)
RETURNS ENUM('YES', 'NO')
diff --git a/scripts/sys_schema/functions/ps_is_thread_instrumented.sql b/scripts/sys_schema/functions/ps_is_thread_instrumented.sql
index 6358f932e3a..06388312135 100644
--- a/scripts/sys_schema/functions/ps_is_thread_instrumented.sql
+++ b/scripts/sys_schema/functions/ps_is_thread_instrumented.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS ps_is_thread_instrumented;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION ps_is_thread_instrumented (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION ps_is_thread_instrumented (
in_connection_id BIGINT UNSIGNED
) RETURNS ENUM('YES', 'NO', 'UNKNOWN')
COMMENT '
diff --git a/scripts/sys_schema/functions/ps_thread_account.sql b/scripts/sys_schema/functions/ps_thread_account.sql
index 1bb77433743..f91e8c66459 100644
--- a/scripts/sys_schema/functions/ps_thread_account.sql
+++ b/scripts/sys_schema/functions/ps_thread_account.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS ps_thread_account;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION ps_thread_account (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION ps_thread_account (
in_thread_id BIGINT UNSIGNED
) RETURNS TEXT
COMMENT '
diff --git a/scripts/sys_schema/functions/ps_thread_id.sql b/scripts/sys_schema/functions/ps_thread_id.sql
index ac55c991db2..f344e6e15d2 100644
--- a/scripts/sys_schema/functions/ps_thread_id.sql
+++ b/scripts/sys_schema/functions/ps_thread_id.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS ps_thread_id;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION ps_thread_id (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION ps_thread_id (
in_connection_id BIGINT UNSIGNED
) RETURNS BIGINT UNSIGNED
COMMENT '
diff --git a/scripts/sys_schema/functions/ps_thread_stack.sql b/scripts/sys_schema/functions/ps_thread_stack.sql
index 674f09e80dd..12b09bd6637 100644
--- a/scripts/sys_schema/functions/ps_thread_stack.sql
+++ b/scripts/sys_schema/functions/ps_thread_stack.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS ps_thread_stack;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION ps_thread_stack (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION ps_thread_stack (
thd_id BIGINT UNSIGNED,
debug BOOLEAN
)
diff --git a/scripts/sys_schema/functions/ps_thread_trx_info.sql b/scripts/sys_schema/functions/ps_thread_trx_info.sql
index 906578db6ab..12ab6aefc56 100644
--- a/scripts/sys_schema/functions/ps_thread_trx_info.sql
+++ b/scripts/sys_schema/functions/ps_thread_trx_info.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS ps_thread_trx_info;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION ps_thread_trx_info (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION ps_thread_trx_info (
in_thread_id BIGINT UNSIGNED
) RETURNS LONGTEXT
COMMENT '
diff --git a/scripts/sys_schema/functions/quote_identifier.sql b/scripts/sys_schema/functions/quote_identifier.sql
index b9c322775b1..b661e5c7b01 100644
--- a/scripts/sys_schema/functions/quote_identifier.sql
+++ b/scripts/sys_schema/functions/quote_identifier.sql
@@ -22,7 +22,7 @@ DELIMITER $$
-- Before that, user variables could have any length.
--
-- Based on Paul Dubois' suggestion in Bug #78823/Bug #22011361.
-CREATE DEFINER='root'@'localhost' FUNCTION quote_identifier(in_identifier TEXT)
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION quote_identifier(in_identifier TEXT)
RETURNS TEXT CHARSET UTF8
COMMENT '
Description
diff --git a/scripts/sys_schema/functions/sys_get_config.sql b/scripts/sys_schema/functions/sys_get_config.sql
index 1064a8f4ee8..bf490a66381 100644
--- a/scripts/sys_schema/functions/sys_get_config.sql
+++ b/scripts/sys_schema/functions/sys_get_config.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS sys_get_config;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION sys_get_config (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION sys_get_config (
in_variable_name VARCHAR(128),
in_default_value VARCHAR(128)
)
diff --git a/scripts/sys_schema/functions/version_major.sql b/scripts/sys_schema/functions/version_major.sql
index c4d2ae25a21..8e44d8cf3e2 100644
--- a/scripts/sys_schema/functions/version_major.sql
+++ b/scripts/sys_schema/functions/version_major.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS version_major;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION version_major ()
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION version_major ()
RETURNS TINYINT UNSIGNED
COMMENT '
Description
diff --git a/scripts/sys_schema/functions/version_minor.sql b/scripts/sys_schema/functions/version_minor.sql
index b4766cb98ee..6d8f654d6f2 100644
--- a/scripts/sys_schema/functions/version_minor.sql
+++ b/scripts/sys_schema/functions/version_minor.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS version_minor;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION version_minor ()
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION version_minor ()
RETURNS TINYINT UNSIGNED
COMMENT '
Description
diff --git a/scripts/sys_schema/functions/version_patch.sql b/scripts/sys_schema/functions/version_patch.sql
index de7f1184bfd..156b5678a17 100644
--- a/scripts/sys_schema/functions/version_patch.sql
+++ b/scripts/sys_schema/functions/version_patch.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS version_patch;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION version_patch ()
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION version_patch ()
RETURNS TINYINT UNSIGNED
COMMENT '
Description
diff --git a/scripts/sys_schema/procedures/create_synonym_db.sql b/scripts/sys_schema/procedures/create_synonym_db.sql
index 4f6a8efb223..703ec9bff3b 100644
--- a/scripts/sys_schema/procedures/create_synonym_db.sql
+++ b/scripts/sys_schema/procedures/create_synonym_db.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS create_synonym_db;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE create_synonym_db (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE create_synonym_db (
IN in_db_name VARCHAR(64),
IN in_synonym VARCHAR(64)
)
diff --git a/scripts/sys_schema/procedures/diagnostics.sql b/scripts/sys_schema/procedures/diagnostics.sql
index 8cccdb68233..2e79c5c1c2a 100644
--- a/scripts/sys_schema/procedures/diagnostics.sql
+++ b/scripts/sys_schema/procedures/diagnostics.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS diagnostics;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE diagnostics (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE diagnostics (
IN in_max_runtime int unsigned, IN in_interval int unsigned,
IN in_auto_config enum ('current', 'medium', 'full')
)
diff --git a/scripts/sys_schema/procedures/execute_prepared_stmt.sql b/scripts/sys_schema/procedures/execute_prepared_stmt.sql
index b77732b5487..8e975b909c2 100644
--- a/scripts/sys_schema/procedures/execute_prepared_stmt.sql
+++ b/scripts/sys_schema/procedures/execute_prepared_stmt.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS execute_prepared_stmt;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE execute_prepared_stmt (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE execute_prepared_stmt (
IN in_query longtext CHARACTER SET UTF8
)
COMMENT '
diff --git a/scripts/sys_schema/procedures/ps_setup_disable_background_threads.sql b/scripts/sys_schema/procedures/ps_setup_disable_background_threads.sql
index 7d0758a4747..0c316bc78b8 100644
--- a/scripts/sys_schema/procedures/ps_setup_disable_background_threads.sql
+++ b/scripts/sys_schema/procedures/ps_setup_disable_background_threads.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_disable_background_threads;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_disable_background_threads ()
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_disable_background_threads ()
COMMENT '
Description
-----------
diff --git a/scripts/sys_schema/procedures/ps_setup_disable_consumer.sql b/scripts/sys_schema/procedures/ps_setup_disable_consumer.sql
index bf0c558186f..bdebd62e419 100644
--- a/scripts/sys_schema/procedures/ps_setup_disable_consumer.sql
+++ b/scripts/sys_schema/procedures/ps_setup_disable_consumer.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_disable_consumer;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_disable_consumer (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_disable_consumer (
IN consumer VARCHAR(128)
)
COMMENT '
diff --git a/scripts/sys_schema/procedures/ps_setup_disable_instrument.sql b/scripts/sys_schema/procedures/ps_setup_disable_instrument.sql
index 5132e33740c..14fe4d86b1d 100644
--- a/scripts/sys_schema/procedures/ps_setup_disable_instrument.sql
+++ b/scripts/sys_schema/procedures/ps_setup_disable_instrument.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_disable_instrument;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_disable_instrument (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_disable_instrument (
IN in_pattern VARCHAR(128)
)
COMMENT '
diff --git a/scripts/sys_schema/procedures/ps_setup_disable_thread.sql b/scripts/sys_schema/procedures/ps_setup_disable_thread.sql
index 9141d387540..fe0bb86275f 100644
--- a/scripts/sys_schema/procedures/ps_setup_disable_thread.sql
+++ b/scripts/sys_schema/procedures/ps_setup_disable_thread.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_disable_thread;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_disable_thread (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_disable_thread (
IN in_connection_id BIGINT
)
COMMENT '
diff --git a/scripts/sys_schema/procedures/ps_setup_enable_background_threads.sql b/scripts/sys_schema/procedures/ps_setup_enable_background_threads.sql
index a5edee09810..ddca06b1287 100644
--- a/scripts/sys_schema/procedures/ps_setup_enable_background_threads.sql
+++ b/scripts/sys_schema/procedures/ps_setup_enable_background_threads.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_enable_background_threads;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_enable_background_threads ()
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_enable_background_threads ()
COMMENT '
Description
-----------
diff --git a/scripts/sys_schema/procedures/ps_setup_enable_consumer.sql b/scripts/sys_schema/procedures/ps_setup_enable_consumer.sql
index d728285a6a2..66138604595 100644
--- a/scripts/sys_schema/procedures/ps_setup_enable_consumer.sql
+++ b/scripts/sys_schema/procedures/ps_setup_enable_consumer.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_enable_consumer;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_enable_consumer (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_enable_consumer (
IN consumer VARCHAR(128)
)
COMMENT '
diff --git a/scripts/sys_schema/procedures/ps_setup_enable_instrument.sql b/scripts/sys_schema/procedures/ps_setup_enable_instrument.sql
index 6be9f343a64..964307de45a 100644
--- a/scripts/sys_schema/procedures/ps_setup_enable_instrument.sql
+++ b/scripts/sys_schema/procedures/ps_setup_enable_instrument.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_enable_instrument;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_enable_instrument (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_enable_instrument (
IN in_pattern VARCHAR(128)
)
COMMENT '
diff --git a/scripts/sys_schema/procedures/ps_setup_enable_thread.sql b/scripts/sys_schema/procedures/ps_setup_enable_thread.sql
index f03f7bd3ed3..15385fc8a3e 100644
--- a/scripts/sys_schema/procedures/ps_setup_enable_thread.sql
+++ b/scripts/sys_schema/procedures/ps_setup_enable_thread.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_enable_thread;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_enable_thread (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_enable_thread (
IN in_connection_id BIGINT
)
COMMENT '
diff --git a/scripts/sys_schema/procedures/ps_setup_reload_saved.sql b/scripts/sys_schema/procedures/ps_setup_reload_saved.sql
index 1ffde684113..38d463b1a4c 100644
--- a/scripts/sys_schema/procedures/ps_setup_reload_saved.sql
+++ b/scripts/sys_schema/procedures/ps_setup_reload_saved.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_reload_saved;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_reload_saved ()
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_reload_saved ()
COMMENT '
Description
-----------
diff --git a/scripts/sys_schema/procedures/ps_setup_reset_to_default.sql b/scripts/sys_schema/procedures/ps_setup_reset_to_default.sql
index 80804206e2e..b626fae82fd 100644
--- a/scripts/sys_schema/procedures/ps_setup_reset_to_default.sql
+++ b/scripts/sys_schema/procedures/ps_setup_reset_to_default.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_reset_to_default;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_reset_to_default (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_reset_to_default (
IN in_verbose BOOLEAN
)
COMMENT '
diff --git a/scripts/sys_schema/procedures/ps_setup_reset_to_default_57.sql b/scripts/sys_schema/procedures/ps_setup_reset_to_default_57.sql
index 7fb6b28ba11..8d3b2eecf71 100644
--- a/scripts/sys_schema/procedures/ps_setup_reset_to_default_57.sql
+++ b/scripts/sys_schema/procedures/ps_setup_reset_to_default_57.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_reset_to_default;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_reset_to_default (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_reset_to_default (
IN in_verbose BOOLEAN
)
COMMENT '
diff --git a/scripts/sys_schema/procedures/ps_setup_save.sql b/scripts/sys_schema/procedures/ps_setup_save.sql
index 97603c758a0..a5a2197e935 100644
--- a/scripts/sys_schema/procedures/ps_setup_save.sql
+++ b/scripts/sys_schema/procedures/ps_setup_save.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_save;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_save (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_save (
IN in_timeout INT
)
COMMENT '
diff --git a/scripts/sys_schema/procedures/ps_setup_show_disabled.sql b/scripts/sys_schema/procedures/ps_setup_show_disabled.sql
index 3148c5a5b6e..82c69840566 100644
--- a/scripts/sys_schema/procedures/ps_setup_show_disabled.sql
+++ b/scripts/sys_schema/procedures/ps_setup_show_disabled.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_show_disabled;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_show_disabled (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_show_disabled (
IN in_show_instruments BOOLEAN,
IN in_show_threads BOOLEAN
)
diff --git a/scripts/sys_schema/procedures/ps_setup_show_disabled_consumers.sql b/scripts/sys_schema/procedures/ps_setup_show_disabled_consumers.sql
index b21ba2bcea7..4c913efdc0e 100644
--- a/scripts/sys_schema/procedures/ps_setup_show_disabled_consumers.sql
+++ b/scripts/sys_schema/procedures/ps_setup_show_disabled_consumers.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_show_disabled_consumers;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_show_disabled_consumers ()
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_show_disabled_consumers ()
COMMENT '
Description
-----------
diff --git a/scripts/sys_schema/procedures/ps_setup_show_disabled_instruments.sql b/scripts/sys_schema/procedures/ps_setup_show_disabled_instruments.sql
index e893bb635f5..45fe7c083df 100644
--- a/scripts/sys_schema/procedures/ps_setup_show_disabled_instruments.sql
+++ b/scripts/sys_schema/procedures/ps_setup_show_disabled_instruments.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_show_disabled_instruments;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_show_disabled_instruments ()
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_show_disabled_instruments ()
COMMENT '
Description
-----------
diff --git a/scripts/sys_schema/procedures/ps_setup_show_enabled.sql b/scripts/sys_schema/procedures/ps_setup_show_enabled.sql
index 7b2c2644358..8e7c0506677 100644
--- a/scripts/sys_schema/procedures/ps_setup_show_enabled.sql
+++ b/scripts/sys_schema/procedures/ps_setup_show_enabled.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_show_enabled;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_show_enabled (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_show_enabled (
IN in_show_instruments BOOLEAN,
IN in_show_threads BOOLEAN
)
diff --git a/scripts/sys_schema/procedures/ps_setup_show_enabled_consumers.sql b/scripts/sys_schema/procedures/ps_setup_show_enabled_consumers.sql
index f8e5ddeed6e..57ec2b751b5 100644
--- a/scripts/sys_schema/procedures/ps_setup_show_enabled_consumers.sql
+++ b/scripts/sys_schema/procedures/ps_setup_show_enabled_consumers.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_show_enabled_consumers;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_show_enabled_consumers ()
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_show_enabled_consumers ()
COMMENT '
Description
-----------
diff --git a/scripts/sys_schema/procedures/ps_setup_show_enabled_instruments.sql b/scripts/sys_schema/procedures/ps_setup_show_enabled_instruments.sql
index d26bd680805..d8cfb108995 100644
--- a/scripts/sys_schema/procedures/ps_setup_show_enabled_instruments.sql
+++ b/scripts/sys_schema/procedures/ps_setup_show_enabled_instruments.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_setup_show_enabled_instruments;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_setup_show_enabled_instruments ()
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_setup_show_enabled_instruments ()
COMMENT '
Description
-----------
diff --git a/scripts/sys_schema/procedures/ps_statement_avg_latency_histogram.sql b/scripts/sys_schema/procedures/ps_statement_avg_latency_histogram.sql
index f808de31a3a..e57cbc1d452 100644
--- a/scripts/sys_schema/procedures/ps_statement_avg_latency_histogram.sql
+++ b/scripts/sys_schema/procedures/ps_statement_avg_latency_histogram.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_statement_avg_latency_histogram;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_statement_avg_latency_histogram ()
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_statement_avg_latency_histogram ()
COMMENT '
Description
-----------
diff --git a/scripts/sys_schema/procedures/ps_trace_statement_digest.sql b/scripts/sys_schema/procedures/ps_trace_statement_digest.sql
index 57cf8df32cb..f9bb4d3b09e 100644
--- a/scripts/sys_schema/procedures/ps_trace_statement_digest.sql
+++ b/scripts/sys_schema/procedures/ps_trace_statement_digest.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_trace_statement_digest;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_trace_statement_digest (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_trace_statement_digest (
IN in_digest VARCHAR(32),
IN in_runtime INT,
IN in_interval DECIMAL(2,2),
diff --git a/scripts/sys_schema/procedures/ps_trace_thread.sql b/scripts/sys_schema/procedures/ps_trace_thread.sql
index 35699a9e4c8..6e5666c2dea 100644
--- a/scripts/sys_schema/procedures/ps_trace_thread.sql
+++ b/scripts/sys_schema/procedures/ps_trace_thread.sql
@@ -16,7 +16,7 @@
DROP PROCEDURE IF EXISTS ps_trace_thread;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_trace_thread (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_trace_thread (
IN in_thread_id BIGINT UNSIGNED,
IN in_outfile VARCHAR(255),
IN in_max_runtime DECIMAL(20,2),
diff --git a/scripts/sys_schema/procedures/ps_trace_thread_57.sql b/scripts/sys_schema/procedures/ps_trace_thread_57.sql
index 313d51854a3..9aae53ba161 100644
--- a/scripts/sys_schema/procedures/ps_trace_thread_57.sql
+++ b/scripts/sys_schema/procedures/ps_trace_thread_57.sql
@@ -16,7 +16,7 @@
DROP PROCEDURE IF EXISTS ps_trace_thread;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_trace_thread (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_trace_thread (
IN in_thread_id BIGINT UNSIGNED,
IN in_outfile VARCHAR(255),
IN in_max_runtime DECIMAL(20,2),
diff --git a/scripts/sys_schema/procedures/ps_truncate_all_tables.sql b/scripts/sys_schema/procedures/ps_truncate_all_tables.sql
index cfd4fee8209..42d904f507c 100644
--- a/scripts/sys_schema/procedures/ps_truncate_all_tables.sql
+++ b/scripts/sys_schema/procedures/ps_truncate_all_tables.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS ps_truncate_all_tables;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE ps_truncate_all_tables (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE ps_truncate_all_tables (
IN in_verbose BOOLEAN
)
COMMENT '
diff --git a/scripts/sys_schema/procedures/statement_performance_analyzer.sql b/scripts/sys_schema/procedures/statement_performance_analyzer.sql
index fcb5af1f52e..f98596ef913 100644
--- a/scripts/sys_schema/procedures/statement_performance_analyzer.sql
+++ b/scripts/sys_schema/procedures/statement_performance_analyzer.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS statement_performance_analyzer;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE statement_performance_analyzer (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE statement_performance_analyzer (
IN in_action ENUM('snapshot', 'overall', 'delta', 'create_table', 'create_tmp', 'save', 'cleanup'),
IN in_table VARCHAR(129),
IN in_views SET ('with_runtimes_in_95th_percentile', 'analysis', 'with_errors_or_warnings', 'with_full_table_scans', 'with_sorting', 'with_temp_tables', 'custom')
diff --git a/scripts/sys_schema/procedures/table_exists.sql b/scripts/sys_schema/procedures/table_exists.sql
index 704edea8030..6f487f2f341 100644
--- a/scripts/sys_schema/procedures/table_exists.sql
+++ b/scripts/sys_schema/procedures/table_exists.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS table_exists;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE table_exists (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE table_exists (
IN in_db VARCHAR(64), IN in_table VARCHAR(64),
OUT out_exists ENUM('', 'BASE TABLE', 'VIEW', 'TEMPORARY')
)
diff --git a/scripts/sys_schema/templates/function.sql b/scripts/sys_schema/templates/function.sql
index fc0505b2e32..dac7899da0a 100644
--- a/scripts/sys_schema/templates/function.sql
+++ b/scripts/sys_schema/templates/function.sql
@@ -17,7 +17,7 @@ DROP FUNCTION IF EXISTS <function name>;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' FUNCTION <function name> (
+CREATE DEFINER='mariadb.sys'@'localhost' FUNCTION <function name> (
/* Variables */
)
RETURNS <data type>
diff --git a/scripts/sys_schema/templates/procedure.sql b/scripts/sys_schema/templates/procedure.sql
index 45140ec4ef0..a6b0860ac7d 100644
--- a/scripts/sys_schema/templates/procedure.sql
+++ b/scripts/sys_schema/templates/procedure.sql
@@ -17,7 +17,7 @@ DROP PROCEDURE IF EXISTS <procedure_name>;
DELIMITER $$
-CREATE DEFINER='root'@'localhost' PROCEDURE <procedure_name> (
+CREATE DEFINER='mariadb.sys'@'localhost' PROCEDURE <procedure_name> (
/* Variables */
)
COMMENT '
diff --git a/scripts/sys_schema/views/i_s/innodb_buffer_stats_by_schema.sql b/scripts/sys_schema/views/i_s/innodb_buffer_stats_by_schema.sql
index d3dc21d2ce4..46f7cdd027c 100644
--- a/scripts/sys_schema/views/i_s/innodb_buffer_stats_by_schema.sql
+++ b/scripts/sys_schema/views/i_s/innodb_buffer_stats_by_schema.sql
@@ -38,7 +38,7 @@ BEGIN NOT ATOMIC
END;
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW innodb_buffer_stats_by_schema (
object_schema,
diff --git a/scripts/sys_schema/views/i_s/innodb_buffer_stats_by_table.sql b/scripts/sys_schema/views/i_s/innodb_buffer_stats_by_table.sql
index 6a479370e2d..be104fb5bfc 100644
--- a/scripts/sys_schema/views/i_s/innodb_buffer_stats_by_table.sql
+++ b/scripts/sys_schema/views/i_s/innodb_buffer_stats_by_table.sql
@@ -39,7 +39,7 @@ BEGIN NOT ATOMIC
DECLARE EXIT HANDLER FOR SQLEXCEPTION BEGIN END;
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW innodb_buffer_stats_by_table (
object_schema,
diff --git a/scripts/sys_schema/views/i_s/innodb_lock_waits.sql b/scripts/sys_schema/views/i_s/innodb_lock_waits.sql
index d19e8f07fee..493eacfc5a8 100644
--- a/scripts/sys_schema/views/i_s/innodb_lock_waits.sql
+++ b/scripts/sys_schema/views/i_s/innodb_lock_waits.sql
@@ -58,7 +58,7 @@ BEGIN NOT ATOMIC
END;
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW innodb_lock_waits (
wait_started,
diff --git a/scripts/sys_schema/views/i_s/schema_auto_increment_columns.sql b/scripts/sys_schema/views/i_s/schema_auto_increment_columns.sql
index 806a24e682c..98c95695e31 100644
--- a/scripts/sys_schema/views/i_s/schema_auto_increment_columns.sql
+++ b/scripts/sys_schema/views/i_s/schema_auto_increment_columns.sql
@@ -18,7 +18,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW schema_auto_increment_columns (
table_schema,
diff --git a/scripts/sys_schema/views/i_s/schema_object_overview.sql b/scripts/sys_schema/views/i_s/schema_object_overview.sql
index f638b63e17c..9da11254293 100644
--- a/scripts/sys_schema/views/i_s/schema_object_overview.sql
+++ b/scripts/sys_schema/views/i_s/schema_object_overview.sql
@@ -39,7 +39,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW schema_object_overview (
db,
diff --git a/scripts/sys_schema/views/i_s/schema_redundant_indexes.sql b/scripts/sys_schema/views/i_s/schema_redundant_indexes.sql
index 2e8f3edd73a..8ad8bb8248e 100644
--- a/scripts/sys_schema/views/i_s/schema_redundant_indexes.sql
+++ b/scripts/sys_schema/views/i_s/schema_redundant_indexes.sql
@@ -33,7 +33,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW schema_redundant_indexes (
table_schema,
diff --git a/scripts/sys_schema/views/i_s/x_innodb_buffer_stats_by_schema.sql b/scripts/sys_schema/views/i_s/x_innodb_buffer_stats_by_schema.sql
index ab0d4df692c..6637f509135 100644
--- a/scripts/sys_schema/views/i_s/x_innodb_buffer_stats_by_schema.sql
+++ b/scripts/sys_schema/views/i_s/x_innodb_buffer_stats_by_schema.sql
@@ -36,7 +36,7 @@ BEGIN NOT ATOMIC
END;
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$innodb_buffer_stats_by_schema (
object_schema,
diff --git a/scripts/sys_schema/views/i_s/x_innodb_buffer_stats_by_table.sql b/scripts/sys_schema/views/i_s/x_innodb_buffer_stats_by_table.sql
index ea878fa5a3a..39d19b059b2 100644
--- a/scripts/sys_schema/views/i_s/x_innodb_buffer_stats_by_table.sql
+++ b/scripts/sys_schema/views/i_s/x_innodb_buffer_stats_by_table.sql
@@ -38,7 +38,7 @@ BEGIN NOT ATOMIC
DECLARE EXIT HANDLER FOR SQLEXCEPTION BEGIN END;
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$innodb_buffer_stats_by_table (
object_schema,
diff --git a/scripts/sys_schema/views/i_s/x_innodb_lock_waits.sql b/scripts/sys_schema/views/i_s/x_innodb_lock_waits.sql
index 4f9b4909282..a36bc4d77e0 100644
--- a/scripts/sys_schema/views/i_s/x_innodb_lock_waits.sql
+++ b/scripts/sys_schema/views/i_s/x_innodb_lock_waits.sql
@@ -58,7 +58,7 @@ DECLARE EXIT HANDLER FOR SQLEXCEPTION BEGIN END;
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$innodb_lock_waits (
wait_started,
diff --git a/scripts/sys_schema/views/i_s/x_schema_flattened_keys.sql b/scripts/sys_schema/views/i_s/x_schema_flattened_keys.sql
index 7a854d4c526..35001158412 100644
--- a/scripts/sys_schema/views/i_s/x_schema_flattened_keys.sql
+++ b/scripts/sys_schema/views/i_s/x_schema_flattened_keys.sql
@@ -17,7 +17,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$schema_flattened_keys (
table_schema,
diff --git a/scripts/sys_schema/views/p_s/host_summary.sql b/scripts/sys_schema/views/p_s/host_summary.sql
index 94d84f34616..080100a4241 100644
--- a/scripts/sys_schema/views/p_s/host_summary.sql
+++ b/scripts/sys_schema/views/p_s/host_summary.sql
@@ -30,7 +30,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW host_summary (
host,
diff --git a/scripts/sys_schema/views/p_s/host_summary_57.sql b/scripts/sys_schema/views/p_s/host_summary_57.sql
index 3a6f8c9ad19..cd0739f495f 100644
--- a/scripts/sys_schema/views/p_s/host_summary_57.sql
+++ b/scripts/sys_schema/views/p_s/host_summary_57.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW host_summary (
host,
diff --git a/scripts/sys_schema/views/p_s/host_summary_by_file_io.sql b/scripts/sys_schema/views/p_s/host_summary_by_file_io.sql
index 892b63ff78e..e1fbf2ea29d 100644
--- a/scripts/sys_schema/views/p_s/host_summary_by_file_io.sql
+++ b/scripts/sys_schema/views/p_s/host_summary_by_file_io.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW host_summary_by_file_io (
host,
diff --git a/scripts/sys_schema/views/p_s/host_summary_by_file_io_type.sql b/scripts/sys_schema/views/p_s/host_summary_by_file_io_type.sql
index 8cdf97cd50b..58567e3f7f2 100644
--- a/scripts/sys_schema/views/p_s/host_summary_by_file_io_type.sql
+++ b/scripts/sys_schema/views/p_s/host_summary_by_file_io_type.sql
@@ -46,7 +46,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW host_summary_by_file_io_type (
host,
diff --git a/scripts/sys_schema/views/p_s/host_summary_by_stages.sql b/scripts/sys_schema/views/p_s/host_summary_by_stages.sql
index 69a2a1f791a..97e5a7eef98 100644
--- a/scripts/sys_schema/views/p_s/host_summary_by_stages.sql
+++ b/scripts/sys_schema/views/p_s/host_summary_by_stages.sql
@@ -45,7 +45,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW host_summary_by_stages (
host,
diff --git a/scripts/sys_schema/views/p_s/host_summary_by_statement_latency.sql b/scripts/sys_schema/views/p_s/host_summary_by_statement_latency.sql
index 47d5efb7246..9eeb4c30d80 100644
--- a/scripts/sys_schema/views/p_s/host_summary_by_statement_latency.sql
+++ b/scripts/sys_schema/views/p_s/host_summary_by_statement_latency.sql
@@ -30,7 +30,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW host_summary_by_statement_latency (
host,
diff --git a/scripts/sys_schema/views/p_s/host_summary_by_statement_type.sql b/scripts/sys_schema/views/p_s/host_summary_by_statement_type.sql
index 22f5a788890..b529cd8c68d 100644
--- a/scripts/sys_schema/views/p_s/host_summary_by_statement_type.sql
+++ b/scripts/sys_schema/views/p_s/host_summary_by_statement_type.sql
@@ -35,7 +35,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW host_summary_by_statement_type (
host,
diff --git a/scripts/sys_schema/views/p_s/io_by_thread_by_latency.sql b/scripts/sys_schema/views/p_s/io_by_thread_by_latency.sql
index 5615132ba33..c5bf1c693c2 100644
--- a/scripts/sys_schema/views/p_s/io_by_thread_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/io_by_thread_by_latency.sql
@@ -38,7 +38,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW io_by_thread_by_latency (
user,
diff --git a/scripts/sys_schema/views/p_s/io_global_by_file_by_bytes.sql b/scripts/sys_schema/views/p_s/io_global_by_file_by_bytes.sql
index 38ba6ee45ae..cca00495424 100644
--- a/scripts/sys_schema/views/p_s/io_global_by_file_by_bytes.sql
+++ b/scripts/sys_schema/views/p_s/io_global_by_file_by_bytes.sql
@@ -32,7 +32,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW io_global_by_file_by_bytes (
file,
diff --git a/scripts/sys_schema/views/p_s/io_global_by_file_by_latency.sql b/scripts/sys_schema/views/p_s/io_global_by_file_by_latency.sql
index a02f8f2c2e6..97b0aae97c1 100644
--- a/scripts/sys_schema/views/p_s/io_global_by_file_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/io_global_by_file_by_latency.sql
@@ -32,7 +32,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW io_global_by_file_by_latency (
file,
diff --git a/scripts/sys_schema/views/p_s/io_global_by_wait_by_bytes.sql b/scripts/sys_schema/views/p_s/io_global_by_wait_by_bytes.sql
index 769bbf21df2..edf6b994303 100644
--- a/scripts/sys_schema/views/p_s/io_global_by_wait_by_bytes.sql
+++ b/scripts/sys_schema/views/p_s/io_global_by_wait_by_bytes.sql
@@ -43,7 +43,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW io_global_by_wait_by_bytes (
event_name,
diff --git a/scripts/sys_schema/views/p_s/io_global_by_wait_by_latency.sql b/scripts/sys_schema/views/p_s/io_global_by_wait_by_latency.sql
index 9339c5814b5..5783e98ca4e 100644
--- a/scripts/sys_schema/views/p_s/io_global_by_wait_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/io_global_by_wait_by_latency.sql
@@ -43,7 +43,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW io_global_by_wait_by_latency (
event_name,
diff --git a/scripts/sys_schema/views/p_s/latest_file_io.sql b/scripts/sys_schema/views/p_s/latest_file_io.sql
index 07dc111f1b1..9803cc6cd8b 100644
--- a/scripts/sys_schema/views/p_s/latest_file_io.sql
+++ b/scripts/sys_schema/views/p_s/latest_file_io.sql
@@ -32,7 +32,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW latest_file_io (
thread,
diff --git a/scripts/sys_schema/views/p_s/memory_by_host_by_current_bytes.sql b/scripts/sys_schema/views/p_s/memory_by_host_by_current_bytes.sql
index 63e8759619d..ca6ce2da713 100644
--- a/scripts/sys_schema/views/p_s/memory_by_host_by_current_bytes.sql
+++ b/scripts/sys_schema/views/p_s/memory_by_host_by_current_bytes.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW memory_by_host_by_current_bytes (
host,
diff --git a/scripts/sys_schema/views/p_s/memory_by_thread_by_current_bytes.sql b/scripts/sys_schema/views/p_s/memory_by_thread_by_current_bytes.sql
index 39af4633e7e..6db9d79c434 100644
--- a/scripts/sys_schema/views/p_s/memory_by_thread_by_current_bytes.sql
+++ b/scripts/sys_schema/views/p_s/memory_by_thread_by_current_bytes.sql
@@ -34,7 +34,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW memory_by_thread_by_current_bytes (
thread_id,
diff --git a/scripts/sys_schema/views/p_s/memory_by_user_by_current_bytes.sql b/scripts/sys_schema/views/p_s/memory_by_user_by_current_bytes.sql
index 722cdb65f8b..efb5267efa6 100644
--- a/scripts/sys_schema/views/p_s/memory_by_user_by_current_bytes.sql
+++ b/scripts/sys_schema/views/p_s/memory_by_user_by_current_bytes.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW memory_by_user_by_current_bytes (
user,
diff --git a/scripts/sys_schema/views/p_s/memory_global_by_current_bytes.sql b/scripts/sys_schema/views/p_s/memory_global_by_current_bytes.sql
index 82b501a59a4..c1e9f27e861 100644
--- a/scripts/sys_schema/views/p_s/memory_global_by_current_bytes.sql
+++ b/scripts/sys_schema/views/p_s/memory_global_by_current_bytes.sql
@@ -33,7 +33,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW memory_global_by_current_bytes (
event_name,
diff --git a/scripts/sys_schema/views/p_s/memory_global_total.sql b/scripts/sys_schema/views/p_s/memory_global_total.sql
index 0659f25805c..8d014e9d367 100644
--- a/scripts/sys_schema/views/p_s/memory_global_total.sql
+++ b/scripts/sys_schema/views/p_s/memory_global_total.sql
@@ -28,7 +28,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW memory_global_total (
total_allocated
diff --git a/scripts/sys_schema/views/p_s/metrics.sql b/scripts/sys_schema/views/p_s/metrics.sql
index 009e6bb908c..0fcc5c5ed10 100644
--- a/scripts/sys_schema/views/p_s/metrics.sql
+++ b/scripts/sys_schema/views/p_s/metrics.sql
@@ -74,7 +74,7 @@ DECLARE EXIT HANDLER FOR SQLEXCEPTION BEGIN END;
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW metrics (
Variable_name,
diff --git a/scripts/sys_schema/views/p_s/metrics_56.sql b/scripts/sys_schema/views/p_s/metrics_56.sql
index 0bf9e0ffaeb..79447ae7b02 100644
--- a/scripts/sys_schema/views/p_s/metrics_56.sql
+++ b/scripts/sys_schema/views/p_s/metrics_56.sql
@@ -77,7 +77,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW metrics (
Variable_name,
diff --git a/scripts/sys_schema/views/p_s/processlist.sql b/scripts/sys_schema/views/p_s/processlist.sql
index a85b656f5fb..33e8969f73f 100644
--- a/scripts/sys_schema/views/p_s/processlist.sql
+++ b/scripts/sys_schema/views/p_s/processlist.sql
@@ -46,7 +46,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW processlist (
thd_id,
diff --git a/scripts/sys_schema/views/p_s/processlist_57.sql b/scripts/sys_schema/views/p_s/processlist_57.sql
index 4ac5ac48091..4e4f21ead3f 100644
--- a/scripts/sys_schema/views/p_s/processlist_57.sql
+++ b/scripts/sys_schema/views/p_s/processlist_57.sql
@@ -55,7 +55,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW processlist (
thd_id,
diff --git a/scripts/sys_schema/views/p_s/ps_check_lost_instrumentation.sql b/scripts/sys_schema/views/p_s/ps_check_lost_instrumentation.sql
index 58c5ec7f39f..21d8ecb6c74 100644
--- a/scripts/sys_schema/views/p_s/ps_check_lost_instrumentation.sql
+++ b/scripts/sys_schema/views/p_s/ps_check_lost_instrumentation.sql
@@ -30,7 +30,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW ps_check_lost_instrumentation (
variable_name,
diff --git a/scripts/sys_schema/views/p_s/ps_check_lost_instrumentation_57.sql b/scripts/sys_schema/views/p_s/ps_check_lost_instrumentation_57.sql
index a1c0a29bfbd..25cc829ba30 100644
--- a/scripts/sys_schema/views/p_s/ps_check_lost_instrumentation_57.sql
+++ b/scripts/sys_schema/views/p_s/ps_check_lost_instrumentation_57.sql
@@ -30,7 +30,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW ps_check_lost_instrumentation (
variable_name,
diff --git a/scripts/sys_schema/views/p_s/schema_index_statistics.sql b/scripts/sys_schema/views/p_s/schema_index_statistics.sql
index 1c4785ad8ce..84ce7ead5cf 100644
--- a/scripts/sys_schema/views/p_s/schema_index_statistics.sql
+++ b/scripts/sys_schema/views/p_s/schema_index_statistics.sql
@@ -34,7 +34,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW schema_index_statistics (
table_schema,
diff --git a/scripts/sys_schema/views/p_s/schema_table_lock_waits.sql b/scripts/sys_schema/views/p_s/schema_table_lock_waits.sql
index da4e218d40a..dd293c5b3f3 100644
--- a/scripts/sys_schema/views/p_s/schema_table_lock_waits.sql
+++ b/scripts/sys_schema/views/p_s/schema_table_lock_waits.sql
@@ -43,7 +43,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW schema_table_lock_waits (
object_schema,
diff --git a/scripts/sys_schema/views/p_s/schema_table_statistics.sql b/scripts/sys_schema/views/p_s/schema_table_statistics.sql
index 12a1ae87615..198d2e0ee7c 100644
--- a/scripts/sys_schema/views/p_s/schema_table_statistics.sql
+++ b/scripts/sys_schema/views/p_s/schema_table_statistics.sql
@@ -45,7 +45,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW schema_table_statistics (
table_schema,
diff --git a/scripts/sys_schema/views/p_s/schema_table_statistics_with_buffer.sql b/scripts/sys_schema/views/p_s/schema_table_statistics_with_buffer.sql
index 0b710b1e7ef..acdaefb355f 100644
--- a/scripts/sys_schema/views/p_s/schema_table_statistics_with_buffer.sql
+++ b/scripts/sys_schema/views/p_s/schema_table_statistics_with_buffer.sql
@@ -55,7 +55,7 @@ BEGIN NOT ATOMIC
DECLARE EXIT HANDLER FOR SQLEXCEPTION BEGIN END;
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW schema_table_statistics_with_buffer (
table_schema,
diff --git a/scripts/sys_schema/views/p_s/schema_tables_with_full_table_scans.sql b/scripts/sys_schema/views/p_s/schema_tables_with_full_table_scans.sql
index bc046538e3d..6199d244dd2 100644
--- a/scripts/sys_schema/views/p_s/schema_tables_with_full_table_scans.sql
+++ b/scripts/sys_schema/views/p_s/schema_tables_with_full_table_scans.sql
@@ -33,7 +33,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW schema_tables_with_full_table_scans (
object_schema,
diff --git a/scripts/sys_schema/views/p_s/schema_unused_indexes.sql b/scripts/sys_schema/views/p_s/schema_unused_indexes.sql
index 2eff388c7dd..168f88bbb39 100644
--- a/scripts/sys_schema/views/p_s/schema_unused_indexes.sql
+++ b/scripts/sys_schema/views/p_s/schema_unused_indexes.sql
@@ -38,7 +38,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW schema_unused_indexes (
object_schema,
diff --git a/scripts/sys_schema/views/p_s/session_ssl_status.sql b/scripts/sys_schema/views/p_s/session_ssl_status.sql
index 7915a303208..cb8ce855c45 100644
--- a/scripts/sys_schema/views/p_s/session_ssl_status.sql
+++ b/scripts/sys_schema/views/p_s/session_ssl_status.sql
@@ -16,7 +16,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW session_ssl_status (
thread_id,
diff --git a/scripts/sys_schema/views/p_s/sessions.sql b/scripts/sys_schema/views/p_s/sessions.sql
index b1ed2500df3..94471aabde1 100644
--- a/scripts/sys_schema/views/p_s/sessions.sql
+++ b/scripts/sys_schema/views/p_s/sessions.sql
@@ -55,7 +55,7 @@
--
CREATE OR REPLACE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW session
AS
diff --git a/scripts/sys_schema/views/p_s/statement_analysis.sql b/scripts/sys_schema/views/p_s/statement_analysis.sql
index 6c6f6c38fe8..0d9c9cef32c 100644
--- a/scripts/sys_schema/views/p_s/statement_analysis.sql
+++ b/scripts/sys_schema/views/p_s/statement_analysis.sql
@@ -49,7 +49,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW statement_analysis (
query,
diff --git a/scripts/sys_schema/views/p_s/statements_with_errors_or_warnings.sql b/scripts/sys_schema/views/p_s/statements_with_errors_or_warnings.sql
index d589e8015dc..e5e5e67c7b0 100644
--- a/scripts/sys_schema/views/p_s/statements_with_errors_or_warnings.sql
+++ b/scripts/sys_schema/views/p_s/statements_with_errors_or_warnings.sql
@@ -34,7 +34,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW statements_with_errors_or_warnings (
query,
diff --git a/scripts/sys_schema/views/p_s/statements_with_full_table_scans.sql b/scripts/sys_schema/views/p_s/statements_with_full_table_scans.sql
index 2112feb5a5d..842173645f5 100644
--- a/scripts/sys_schema/views/p_s/statements_with_full_table_scans.sql
+++ b/scripts/sys_schema/views/p_s/statements_with_full_table_scans.sql
@@ -43,7 +43,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW statements_with_full_table_scans (
query,
diff --git a/scripts/sys_schema/views/p_s/statements_with_runtimes_in_95th_percentile.sql b/scripts/sys_schema/views/p_s/statements_with_runtimes_in_95th_percentile.sql
index 8d2c803336c..6e2489ed84c 100644
--- a/scripts/sys_schema/views/p_s/statements_with_runtimes_in_95th_percentile.sql
+++ b/scripts/sys_schema/views/p_s/statements_with_runtimes_in_95th_percentile.sql
@@ -32,7 +32,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW statements_with_runtimes_in_95th_percentile (
query,
diff --git a/scripts/sys_schema/views/p_s/statements_with_sorting.sql b/scripts/sys_schema/views/p_s/statements_with_sorting.sql
index 3c62344f0ca..0216a12ed4d 100644
--- a/scripts/sys_schema/views/p_s/statements_with_sorting.sql
+++ b/scripts/sys_schema/views/p_s/statements_with_sorting.sql
@@ -38,7 +38,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW statements_with_sorting (
query,
diff --git a/scripts/sys_schema/views/p_s/statements_with_temp_tables.sql b/scripts/sys_schema/views/p_s/statements_with_temp_tables.sql
index 198263386e4..3f9dfbc6299 100644
--- a/scripts/sys_schema/views/p_s/statements_with_temp_tables.sql
+++ b/scripts/sys_schema/views/p_s/statements_with_temp_tables.sql
@@ -37,7 +37,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW statements_with_temp_tables (
query,
diff --git a/scripts/sys_schema/views/p_s/user_summary.sql b/scripts/sys_schema/views/p_s/user_summary.sql
index cd9f1235fd6..85f08878972 100644
--- a/scripts/sys_schema/views/p_s/user_summary.sql
+++ b/scripts/sys_schema/views/p_s/user_summary.sql
@@ -30,7 +30,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW user_summary (
user,
diff --git a/scripts/sys_schema/views/p_s/user_summary_57.sql b/scripts/sys_schema/views/p_s/user_summary_57.sql
index 5319748744e..a3147a17714 100644
--- a/scripts/sys_schema/views/p_s/user_summary_57.sql
+++ b/scripts/sys_schema/views/p_s/user_summary_57.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW user_summary (
user,
diff --git a/scripts/sys_schema/views/p_s/user_summary_by_file_io.sql b/scripts/sys_schema/views/p_s/user_summary_by_file_io.sql
index d3aa3294e6a..85862d50ecd 100644
--- a/scripts/sys_schema/views/p_s/user_summary_by_file_io.sql
+++ b/scripts/sys_schema/views/p_s/user_summary_by_file_io.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW user_summary_by_file_io (
user,
diff --git a/scripts/sys_schema/views/p_s/user_summary_by_file_io_type.sql b/scripts/sys_schema/views/p_s/user_summary_by_file_io_type.sql
index 89d76556f92..37b4b14bc8f 100644
--- a/scripts/sys_schema/views/p_s/user_summary_by_file_io_type.sql
+++ b/scripts/sys_schema/views/p_s/user_summary_by_file_io_type.sql
@@ -46,7 +46,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW user_summary_by_file_io_type (
user,
diff --git a/scripts/sys_schema/views/p_s/user_summary_by_stages.sql b/scripts/sys_schema/views/p_s/user_summary_by_stages.sql
index 14cc7e93ac5..ab34a3ee107 100644
--- a/scripts/sys_schema/views/p_s/user_summary_by_stages.sql
+++ b/scripts/sys_schema/views/p_s/user_summary_by_stages.sql
@@ -45,7 +45,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW user_summary_by_stages (
user,
diff --git a/scripts/sys_schema/views/p_s/user_summary_by_statement_latency.sql b/scripts/sys_schema/views/p_s/user_summary_by_statement_latency.sql
index 983572ec234..2c6e0b50ccf 100644
--- a/scripts/sys_schema/views/p_s/user_summary_by_statement_latency.sql
+++ b/scripts/sys_schema/views/p_s/user_summary_by_statement_latency.sql
@@ -30,7 +30,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW user_summary_by_statement_latency (
user,
diff --git a/scripts/sys_schema/views/p_s/user_summary_by_statement_type.sql b/scripts/sys_schema/views/p_s/user_summary_by_statement_type.sql
index f32415fdba6..f9ddc2bb4ff 100644
--- a/scripts/sys_schema/views/p_s/user_summary_by_statement_type.sql
+++ b/scripts/sys_schema/views/p_s/user_summary_by_statement_type.sql
@@ -35,7 +35,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW user_summary_by_statement_type (
user,
diff --git a/scripts/sys_schema/views/p_s/wait_classes_global_by_avg_latency.sql b/scripts/sys_schema/views/p_s/wait_classes_global_by_avg_latency.sql
index 001f946fccd..faee58230a9 100644
--- a/scripts/sys_schema/views/p_s/wait_classes_global_by_avg_latency.sql
+++ b/scripts/sys_schema/views/p_s/wait_classes_global_by_avg_latency.sql
@@ -33,7 +33,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW wait_classes_global_by_avg_latency (
event_class,
diff --git a/scripts/sys_schema/views/p_s/wait_classes_global_by_latency.sql b/scripts/sys_schema/views/p_s/wait_classes_global_by_latency.sql
index b9172981cbc..5675c3f589a 100644
--- a/scripts/sys_schema/views/p_s/wait_classes_global_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/wait_classes_global_by_latency.sql
@@ -33,7 +33,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW wait_classes_global_by_latency (
event_class,
diff --git a/scripts/sys_schema/views/p_s/waits_by_host_by_latency.sql b/scripts/sys_schema/views/p_s/waits_by_host_by_latency.sql
index 49e6d78dc95..5587fee210f 100644
--- a/scripts/sys_schema/views/p_s/waits_by_host_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/waits_by_host_by_latency.sql
@@ -32,7 +32,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW waits_by_host_by_latency (
host,
diff --git a/scripts/sys_schema/views/p_s/waits_by_user_by_latency.sql b/scripts/sys_schema/views/p_s/waits_by_user_by_latency.sql
index bef46ef23d9..5a6a618ecc6 100644
--- a/scripts/sys_schema/views/p_s/waits_by_user_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/waits_by_user_by_latency.sql
@@ -42,7 +42,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW waits_by_user_by_latency (
user,
diff --git a/scripts/sys_schema/views/p_s/waits_global_by_latency.sql b/scripts/sys_schema/views/p_s/waits_global_by_latency.sql
index 842c900fc07..a41be3b1448 100644
--- a/scripts/sys_schema/views/p_s/waits_global_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/waits_global_by_latency.sql
@@ -32,7 +32,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW waits_global_by_latency (
events,
diff --git a/scripts/sys_schema/views/p_s/x_host_summary.sql b/scripts/sys_schema/views/p_s/x_host_summary.sql
index 23274c4fc16..87d415b0c8d 100644
--- a/scripts/sys_schema/views/p_s/x_host_summary.sql
+++ b/scripts/sys_schema/views/p_s/x_host_summary.sql
@@ -30,7 +30,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$host_summary (
host,
diff --git a/scripts/sys_schema/views/p_s/x_host_summary_57.sql b/scripts/sys_schema/views/p_s/x_host_summary_57.sql
index 06015ae8e09..5a741adeaeb 100644
--- a/scripts/sys_schema/views/p_s/x_host_summary_57.sql
+++ b/scripts/sys_schema/views/p_s/x_host_summary_57.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$host_summary (
host,
diff --git a/scripts/sys_schema/views/p_s/x_host_summary_by_file_io.sql b/scripts/sys_schema/views/p_s/x_host_summary_by_file_io.sql
index 55b488e953a..6e1d727a0f9 100644
--- a/scripts/sys_schema/views/p_s/x_host_summary_by_file_io.sql
+++ b/scripts/sys_schema/views/p_s/x_host_summary_by_file_io.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$host_summary_by_file_io (
host,
diff --git a/scripts/sys_schema/views/p_s/x_host_summary_by_file_io_type.sql b/scripts/sys_schema/views/p_s/x_host_summary_by_file_io_type.sql
index 55c90690604..e272732dd09 100644
--- a/scripts/sys_schema/views/p_s/x_host_summary_by_file_io_type.sql
+++ b/scripts/sys_schema/views/p_s/x_host_summary_by_file_io_type.sql
@@ -46,7 +46,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$host_summary_by_file_io_type (
host,
diff --git a/scripts/sys_schema/views/p_s/x_host_summary_by_stages.sql b/scripts/sys_schema/views/p_s/x_host_summary_by_stages.sql
index 6a4268c998d..801d338e2aa 100644
--- a/scripts/sys_schema/views/p_s/x_host_summary_by_stages.sql
+++ b/scripts/sys_schema/views/p_s/x_host_summary_by_stages.sql
@@ -45,7 +45,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$host_summary_by_stages (
host,
diff --git a/scripts/sys_schema/views/p_s/x_host_summary_by_statement_latency.sql b/scripts/sys_schema/views/p_s/x_host_summary_by_statement_latency.sql
index e7bc0e9f23c..30a6e3900da 100644
--- a/scripts/sys_schema/views/p_s/x_host_summary_by_statement_latency.sql
+++ b/scripts/sys_schema/views/p_s/x_host_summary_by_statement_latency.sql
@@ -30,7 +30,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$host_summary_by_statement_latency (
host,
diff --git a/scripts/sys_schema/views/p_s/x_host_summary_by_statement_type.sql b/scripts/sys_schema/views/p_s/x_host_summary_by_statement_type.sql
index 49c830343e9..72b75b9c196 100644
--- a/scripts/sys_schema/views/p_s/x_host_summary_by_statement_type.sql
+++ b/scripts/sys_schema/views/p_s/x_host_summary_by_statement_type.sql
@@ -35,7 +35,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$host_summary_by_statement_type (
host,
diff --git a/scripts/sys_schema/views/p_s/x_io_by_thread_by_latency.sql b/scripts/sys_schema/views/p_s/x_io_by_thread_by_latency.sql
index bfc32100b55..5e02f528f3d 100644
--- a/scripts/sys_schema/views/p_s/x_io_by_thread_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/x_io_by_thread_by_latency.sql
@@ -38,7 +38,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$io_by_thread_by_latency (
user,
diff --git a/scripts/sys_schema/views/p_s/x_io_global_by_file_by_bytes.sql b/scripts/sys_schema/views/p_s/x_io_global_by_file_by_bytes.sql
index 4f2e0f3ca92..d508deb117f 100644
--- a/scripts/sys_schema/views/p_s/x_io_global_by_file_by_bytes.sql
+++ b/scripts/sys_schema/views/p_s/x_io_global_by_file_by_bytes.sql
@@ -32,7 +32,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$io_global_by_file_by_bytes (
file,
diff --git a/scripts/sys_schema/views/p_s/x_io_global_by_file_by_latency.sql b/scripts/sys_schema/views/p_s/x_io_global_by_file_by_latency.sql
index 60396081e5d..b1229ff4d2e 100644
--- a/scripts/sys_schema/views/p_s/x_io_global_by_file_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/x_io_global_by_file_by_latency.sql
@@ -32,7 +32,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$io_global_by_file_by_latency (
file,
diff --git a/scripts/sys_schema/views/p_s/x_io_global_by_wait_by_bytes.sql b/scripts/sys_schema/views/p_s/x_io_global_by_wait_by_bytes.sql
index 21072eb2aef..1ec6e9ceb92 100644
--- a/scripts/sys_schema/views/p_s/x_io_global_by_wait_by_bytes.sql
+++ b/scripts/sys_schema/views/p_s/x_io_global_by_wait_by_bytes.sql
@@ -38,7 +38,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$io_global_by_wait_by_bytes (
event_name,
diff --git a/scripts/sys_schema/views/p_s/x_io_global_by_wait_by_latency.sql b/scripts/sys_schema/views/p_s/x_io_global_by_wait_by_latency.sql
index 3f72c7ea5f1..23fb1f81f99 100644
--- a/scripts/sys_schema/views/p_s/x_io_global_by_wait_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/x_io_global_by_wait_by_latency.sql
@@ -44,7 +44,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$io_global_by_wait_by_latency (
event_name,
diff --git a/scripts/sys_schema/views/p_s/x_latest_file_io.sql b/scripts/sys_schema/views/p_s/x_latest_file_io.sql
index 59caaac25cf..7cef7b8922f 100644
--- a/scripts/sys_schema/views/p_s/x_latest_file_io.sql
+++ b/scripts/sys_schema/views/p_s/x_latest_file_io.sql
@@ -32,7 +32,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$latest_file_io (
thread,
diff --git a/scripts/sys_schema/views/p_s/x_memory_by_host_by_current_bytes.sql b/scripts/sys_schema/views/p_s/x_memory_by_host_by_current_bytes.sql
index 62ffe620e9a..1fc381978e1 100644
--- a/scripts/sys_schema/views/p_s/x_memory_by_host_by_current_bytes.sql
+++ b/scripts/sys_schema/views/p_s/x_memory_by_host_by_current_bytes.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$memory_by_host_by_current_bytes (
host,
diff --git a/scripts/sys_schema/views/p_s/x_memory_by_thread_by_current_bytes.sql b/scripts/sys_schema/views/p_s/x_memory_by_thread_by_current_bytes.sql
index 8df6489236d..3f4098bdbc5 100644
--- a/scripts/sys_schema/views/p_s/x_memory_by_thread_by_current_bytes.sql
+++ b/scripts/sys_schema/views/p_s/x_memory_by_thread_by_current_bytes.sql
@@ -34,7 +34,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$memory_by_thread_by_current_bytes (
thread_id,
diff --git a/scripts/sys_schema/views/p_s/x_memory_by_user_by_current_bytes.sql b/scripts/sys_schema/views/p_s/x_memory_by_user_by_current_bytes.sql
index 0ac80822835..794fc5689bd 100644
--- a/scripts/sys_schema/views/p_s/x_memory_by_user_by_current_bytes.sql
+++ b/scripts/sys_schema/views/p_s/x_memory_by_user_by_current_bytes.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$memory_by_user_by_current_bytes (
user,
diff --git a/scripts/sys_schema/views/p_s/x_memory_global_by_current_bytes.sql b/scripts/sys_schema/views/p_s/x_memory_global_by_current_bytes.sql
index 54d028ba24b..986c44529f1 100644
--- a/scripts/sys_schema/views/p_s/x_memory_global_by_current_bytes.sql
+++ b/scripts/sys_schema/views/p_s/x_memory_global_by_current_bytes.sql
@@ -33,7 +33,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$memory_global_by_current_bytes (
event_name,
diff --git a/scripts/sys_schema/views/p_s/x_memory_global_total.sql b/scripts/sys_schema/views/p_s/x_memory_global_total.sql
index 46c7db7a245..9fe7e7b1989 100644
--- a/scripts/sys_schema/views/p_s/x_memory_global_total.sql
+++ b/scripts/sys_schema/views/p_s/x_memory_global_total.sql
@@ -28,7 +28,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$memory_global_total (
total_allocated
diff --git a/scripts/sys_schema/views/p_s/x_processlist.sql b/scripts/sys_schema/views/p_s/x_processlist.sql
index 24722e22d95..8f39918d311 100644
--- a/scripts/sys_schema/views/p_s/x_processlist.sql
+++ b/scripts/sys_schema/views/p_s/x_processlist.sql
@@ -46,7 +46,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$processlist (
thd_id,
diff --git a/scripts/sys_schema/views/p_s/x_processlist_57.sql b/scripts/sys_schema/views/p_s/x_processlist_57.sql
index 77f625d8db2..cfea37a0a56 100644
--- a/scripts/sys_schema/views/p_s/x_processlist_57.sql
+++ b/scripts/sys_schema/views/p_s/x_processlist_57.sql
@@ -56,7 +56,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$processlist (
thd_id,
diff --git a/scripts/sys_schema/views/p_s/x_ps_digest_95th_percentile_by_avg_us.sql b/scripts/sys_schema/views/p_s/x_ps_digest_95th_percentile_by_avg_us.sql
index 7a0beba59da..de747b87ad5 100644
--- a/scripts/sys_schema/views/p_s/x_ps_digest_95th_percentile_by_avg_us.sql
+++ b/scripts/sys_schema/views/p_s/x_ps_digest_95th_percentile_by_avg_us.sql
@@ -29,7 +29,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$ps_digest_95th_percentile_by_avg_us (
avg_us,
diff --git a/scripts/sys_schema/views/p_s/x_ps_digest_avg_latency_distribution.sql b/scripts/sys_schema/views/p_s/x_ps_digest_avg_latency_distribution.sql
index ce3e1b9ce9b..7a0b468fff6 100644
--- a/scripts/sys_schema/views/p_s/x_ps_digest_avg_latency_distribution.sql
+++ b/scripts/sys_schema/views/p_s/x_ps_digest_avg_latency_distribution.sql
@@ -21,7 +21,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$ps_digest_avg_latency_distribution (
cnt,
diff --git a/scripts/sys_schema/views/p_s/x_ps_schema_table_statistics_io.sql b/scripts/sys_schema/views/p_s/x_ps_schema_table_statistics_io.sql
index 1043b65d6a2..c2c36cae6e5 100644
--- a/scripts/sys_schema/views/p_s/x_ps_schema_table_statistics_io.sql
+++ b/scripts/sys_schema/views/p_s/x_ps_schema_table_statistics_io.sql
@@ -36,7 +36,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$ps_schema_table_statistics_io (
table_schema,
diff --git a/scripts/sys_schema/views/p_s/x_schema_index_statistics.sql b/scripts/sys_schema/views/p_s/x_schema_index_statistics.sql
index 8a6168962cf..1ef5821f29f 100644
--- a/scripts/sys_schema/views/p_s/x_schema_index_statistics.sql
+++ b/scripts/sys_schema/views/p_s/x_schema_index_statistics.sql
@@ -34,7 +34,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$schema_index_statistics (
table_schema,
diff --git a/scripts/sys_schema/views/p_s/x_schema_table_lock_waits.sql b/scripts/sys_schema/views/p_s/x_schema_table_lock_waits.sql
index 930ff46cfc0..0cbf84cf6df 100644
--- a/scripts/sys_schema/views/p_s/x_schema_table_lock_waits.sql
+++ b/scripts/sys_schema/views/p_s/x_schema_table_lock_waits.sql
@@ -43,7 +43,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$schema_table_lock_waits (
object_schema,
diff --git a/scripts/sys_schema/views/p_s/x_schema_table_statistics.sql b/scripts/sys_schema/views/p_s/x_schema_table_statistics.sql
index 77103d40a63..b131200c566 100644
--- a/scripts/sys_schema/views/p_s/x_schema_table_statistics.sql
+++ b/scripts/sys_schema/views/p_s/x_schema_table_statistics.sql
@@ -45,7 +45,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$schema_table_statistics (
table_schema,
diff --git a/scripts/sys_schema/views/p_s/x_schema_table_statistics_with_buffer.sql b/scripts/sys_schema/views/p_s/x_schema_table_statistics_with_buffer.sql
index e9b48f390a8..a573c288406 100644
--- a/scripts/sys_schema/views/p_s/x_schema_table_statistics_with_buffer.sql
+++ b/scripts/sys_schema/views/p_s/x_schema_table_statistics_with_buffer.sql
@@ -56,7 +56,7 @@ DECLARE EXIT HANDLER FOR SQLEXCEPTION BEGIN END;
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$schema_table_statistics_with_buffer (
table_schema,
diff --git a/scripts/sys_schema/views/p_s/x_schema_tables_with_full_table_scans.sql b/scripts/sys_schema/views/p_s/x_schema_tables_with_full_table_scans.sql
index a9b585fa9a9..d5868bf1eea 100644
--- a/scripts/sys_schema/views/p_s/x_schema_tables_with_full_table_scans.sql
+++ b/scripts/sys_schema/views/p_s/x_schema_tables_with_full_table_scans.sql
@@ -33,7 +33,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$schema_tables_with_full_table_scans (
object_schema,
diff --git a/scripts/sys_schema/views/p_s/x_sessions.sql b/scripts/sys_schema/views/p_s/x_sessions.sql
index 841682f3e3f..e320777ff7a 100644
--- a/scripts/sys_schema/views/p_s/x_sessions.sql
+++ b/scripts/sys_schema/views/p_s/x_sessions.sql
@@ -55,7 +55,7 @@
--
CREATE OR REPLACE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$session
AS
diff --git a/scripts/sys_schema/views/p_s/x_statement_analysis.sql b/scripts/sys_schema/views/p_s/x_statement_analysis.sql
index cb7071d7252..754c073c420 100644
--- a/scripts/sys_schema/views/p_s/x_statement_analysis.sql
+++ b/scripts/sys_schema/views/p_s/x_statement_analysis.sql
@@ -49,7 +49,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$statement_analysis (
query,
diff --git a/scripts/sys_schema/views/p_s/x_statements_with_errors_or_warnings.sql b/scripts/sys_schema/views/p_s/x_statements_with_errors_or_warnings.sql
index d1fd6878676..aa87cf6e849 100644
--- a/scripts/sys_schema/views/p_s/x_statements_with_errors_or_warnings.sql
+++ b/scripts/sys_schema/views/p_s/x_statements_with_errors_or_warnings.sql
@@ -34,7 +34,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$statements_with_errors_or_warnings (
query,
diff --git a/scripts/sys_schema/views/p_s/x_statements_with_full_table_scans.sql b/scripts/sys_schema/views/p_s/x_statements_with_full_table_scans.sql
index d78123b52d1..cd4d653f016 100644
--- a/scripts/sys_schema/views/p_s/x_statements_with_full_table_scans.sql
+++ b/scripts/sys_schema/views/p_s/x_statements_with_full_table_scans.sql
@@ -43,7 +43,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$statements_with_full_table_scans (
query,
diff --git a/scripts/sys_schema/views/p_s/x_statements_with_runtimes_in_95th_percentile.sql b/scripts/sys_schema/views/p_s/x_statements_with_runtimes_in_95th_percentile.sql
index fbb3deb6d89..6281d375c21 100644
--- a/scripts/sys_schema/views/p_s/x_statements_with_runtimes_in_95th_percentile.sql
+++ b/scripts/sys_schema/views/p_s/x_statements_with_runtimes_in_95th_percentile.sql
@@ -40,7 +40,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$statements_with_runtimes_in_95th_percentile (
query,
diff --git a/scripts/sys_schema/views/p_s/x_statements_with_sorting.sql b/scripts/sys_schema/views/p_s/x_statements_with_sorting.sql
index 743083c582b..a168d19d420 100644
--- a/scripts/sys_schema/views/p_s/x_statements_with_sorting.sql
+++ b/scripts/sys_schema/views/p_s/x_statements_with_sorting.sql
@@ -38,7 +38,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$statements_with_sorting (
query,
diff --git a/scripts/sys_schema/views/p_s/x_statements_with_temp_tables.sql b/scripts/sys_schema/views/p_s/x_statements_with_temp_tables.sql
index 876286997d6..d8f5fa2e614 100644
--- a/scripts/sys_schema/views/p_s/x_statements_with_temp_tables.sql
+++ b/scripts/sys_schema/views/p_s/x_statements_with_temp_tables.sql
@@ -37,7 +37,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$statements_with_temp_tables (
query,
diff --git a/scripts/sys_schema/views/p_s/x_user_summary.sql b/scripts/sys_schema/views/p_s/x_user_summary.sql
index 797b0ee0950..8c9f4b3b998 100644
--- a/scripts/sys_schema/views/p_s/x_user_summary.sql
+++ b/scripts/sys_schema/views/p_s/x_user_summary.sql
@@ -30,7 +30,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$user_summary (
user,
diff --git a/scripts/sys_schema/views/p_s/x_user_summary_57.sql b/scripts/sys_schema/views/p_s/x_user_summary_57.sql
index 0125a02469b..9bcaa781919 100644
--- a/scripts/sys_schema/views/p_s/x_user_summary_57.sql
+++ b/scripts/sys_schema/views/p_s/x_user_summary_57.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$user_summary (
user,
diff --git a/scripts/sys_schema/views/p_s/x_user_summary_by_file_io.sql b/scripts/sys_schema/views/p_s/x_user_summary_by_file_io.sql
index 1c17e564888..0fe1f55f95d 100644
--- a/scripts/sys_schema/views/p_s/x_user_summary_by_file_io.sql
+++ b/scripts/sys_schema/views/p_s/x_user_summary_by_file_io.sql
@@ -31,7 +31,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$user_summary_by_file_io (
user,
diff --git a/scripts/sys_schema/views/p_s/x_user_summary_by_file_io_type.sql b/scripts/sys_schema/views/p_s/x_user_summary_by_file_io_type.sql
index 51035f2a6de..6705ae97078 100644
--- a/scripts/sys_schema/views/p_s/x_user_summary_by_file_io_type.sql
+++ b/scripts/sys_schema/views/p_s/x_user_summary_by_file_io_type.sql
@@ -46,7 +46,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$user_summary_by_file_io_type (
user,
diff --git a/scripts/sys_schema/views/p_s/x_user_summary_by_stages.sql b/scripts/sys_schema/views/p_s/x_user_summary_by_stages.sql
index 816d5ae886d..1e94d6db1f5 100644
--- a/scripts/sys_schema/views/p_s/x_user_summary_by_stages.sql
+++ b/scripts/sys_schema/views/p_s/x_user_summary_by_stages.sql
@@ -45,7 +45,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$user_summary_by_stages (
user,
diff --git a/scripts/sys_schema/views/p_s/x_user_summary_by_statement_latency.sql b/scripts/sys_schema/views/p_s/x_user_summary_by_statement_latency.sql
index 1f8da5fad50..5bc520b70a8 100644
--- a/scripts/sys_schema/views/p_s/x_user_summary_by_statement_latency.sql
+++ b/scripts/sys_schema/views/p_s/x_user_summary_by_statement_latency.sql
@@ -30,7 +30,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$user_summary_by_statement_latency (
user,
diff --git a/scripts/sys_schema/views/p_s/x_user_summary_by_statement_type.sql b/scripts/sys_schema/views/p_s/x_user_summary_by_statement_type.sql
index e06debe5777..e2c2c5e7341 100644
--- a/scripts/sys_schema/views/p_s/x_user_summary_by_statement_type.sql
+++ b/scripts/sys_schema/views/p_s/x_user_summary_by_statement_type.sql
@@ -35,7 +35,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$user_summary_by_statement_type (
user,
diff --git a/scripts/sys_schema/views/p_s/x_wait_classes_global_by_avg_latency.sql b/scripts/sys_schema/views/p_s/x_wait_classes_global_by_avg_latency.sql
index ad77c530ff5..48dabe51336 100644
--- a/scripts/sys_schema/views/p_s/x_wait_classes_global_by_avg_latency.sql
+++ b/scripts/sys_schema/views/p_s/x_wait_classes_global_by_avg_latency.sql
@@ -33,7 +33,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$wait_classes_global_by_avg_latency (
event_class,
diff --git a/scripts/sys_schema/views/p_s/x_wait_classes_global_by_latency.sql b/scripts/sys_schema/views/p_s/x_wait_classes_global_by_latency.sql
index 63c7c040a87..c9ac506974c 100644
--- a/scripts/sys_schema/views/p_s/x_wait_classes_global_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/x_wait_classes_global_by_latency.sql
@@ -33,7 +33,7 @@
CREATE OR REPLACE
ALGORITHM = TEMPTABLE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$wait_classes_global_by_latency (
event_class,
diff --git a/scripts/sys_schema/views/p_s/x_waits_by_host_by_latency.sql b/scripts/sys_schema/views/p_s/x_waits_by_host_by_latency.sql
index 80c69a799c9..c6f55f90266 100644
--- a/scripts/sys_schema/views/p_s/x_waits_by_host_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/x_waits_by_host_by_latency.sql
@@ -32,7 +32,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$waits_by_host_by_latency (
host,
diff --git a/scripts/sys_schema/views/p_s/x_waits_by_user_by_latency.sql b/scripts/sys_schema/views/p_s/x_waits_by_user_by_latency.sql
index d541f77c96f..42f428598c7 100644
--- a/scripts/sys_schema/views/p_s/x_waits_by_user_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/x_waits_by_user_by_latency.sql
@@ -42,7 +42,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$waits_by_user_by_latency (
user,
diff --git a/scripts/sys_schema/views/p_s/x_waits_global_by_latency.sql b/scripts/sys_schema/views/p_s/x_waits_global_by_latency.sql
index b131719d4a6..9b3ff819259 100644
--- a/scripts/sys_schema/views/p_s/x_waits_global_by_latency.sql
+++ b/scripts/sys_schema/views/p_s/x_waits_global_by_latency.sql
@@ -32,7 +32,7 @@
CREATE OR REPLACE
ALGORITHM = MERGE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW x$waits_global_by_latency (
events,
diff --git a/scripts/sys_schema/views/version.sql b/scripts/sys_schema/views/version.sql
index e7f7ef398ef..a25b53151d2 100644
--- a/scripts/sys_schema/views/version.sql
+++ b/scripts/sys_schema/views/version.sql
@@ -27,7 +27,7 @@
--
CREATE OR REPLACE
- DEFINER = 'root'@'localhost'
+ DEFINER = 'mariadb.sys'@'localhost'
SQL SECURITY INVOKER
VIEW version (
sys_version,