首页 > 数据库 >proxysql安装与配置

proxysql安装与配置

时间:2023-04-17 15:01:06浏览次数:67  
标签:src pic monitor admin 配置 proxysql mysql query 安装

#####################

proxysql安装与配置_sql

 

 

proxysql安装与配置_perl_02

 

 

安装包类型:

源码包

rpm安装包

免编译二进制

 

 perl-CPAN

 

 

 make后报错:

cc -std=gnu11 -Wall -Wextra -Wsign-compare -Wundef -Wno-format-zero-length -pipe -g3 -fvisibility=hidden -O3 -funroll-loops -c -D_GNU_SOURCE -D_REENTRANT -Iinclude -Iinclude -o src/witness.o src/witness.c
g++ -Wall -Wextra -g3 -fvisibility=hidden -O3 -c -D_GNU_SOURCE -D_REENTRANT -Iinclude -Iinclude -o src/jemalloc_cpp.o src/jemalloc_cpp.cpp
ar crus lib/libjemalloc.a src/jemalloc.o src/arena.o src/background_thread.o src/base.o src/bin.o src/bitmap.o src/ckh.o src/ctl.o src/div.o src/extent.o src/extent_dss.o src/extent_mmap.o src/hash.o src/hook.o src/large.o src/log.o src/malloc_io.o src/mutex.o src/mutex_pool.o 
src/nstime.o src/pages.o src/prng.o src/prof.o src/rtree.o src/stats.o src/sc.o src/sz.o src/tcache.o src/test_hooks.o src/ticker.o src/tsd.o src/witness.o src/jemalloc_cpp.o
ar crus lib/libjemalloc_pic.a src/jemalloc.pic.o src/arena.pic.o src/background_thread.pic.o src/base.pic.o src/bin.pic.o src/bitmap.pic.o src/ckh.pic.o src/ctl.pic.o src/div.pic.o src/extent.pic.o src/extent_dss.pic.o src/extent_mmap.pic.o src/hash.pic.o src/hook.pic.o 
src/large.pic.o src/log.pic.o src/malloc_io.pic.o src/mutex.pic.o src/mutex_pool.pic.o src/nstime.pic.o src/pages.pic.o src/prng.pic.o src/prof.pic.o src/rtree.pic.o src/stats.pic.o src/sc.pic.o src/sz.pic.o src/tcache.pic.o src/test_hooks.pic.o src/ticker.pic.o src/tsd.pic.o src/witness.pic.o src/jemalloc_cpp.pic.o  
make[2]: Leaving directory '/data/soft/proxysql/deps/jemalloc/jemalloc-5.2.0'
cd libssl && rm -rf openssl-openssl-*/ openssl-3*/ || true
cd libssl && tar -zxf openssl-*.tar.gz
cd libssl/openssl && ./config no-ssl3 no-tests
Can't locate IPC/Cmd.pm in @INC (you may need to install the IPC::Cmd module) (@INC contains: /data/soft/proxysql/deps/libssl/openssl-3.0.8/util/perl /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 
/usr/share/perl5 /data/soft/proxysql/deps/libssl/openssl-3.0.8/external/perl/Text-Template-1.56/lib) at /data/soft/proxysql/deps/libssl/openssl-3.0.8/util/perl/OpenSSL/config.pm line 19.
BEGIN failed--compilation aborted at /data/soft/proxysql/deps/libssl/openssl-3.0.8/util/perl/OpenSSL/config.pm line 19.
Compilation failed in require at /data/soft/proxysql/deps/libssl/openssl/Configure line 23.
BEGIN failed--compilation aborted at /data/soft/proxysql/deps/libssl/openssl/Configure line 23.
make[1]: *** [Makefile:88: libssl/openssl/libssl.a] Error 2
make[1]: Leaving directory '/data/soft/proxysql/deps'
make: *** [Makefile:101: build_deps] Error 2

 


 

 

配置详解:

重要说明:更改在加载到 RUNTIME 之前不会被激活,并且任何未保存到 DISK 的更改在 ProxySQL 重新启动后将不可用。

proxysql安装与配置_sql_03

 

 

proxysql安装与配置_sql_04

 

 

proxysql安装与配置_sql_05

 

 

 

 

proxysql安装与配置_mysql_06

 

 

 

 

proxysql安装与配置_sql_07

 

 

 

 

 

mysql> SELECT * FROM global_variables ;
+----------------------------------------------------------------------+--------------------------------------------+
| variable_name                                                        | variable_value                             |
+----------------------------------------------------------------------+--------------------------------------------+
| mysql-default_charset                                                | utf8                                       |
| mysql-default_collation_connection                                   | utf8_general_ci                            |
| mysql-shun_on_failures                                               | 5                                          |
| mysql-shun_recovery_time_sec                                         | 10                                         |
| mysql-unshun_algorithm                                               | 0                                          |
| mysql-query_retries_on_failure                                       | 1                                          |
| mysql-client_host_cache_size                                         | 0                                          |
| mysql-client_host_error_counts                                       | 0                                          |
| mysql-connect_retries_delay                                          | 1                                          |
| mysql-connection_delay_multiplex_ms                                  | 0                                          |
| mysql-connection_max_age_ms                                          | 0                                          |
| mysql-connect_timeout_client                                         | 10000                                      |
| mysql-connect_timeout_server_max                                     | 10000                                      |
| mysql-enable_client_deprecate_eof                                    | true                                       |
| mysql-enable_server_deprecate_eof                                    | true                                       |
| mysql-enable_load_data_local_infile                                  | false                                      |
| mysql-eventslog_filename                                             |                                            |
| mysql-eventslog_filesize                                             | 104857600                                  |
| mysql-eventslog_default_log                                          | 0                                          |
| mysql-eventslog_format                                               | 1                                          |
| mysql-auditlog_filename                                              |                                            |
| mysql-auditlog_filesize                                              | 104857600                                  |
| mysql-handle_unknown_charset                                         | 1                                          |
| mysql-free_connections_pct                                           | 10                                         |
| mysql-connection_warming                                             | false                                      |
| mysql-session_idle_ms                                                | 1                                          |
| mysql-have_ssl                                                       | false                                      |
| mysql-log_mysql_warnings_enabled                                     | false                                      |
| mysql-monitor_enabled                                                | true                                       |
| mysql-monitor_connect_timeout                                        | 600                                        |
| mysql-monitor_ping_max_failures                                      | 3                                          |
| mysql-monitor_ping_timeout                                           | 1000                                       |
| mysql-monitor_read_only_max_timeout_count                            | 3                                          |
| mysql-monitor_replication_lag_group_by_host                          | false                                      |
| mysql-monitor_replication_lag_interval                               | 10000                                      |
| mysql-monitor_replication_lag_timeout                                | 1000                                       |
| mysql-monitor_replication_lag_count                                  | 1                                          |
| mysql-monitor_groupreplication_healthcheck_interval                  | 5000                                       |
| mysql-monitor_groupreplication_healthcheck_timeout                   | 800                                        |
| mysql-monitor_groupreplication_healthcheck_max_timeout_count         | 3                                          |
| mysql-monitor_groupreplication_max_transactions_behind_count         | 3                                          |
| mysql-monitor_groupreplication_max_transactions_behind_for_read_only | 1                                          |
| mysql-monitor_galera_healthcheck_interval                            | 5000                                       |
| mysql-monitor_galera_healthcheck_timeout                             | 800                                        |
| mysql-monitor_galera_healthcheck_max_timeout_count                   | 3                                          |
| mysql-monitor_replication_lag_use_percona_heartbeat                  |                                            |
| mysql-monitor_query_interval                                         | 60000                                      |
| mysql-monitor_query_timeout                                          | 100                                        |
| mysql-monitor_slave_lag_when_null                                    | 60                                         |
| mysql-monitor_threads_min                                            | 8                                          |
| mysql-monitor_threads_max                                            | 128                                        |
| mysql-monitor_threads_queue_maxsize                                  | 128                                        |
| mysql-monitor_local_dns_cache_ttl                                    | 300000                                     |
| mysql-monitor_local_dns_cache_refresh_interval                       | 60000                                      |
| mysql-monitor_local_dns_resolver_queue_maxsize                       | 128                                        |
| mysql-monitor_wait_timeout                                           | true                                       |
| mysql-monitor_writer_is_also_reader                                  | true                                       |
| mysql-max_allowed_packet                                             | 67108864                                   |
| mysql-tcp_keepalive_time                                             | 0                                          |
| mysql-use_tcp_keepalive                                              | false                                      |
| mysql-automatic_detect_sqli                                          | false                                      |
| mysql-firewall_whitelist_enabled                                     | false                                      |
| mysql-firewall_whitelist_errormsg                                    | Firewall blocked this query                |
| mysql-throttle_connections_per_sec_to_hostgroup                      | 1000000                                    |
| mysql-max_transaction_idle_time                                      | 14400000                                   |
| mysql-max_transaction_time                                           | 14400000                                   |
| mysql-multiplexing                                                   | true                                       |
| mysql-log_unhealthy_connections                                      | true                                       |
| mysql-enforce_autocommit_on_reads                                    | false                                      |
| mysql-autocommit_false_not_reusable                                  | false                                      |
| mysql-autocommit_false_is_transaction                                | false                                      |
| mysql-verbose_query_error                                            | false                                      |
| mysql-hostgroup_manager_verbose                                      | 1                                          |
| mysql-binlog_reader_connect_retry_msec                               | 3000                                       |
| mysql-threshold_query_length                                         | 524288                                     |
| mysql-threshold_resultset_size                                       | 4194304                                    |
| mysql-query_digests_max_digest_length                                | 2048                                       |
| mysql-query_digests_max_query_length                                 | 65000                                      |
| mysql-query_digests_grouping_limit                                   | 3                                          |
| mysql-query_digests_groups_grouping_limit                            | 0                                          |
| mysql-wait_timeout                                                   | 28800000                                   |
| mysql-throttle_max_bytes_per_second_to_client                        | 0                                          |
| mysql-throttle_ratio_server_to_client                                | 0                                          |
| mysql-max_stmts_per_connection                                       | 20                                         |
| mysql-max_stmts_cache                                                | 10000                                      |
| mysql-mirror_max_concurrency                                         | 16                                         |
| mysql-mirror_max_queue_length                                        | 32000                                      |
| mysql-default_max_latency_ms                                         | 1000                                       |
| mysql-query_processor_iterations                                     | 0                                          |
| mysql-query_processor_regex                                          | 1                                          |
| mysql-set_query_lock_on_hostgroup                                    | 1                                          |
| mysql-reset_connection_algorithm                                     | 2                                          |
| mysql-auto_increment_delay_multiplex                                 | 5                                          |
| mysql-auto_increment_delay_multiplex_timeout_ms                      | 10000                                      |
| mysql-long_query_time                                                | 1000                                       |
| mysql-query_cache_size_MB                                            | 256                                        |
| mysql-query_cache_soft_ttl_pct                                       | 0                                          |
| mysql-poll_timeout_on_failure                                        | 100                                        |
| mysql-server_capabilities                                            | 569867                                     |
| mysql-keep_multiplexing_variables                                    | tx_isolation,transaction_isolation,version |
| mysql-kill_backend_connection_when_disconnect                        | true                                       |
| mysql-client_session_track_gtid                                      | true                                       |
| mysql-session_idle_show_processlist                                  | true                                       |
| mysql-show_processlist_extended                                      | 0                                          |
| mysql-query_digests                                                  | true                                       |
| mysql-query_digests_lowercase                                        | false                                      |
| mysql-query_digests_replace_null                                     | false                                      |
| mysql-query_digests_no_digits                                        | false                                      |
| mysql-query_digests_normalize_digest_text                            | false                                      |
| mysql-query_digests_track_hostname                                   | false                                      |
| mysql-query_digests_keep_comment                                     | false                                      |
| mysql-parse_failure_logs_digest                                      | false                                      |
| mysql-servers_stats                                                  | true                                       |
| mysql-default_reconnect                                              | true                                       |
| mysql-ssl_p2s_ca                                                     |                                            |
| mysql-ssl_p2s_capath                                                 |                                            |
| mysql-ssl_p2s_cert                                                   |                                            |
| mysql-ssl_p2s_key                                                    |                                            |
| mysql-ssl_p2s_cipher                                                 |                                            |
| mysql-ssl_p2s_crl                                                    |                                            |
| mysql-ssl_p2s_crlpath                                                |                                            |
| mysql-init_connect                                                   |                                            |
| mysql-ldap_user_variable                                             |                                            |
| mysql-add_ldap_user_comment                                          |                                            |
| mysql-default_tx_isolation                                           | READ-COMMITTED                             |
| mysql-default_session_track_gtids                                    | OFF                                        |
| mysql-connpoll_reset_queue_length                                    | 50                                         |
| mysql-min_num_servers_lantency_awareness                             | 1000                                       |
| mysql-aurora_max_lag_ms_only_read_from_replicas                      | 2                                          |
| mysql-stats_time_backend_query                                       | false                                      |
| mysql-stats_time_query_processor                                     | false                                      |
| mysql-query_cache_stores_empty_result                                | true                                       |
| admin-stats_credentials                                              | stats:stats                                |
| admin-stats_mysql_connections                                        | 60                                         |
| admin-stats_mysql_connection_pool                                    | 60                                         |
| admin-stats_mysql_query_cache                                        | 60                                         |
| admin-stats_mysql_query_digest_to_disk                               | 0                                          |
| admin-stats_system_cpu                                               | 60                                         |
| admin-stats_system_memory                                            | 60                                         |
| admin-telnet_admin_ifaces                                            | (null)                                     |
| admin-telnet_stats_ifaces                                            | (null)                                     |
| admin-refresh_interval                                               | 2000                                       |
| admin-read_only                                                      | false                                      |
| admin-hash_passwords                                                 | true                                       |
| admin-vacuum_stats                                                   | true                                       |
| admin-version                                                        | 2.5.2-20-g7a9e864                          |
| admin-cluster_username                                               |                                            |
| admin-cluster_password                                               |                                            |
| admin-cluster_check_interval_ms                                      | 1000                                       |
| admin-cluster_check_status_frequency                                 | 10                                         |
| admin-cluster_mysql_query_rules_diffs_before_sync                    | 3                                          |
| admin-cluster_mysql_servers_diffs_before_sync                        | 3                                          |
| admin-cluster_mysql_users_diffs_before_sync                          | 3                                          |
| admin-cluster_proxysql_servers_diffs_before_sync                     | 3                                          |
| admin-cluster_mysql_variables_diffs_before_sync                      | 3                                          |
| admin-cluster_admin_variables_diffs_before_sync                      | 3                                          |
| admin-cluster_ldap_variables_diffs_before_sync                       | 3                                          |
| admin-cluster_mysql_query_rules_save_to_disk                         | true                                       |
| admin-cluster_mysql_servers_save_to_disk                             | true                                       |
| admin-cluster_mysql_users_save_to_disk                               | true                                       |
| admin-cluster_proxysql_servers_save_to_disk                          | true                                       |
| admin-cluster_mysql_variables_save_to_disk                           | true                                       |
| admin-cluster_admin_variables_save_to_disk                           | true                                       |
| admin-cluster_ldap_variables_save_to_disk                            | true                                       |
| admin-checksum_mysql_query_rules                                     | true                                       |
| admin-checksum_mysql_servers                                         | true                                       |
| admin-checksum_mysql_users                                           | true                                       |
| admin-checksum_mysql_variables                                       | true                                       |
| admin-checksum_admin_variables                                       | true                                       |
| admin-checksum_ldap_variables                                        | true                                       |
| admin-restapi_enabled                                                | false                                      |
| admin-restapi_port                                                   | 6070                                       |
| admin-web_enabled                                                    | false                                      |
| admin-web_port                                                       | 6080                                       |
| admin-web_verbosity                                                  | 0                                          |
| admin-prometheus_memory_metrics_interval                             | 61                                         |
| admin-admin_credentials                                              | admin:admin                                |
| admin-mysql_ifaces                                                   | 0.0.0.0:6000                               |
| mysql-threads                                                        | 8                                          |
| mysql-max_connections                                                | 10240                                      |
| mysql-default_query_delay                                            | 0                                          |
| mysql-default_query_timeout                                          | 36000000                                   |
| mysql-have_compress                                                  | true                                       |
| mysql-poll_timeout                                                   | 2000                                       |
| mysql-interfaces                                                     | 0.0.0.0:6001                               |
| mysql-default_schema                                                 | information_schema                         |
| mysql-stacksize                                                      | 1048576                                    |
| mysql-server_version                                                 | 5.5.30                                     |
| mysql-connect_timeout_server                                         | 3000                                       |
| mysql-monitor_username                                               | monitor                                    |
| mysql-monitor_password                                               | monitor                                    |
| mysql-monitor_history                                                | 600000                                     |
| mysql-monitor_connect_interval                                       | 60000                                      |
| mysql-monitor_ping_interval                                          | 10000                                      |
| mysql-monitor_read_only_interval                                     | 1500                                       |
| mysql-monitor_read_only_timeout                                      | 500                                        |
| mysql-ping_interval_server_msec                                      | 120000                                     |
| mysql-ping_timeout_server                                            | 500                                        |
| mysql-commands_stats                                                 | true                                       |
| mysql-sessions_sort                                                  | true                                       |
| mysql-connect_retries_on_failure                                     | 10                                         |
+----------------------------------------------------------------------+--------------------------------------------+
201 rows in set (0.00 sec)

 

 

 

proxysql安装与配置_mysql_08

 

 

 

 

 

proxysql安装与配置_perl_09

 

 #######################

https://github.com/sysown/proxysql/blob/v2.x/INSTALL.md

 

########################


标签:src,pic,monitor,admin,配置,proxysql,mysql,query,安装
From: https://blog.51cto.com/u_13912516/6195207

相关文章

  • 安装Zookeeper和Kafka集群
    安装Zookeeper和Kafka集群本文介绍如何安装Zookeeper和Kafka集群。为了方便,介绍的是在一台服务器上的安装,实际应该安装在多台服务器上,但步骤是一样的。安装Zookeeper集群下载安装包从官网上下载安装包:curlhttps://dlcdn.apache.org/zookeeper/zookeeper-3.7.1/apache-zookee......
  • vscode c++ 配置
    //vscodeC++环境配置//三个配置文件c_cpp_properties.json{"configurations":[{"name":"Win32","includePath":["${workspaceFolder}/**"],......
  • rclone 安装
    安装rclonewget--no-check-certificate'https://downloads.rclone.org/v1.52.3/rclone-v1.52.3-linux-amd64.zip'unziprclone-v1.52.3-linux-amd64.zipcp./rclone-*/rclone/usr/local/binrm-rf./rclone-*配置在Linux上完成安装之后,rclone会默认从配置文件~/.config/......
  • 交换机镜像口配置
    H3C交换机配置镜像端口配置步骤1.进入配置模式:system-view;2.创建本地镜像组:mirroring-group1local3.为镜像组配置源端口:mirroring-group1mirroring-port4.为镜像组配置目的端口:mirroring-group1monitor-port配置举例1.<sysname>system-vies     (进入配置模式)2.......
  • 【vue3-element-admin】Husky + Lint-staged + Commitlint + Commitizen + cz-git 配
    前言本文介绍vue3-element-admin如何通过Husky+Lint-staged+Commitlint+Commitizen+cz-git来配置Git提交代码规范。核心内容是配置Husky的pre-commit和commit-msg两个钩子:pre-commit:Husky+Lint-staged整合实现Git提交前代码规范检测/格式化(前提......
  • Apache2.4配置http自动跳转到https
    首先在httpd.conf中配置如下:打开Apache重写模块(把#号去掉):LoadModulerewrite_modulemodules/mod_rewrite.so然后修改Directory里的内容,注意是修改标签包含自己项目路径的配置项<Directory"E:/wsp/www">OptionsIndexesFollowSymLinksAllowOverrideAllRewriteE......
  • .net6 在中标麒麟下的安装
    尝试了下.net6在信创环境下的安装和部署信创服务器,CPU:ARM64,操作系统:中标麒麟v10,网络环境:政务网(无法连接外网)1、下载.net6SDK6.0.408Arm64二进制文件。https://dotnet.microsoft.com/zh-cn/download/dotnet/6.02、在服务器/home目录下创建两个新目录,test和dotnet;3、上......
  • Linux离线安装jdk
    1、官网下载相应的jdkhttps://www.oracle.com/2、将jdk包上传到服务器并解压3、设置环境变量vi/etc/profileexportJAVA_HOME=/opt/jdk-20exportPATH=$PATH:$JAVA_HOME/binsource/etc/profile4、检查是否安装成功......
  • m1--安装python2
    brewinstallpyenv##这样更快如果在国外这步可以跳过cd~/.pyenvwgethttps://www.python.org/ftp/python/2.7.18/Python-2.7.18.tar.xzmkdircachecpPython-2.7.18.tar.xzcache##安装pyenvinstall2.7.18exportPATH="$(pyenvroot)/shims:${PATH}"pyenvglobal......
  • Rhel7.8编译安装suricata
    Rhel7.8编译安装suricata1、安装依赖yuminstall-ylibpcap-devellibnet-develpcre-develgcc-c++automakeautoconflibtoolmakelibyaml-develzlib-develfile-develjansson-develnss-devellua-develyuminstall-yrustccargopython3git 2、下载suricata源......