+ All Categories
Home > Documents > MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration...

MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration...

Date post: 28-May-2018
Category:
Upload: vandan
View: 229 times
Download: 0 times
Share this document with a friend
78
MySQL 5.1 Configuration Files & Options Part I Presented by: Sheeri K. Cabral Twitter: @sheeri
Transcript
Page 1: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

MySQL 5.1 Configuration Files & OptionsPart I

Presented by: Sheeri K. Cabral

Twitter: @sheeri

Page 2: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

© 2009/2010 Pythian

•Recognized Leader:• Global industry-leader in database infrastructure services for

Oracle, Oracle Applications, MySQL and SQL Server

• 150 current multinational companies such as Forbes.com, Fox Sports and Western Union to help manage their complex IT deployments

•Expertise:• One of the world’s largest concentrations of dedicated, full-time DBA expertise.

•Global Reach & Scalability:• 24/7/365 global remote support for DBA and consulting, systems administration, special

projects or emergency response

About Pythian

2

Page 3: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

3

What you can use this info for● Files, purpose, known issues

● System and status variables

● Tuning

● Includes Percona variables

Page 4: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

4

Included/not included

● Up to MySQL 5.1.41

● Includes Percona variables (5.1.36)

● Does not include InnoDB plugin variables

Page 5: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

5

Directories● basedir

● /app/mysql-5.1.29-rc-linux-x86_64/● datadir

● /app/mysql/data● tmpdir

● /tmp

Page 6: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

6

Directories● language

● /app/mysql-5.1.29-rc-linux-x86_64/share/mysql/english/

● plugin_dir● /app/mysql-5.1.29-rc-linux-x86_64/lib/mysql/plugin

Page 7: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

7

Configuration Files● In order:

● /etc/my.cnf● /etc/mysql/my.cnf● $SYSCONFDIR/my.cnf

– (--sysconfdir option to compiling)

Page 8: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

8

Configuration Files (2)● In order (still):

● $MYSQL_HOME/my.cnf– Server options [mysqld] [safe_mysqld] directives

● --defaults-extra-file● ~/.my.cnf

– User options [client] directive● commandline

Page 9: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

9

Summary: Configuration Files

● Just use /etc/my.cnf or /etc/mysql/my.cnf● and optionally ~/.my.cnf if you want to store

passwords, but secure the file!

Page 10: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

10

Other Files

● File extensions used by MySQL● .index .MYI .MYD .TRG .TRN .ibd .info .frm

● db.opt● Slave information

● master.info● relay-log.info

● Recommend: turn on log-slave-updates on all machines

Page 11: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

11

Version● Version (5.1.37-1ubuntu5-log)

● version_comment (Ubuntu)● version_compile_machine (x86_64)● version_compile_os (debian-linux-gnu)

● License (GPL)

Page 12: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

12

Basics● div_precision_increment (4)

● Default precision value● 4, so 1/11=0.0909

● lower_case_table_names (1)● lower_case_file_system (OFF)

Page 13: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

13

Basics● hostname (sea1tpmysql03s1)● port (3306)● socket (/tmp/mysql.sock)● pid file (/app/mysql/data/sea1tpmysql03s1.pid)● protocol version (10)

● client/server mysql protocol

Page 14: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

14

Basics● storage_engine (InnoDB)

● also table_type● time_zone (SYSTEM)● system_time_zone (PDT)● timestamp (124101315)

● used mostly in replication● affects CURRENT_TIMESTAMP(), NOW()● only affects SYSDATE() if sysdate-is-now is set

Page 15: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

15

Basics● Queries● Questions● Uptime● Uptime_since_flush_status

Page 16: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

16

Connections● max_connections (5000)

● Max_used_connections (50)

● Threads_connected (33)● Threads_running (2)

Page 17: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

17

Threads● Connections (439049)

● Threads_created (50)

● Threads_cached (17)● thread_cache_size (48)

Page 18: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

18

When a thread is slow to launch

● slow_launch_time (2)

● Slow_launch_threads (0)

Page 19: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

19

Aborted connects/clients

● Aborted_clients (9)

● Aborted_connects (57932)● max_connect_errors (100)● FLUSH HOSTS● connect_timeout

Page 20: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

20

Per-user limits

● max_tmp_tables (32)● not used yet

● max_user_connections (0)

Page 21: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

21

Security● old_passwords (OFF)

● secure_auth (ON)

● skip_show_database (OFF)

● secure_file_priv

Page 22: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

22

Initial SQL● init_connect

● String to execute when cxn is made

● init_file● File to execute when cxn is made

● init_slave● String to execute when slave cxn is made

Page 23: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

23

Query Cache● query_cache_type (ON)

● have_query_cache (YES)

● query_cache_size (128M)● Qcache_total_blocks (64,428)● Qcache_free_blocks (15,348)● Qcache_free_memory (44.1M)

● Qcache_queries_in_cache (20,536)

Page 24: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

24

Query Cache Usage● query_cache_limit (4M)● Qcache_not_cached (14,000,166)

● Qcache_lowmem_prunes (18,290,939)● Defragment with FLUSH QUERY CACHE● query_cache_min_res_unit (4096) can be

decreased if results are very small

Page 25: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

25

Query Cache Usage

● Qcache_hits (15,399,458)

● Qcache_inserts (26,947,349)

● Com_select (40,947,868)● Query cache hit % = 39.69%

Page 26: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

26

Query Cache Other

● query_cache_wlock_invalidate (OFF)

Page 27: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

27

Errors/Warnings

● error_count (0)

● warning_count (0)

● max_error_count (64)

Page 28: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

28

Character sets● character_sets_dir

● /app/mysql-5.1.29-rc-linux-x86_64/share/mysql/charsets)

● character_set_● client (utf8)● results (utf8)● server (utf8)● database (utf8)● filesystem(binary)● system (utf8)● connection (utf8)

Page 29: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

29

Collations● collation_

● server (utf8_general_ci)● database (utf8_general_ci)● connection (utf8_general_ci)

Page 30: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

30

Locale information

● default_week_format (0)

● lc_time_names (en_US)

Page 31: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

31

Logs

● log_output (FILE,TABLE)

● General● Slow query● Error● Binary

Page 32: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

32

General Log

● general_log (OFF)● log (OFF)

● general_log_file (/app/mysql/data/sea1tpmysql03s1.log)

● sql_log_off (OFF)

Page 33: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

33

Slow Query Log● slow_query_log (ON)

● log_slow_queries (ON)

● slow_query_log_file (/app/mysql/data/sea1tpmysql03s1-slow.log)

● Slow_queries (649)

Page 34: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

34

What gets logged as a slow query

● long_query_time (0.5)

● log_queries_not_using_indexes (OFF)

● min_examined_row_limit (0)

Page 35: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

35

Error Logging

● log_error (/app/mysql/data/sea1tpmysql03s1.err)

● log_warnings (1)● sql_notes (ON)

Page 36: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

36

Binary Logging● log_bin (ON)

● sql_log_bin (ON), sql_log_update (ON)

● max_binlog_size (1G)● binlog_format (MIXED)

● mysqlbinlog --base64-output=DECODE-ROWS

● expire_logs_days (7)

Page 37: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

37

Binary Log Cache

● binlog_cache_size (2M)

● Binlog_cache_use (3,924,856)

● Binlog_cache_disk_use (23)

Page 38: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

38

Replication and Binary Logging● server_id (1)

● log_slave_updates (ON)

● sync_binlog (1)

● sync_frm (ON)

Page 39: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

39

Determinism and Replication● insert_id (0)

● last_insert_id (0)

● identity (0)

● rand_seed1, rand_seed2

Page 40: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

40

Slave Registration

● Optional, used for SHOW SLAVE HOSTS● report_host● report_port (3306)● report_user● report_password

Page 41: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

41

Relay Logs● relay_log, relay_log_index

● relay_log_info_file (relay_log.info)

● max_relay_log_size (0)● relay_log_space_limit (0)● relay_log_purge (ON)

Page 42: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

42

Master/Master Replication Settings

● auto_increment_offset (1)

● auto_increment_increment (1)

Page 43: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

43

Slave Settings

● slave_skip_errors (1061,1062)

● slave_net_timeout (60)

● slave_transaction_retries (10)

Page 44: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

44

More Slave Settings

● slave_exec_mode (STRICT)

● slave_load_tmpdir (/tmp)

● slave_compressed_protocol (OFF)

Page 45: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

45

Slave Status Variables● Slave_open_temp_tables (0)

● Slave_retried_transactions (0)

● Slave_running (ON)

Page 46: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

46

Slave Session Variables

● sql_slave_skip_counter (0)

● sql_warnings (OFF)

Page 47: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

47

Do and Ignore● binlog-do-db – don't use● binlog-ignore-db – don't use● replicate-do-db – don't use● replicate-ignore-db – don't use● replicate-do-table – don't use● replicate-ignore-table● replicate-ignore-wild-table

Page 48: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

48

Remember

● init_slave

Page 49: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

49

Other Binary Log Variables

● max_binlog_cache_size● max is supposed to be 4G● Appears as >17,000,000,000 G● bug, fixed by 5.1.31

Page 50: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

50

Stored Routines● max_sp_recursion_depth (0)

● automatic_sp_privileges (ON)

● log_bin_trust_function_creators (OFF)

● log_bin_trust_routine_creators (OFF)

Page 51: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

51

Temporary Tables● Per-thread

● tmp_table_size (128M)● max_heap_table_size (128M)

● Created_tmp_tables (2,017,444)● Created_tmp_disk_tables (13,746)

Page 52: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

52

Memory Settings (not storage engine dependent)

● join_buffer_size (128k)

● read_rnd_buffer_size (28M)

● max_prepared_stmt_count (16382)

● preload_buffer_size (32768)

Page 53: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

53

Memory Settings (not storage engine dependent)

● query_alloc_block_size (8192)

● query_prealloc_size (8192)

● thread_stack (192k)

Page 54: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

54

Table Definition Cache

● table_definition_cache (256)

● Open_table_definitions (181)

● Opened_table_definitions (465)

Page 55: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

55

Sorting Variables

● Sort_range (2,105,552)

● Sort_rows (12,161,270)

● Sort_scan (1,539,997)

Page 56: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

56

Bad Handler Status

● Handler_read_first (1704010)

● Handler_read_rnd (1354665)● read_buffer_size (2M)

● Handler_read_rnd_next (2637167797)

Page 57: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

57

Good Handler Status

● Handler_read_key (177,713,296)

● Handler_read_next (235,042,485)

● Handler_read_prev (0)

Page 58: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

58

Sorting System Variables● sort_buffer_size (56M)

● Sort_merge_passes (0)

● max_sort_length (1024)

Page 59: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

59

Join Buffer● join_buffer_size (56M)

● Select_full_join (1)

● Select_scan (2888498)

Page 60: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

60

Joining● max_join_size (4,294,967,295)

● sql_max_join_size

● sql_big_selects (ON)

● Select_range_check (0)

Page 61: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

61

Join Status Variables

● Select_full_range_join (0)

● Select_range (808,772)

Page 62: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

62

Profiling● have_community_features (YES)

● profiling (OFF)● per-session

● profiling_history_size (15)

Page 63: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

63

Optimizer

● optimizer_prune_level (1)

● optimizer_search_depth (62)

● optimizer_switch (5.1.34)

Page 64: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

64

Optimization● max_seeks_for_key (1.84E+019)

● max_length_for_sort_data (1024)

● Last_query_cost (0)

Page 65: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

65

Optimization

● range_alloc_block_size (4k)

● sql_select_limit (1.84E+019)

Page 66: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

66

SQL Behavior● sql_auto_is_null (ON)

● sql_mode(PIPES_AS_CONCAT,ANSI_QUOTES, IGNORE_SPACE,ORACLE,NO_KEY_OPTIONS, NO_TABLE_OPTIONS,NO_FIELD_OPTIONS, NO_AUTO_CREATE_USER)

● sql_quote_show_create (ON)

Page 67: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

67

SQL Behavior● sql_safe_updates (OFF)

● also called i-am-a-dummy

● updatable_views_with_limit (YES)

● new (OFF)

● old (OFF)

Page 68: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

68

Functions

● have_compress (YES)● Unrelated to Compression (OFF)

● have_crypt (YES)

● local_infile (ON)

Page 69: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

69

Features

● read_only (OFF)

● have_dynamic_loading (YES)

● have_partitioning (YES)

Page 70: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

70

Features● event_scheduler (OFF)

● have_geometry (YES)

● have_rtree_keys (YES)

● have_symlink (YES)

Page 71: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

71

Other Variables● locked_in_memory (OFF)

● bulk_insert_buffer_size (8 Mb)

● group_concat_max_len (1024)

● Created_tmp_files (40)

Page 72: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

72

Variables not covered● SSL:

● have_ssl● have_openssl● Ssl_ and ssl_

● Prepared_stmt_cnt (0)● engine_condition_pushdown (OFF)● Most Com_ and Handler_

Page 73: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

73

Variables That Are Not Useful● big_tables (OFF)

● sql_big_tables

● old_alter_table (OFF)

● pseudo_thread_id (0)

Page 74: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

74

Not used/Not useful● multi_range_count (256)

● table_lock_wait_timeout (50)

● rpl_recovery_rank (0)

● Rpl_status (NULL)

Page 75: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

75

These variables are not used● time_format (%H:%i:%s)

● date_format (%Y-%m-%d)

● datetime_format (%Y-%m-%d %H:%i:%s)

● innodb_file_io_threads (4)● used on Windows only

Page 76: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

76

Mostly Unused Variables● log_tc_size (24Kb)

● not shown in SHOW GLOBAL VARIABLES

● Tc_log_max_pages_used (0)

● Tc_log_page_size (0)

● Tc_log_page_waits (5)

Page 77: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

© 2009/2010 Pythian

Thank Y ou.

Win a signed copy of Sheeri’s book.

Leave your business card and you could win a book. We’ll invite you to read our blog posts, follow us on twitter, and join our next webinars.Drawing will be immediately after the talk once all cards are collected.

Page 78: MySQL 5.1 Configuration Files & Options Part Iassets.en.oreilly.com/1/event/36/MySQL Configuration Options and...Oracle, Oracle Applications, MySQL and SQL Server ... When a thread

© 2009/2010 Pythian

Thank Y ouQuestions, Comments, Feedback?

Sheeri [email protected]

Blog: www.pythian.com/news/author/sheeri

Ask me about saving 15% on our Adoption Accelerator for MySQL

while at MySQL Conference 2010!

78


Recommended