mysql中innodb的启动过程

发布时间:2021-09-15 11:37:04 作者:chen
来源:亿速云 阅读:142

这篇文章主要讲解了“mysql中innodb的启动过程”,文中的讲解内容简单清晰,易于学习与理解,下面请大家跟着小编的思路慢慢深入,一起来研究和学习“mysql中innodb的启动过程”吧!

fil_init 主要是初始化文件打开指针哈希表,所有打开的文件全记录在 fil_system 之中,构造按名字查找的哈希表 
 
buf_pool_init 内存缓冲池的初始化,对应 buf_pool_ptr 数组之中,还初始化了 adaptive hash index 的内存
 
log_init 初始化log缓冲区,默认大小为 512*16k, 每个log页面大小为 #define OS_FILE_LOG_BLOCK_SIZE  512  日志文件在创建过程中也是指定不用系统缓存
  www.2cto.com  
 lock_sys_create 初始化系统锁,就是建了一个HASH表,lock_sys
 
 recv_recovery_from_checkpoint_start 开始执行恢复
 
dict_boot 初始化表结构的缓存,dict_sys,建两个hash表,可以根据表名和表ID查找;初始化系统表,就四个 SYS_TABLES SYS_COLUMNS SYS_INDEXES SYS_FIELDS ;初始化 insert buffer,每一个表空间对应一个;读入上面四个系统表中的内容
 
trx_sys_init_at_db_start 初初化事务结构体 trx_sys ; Creates the global purge system control structure and inits the history 
 
dict_create_or_check_foreign_constraint_tables 创建另外两张系统表 SYS_FOREIGN SYS_FOREIGN_COLS  www.2cto.com  
 
启动的线程,
 
IO部分共10个,可通过参数配置
 
1个 insert buffer thread
 
1个 log thread
 
4个 aio read thread
 
4个 aio write thread
 
1个 lock timeout thread      A thread which wakes up threads whose lock wait may have lasted too long
 
1个 error monitor thread    A thread which prints warnings about semaphore waits which have lasted too long
 
1个 monitor thread           A thread which prints the info output by various InnoDB monitors
 
1个 master thread           The master thread controlling the server
 
1个 thread handle shutdown
 
1个 handle connections socket 专门用来处理连理的
 
1个 trx_rollback_or_clean_all_recovered Rollback the uncommitted transactions which have no user   session  www.2cto.com  
 
 
 
struct st__plugin *mysql_optional_plugins[]=
{
   builtin_innobase_plugin, builtin_perfschema_plugin, builtin_partition_plugin, 0
};
 
struct st_mysql_plugin *mysql_mandatory_plugins[]=
{
  builtin_binlog_plugin, builtin_mysql_password_plugin,  builtin_csv_plugin, builtin_heap_plugin, builtin_myisam_plugin, builtin_myisammrg_plugin, 0
};
初始化的 binlog memory myisam innodb pefformance_schema partition

感谢各位的阅读,以上就是“mysql中innodb的启动过程”的内容了,经过本文的学习后,相信大家对mysql中innodb的启动过程这一问题有了更深刻的体会,具体使用情况还需要大家实践验证。这里是亿速云,小编将为大家推送更多相关知识点的文章,欢迎关注!

推荐阅读:
  1. MySQL InnoDB 事务
  2. MySQL中InnoDB与MyISAM的区别

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

mysql innodb

上一篇:清除浮动的影响是怎样的

下一篇:CSS的高级技巧有哪些

相关阅读

您好,登录后才能下订单哦!

密码登录
登录注册
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》