The following are commonly used variables in MySQL databases, with 50 examples listed:
- max_connections - maximum number of connections
- character_set_server - default character set
- innodb_buffer_pool_size - InnoDB buffer pool size
- log_bin - whether to enable binary logging
- query_cache_type - Query cache type
- sql_mode - SQL execution mode
- innodb_file_per_table - whether to use a separate InnoDB tablespace for each table
- wait_timeout - idle time for client connections
- tmp_table_size - temporary table size limit
- innodb_flush_log_at_trx_commit - InnoDB log flush strategy every time a transaction is committed
- max_allowed_packet - Maximum allowed network packet size
- key_buffer_size - MyISAM index cache size
- innodb_log_file_size - InnoDB log file size
- innodb_lock_wait_timeout - InnoDB lock wait timeout
- innodb_thread_concurrency - InnoDB thread concurrency
- sync_binlog - Control the synchronization method of binlog
- max_heap_table_size - Maximum size of temporary table in memory
- thread_cache_size - Thread cache size
- innodb_flush_method - InnoDB method for flushing data and log files
- table_open_cache - cache number of open tables
- log_error - error log file path
- innodb_io_capacity - InnoDB IO capacity limit
- innodb_autoinc_lock_mode - InnoDB auto-increment lock mode
- innodb_open_files - Number of files opened by InnoDB
- interactive_timeout - client interaction timeout
- innodb_stats_on_metadata - whether to update statistics on metadata operations
- thread_stack - Thread stack size
- log_queries_not_using_indexes - Whether to log queries that do not use indexes
- innodb_checksum_algorithm - InnoDB data verification algorithm
- innodb_adaptive_hash_index_partitions - InnoDB adaptive hash index partition number
- innodb_use_native_aio - whether to enable native asynchronous IO
- innodb_fast_shutdown - Controls how quickly the InnoDB engine shuts down
- innodb_purge_threads - Number of InnoDB purge threads
- log_slow_queries - whether to log slow queries
- innodb_print_all_deadlocks - whether to print all deadlock information
- innodb_stats_persistent - Whether to persist InnoDB statistics
- innodb_strict_mode - whether to enable strict mode
- innodb_write_io_threads - InnoDB write IO thread number
- innodb_read_io_threads - InnoDB read IO thread number
- innodb_old_blocks_pct - Controls the proportion of old blocks retained in the buffer pool
- innodb_adaptive_max_sleep_delay - InnoDB adaptive maximum delay time
- innodb_undo_logs - Number of InnoDB undo logs
- innodb_log_buffer_size - InnoDB log buffer size
- innodb_flush_neighbors - Controls the flush strategy of neighboring pages
- innodb_thread_sleep_delay - InnoDB thread sleep delay time
- innodb_large_prefix - whether to enable large prefix indexes
- innodb_max_dirty_pages_pct - Controls the proportion of dirty pages
- innodb_checksums - Whether to enable InnoDB database checksums
- innodb_doublewrite - Whether to enable the InnoDB double-write mechanism
- innodb_stats_sample_pages - Number of pages sampled for InnoDB statistics
Note that these variables may vary depending on your MySQL version and system configuration. You can adjust the variable settings yourself as needed.