strace分析启动流程
Posted chinaops
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了strace分析启动流程相关的知识,希望对你有一定的参考价值。
strace -ttt /usr/local/mysql/bin/mysqld 2>&1 |tee 1.log
vi 1.log
1 1530183737.761709 execve("/usr/local/mysql/bin/mysqld", ["/usr/local/mys ql/bin/mysqld"], [/* 22 vars */]) = 0
2 1530183737.762769 brk(NULL) = 0x2c3e000
3 1530183737.763543 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP _ANONYMOUS, -1, 0) = 0x7f716b606000
4 1530183737.763959 access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No suc h file or directory)
5 1530183737.765866 open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
6 1530183737.766479 fstat(3, {st_mode=S_IFREG|0644, st_size=22349, ...}) = 0
7 1530183737.767560 mmap(NULL, 22349, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f 716b600000
8 1530183737.768290 close(3) = 0
9 1530183737.769406 open("/lib64/libpthread.so.0", O_RDONLY|O_CLOEXEC) = 3 10 1530183737.769905 read(3, "177ELF211 3 >