设为首页 加入收藏

TOP

[20190409]pre_page_sga=true与连接缓慢的问题.txt(二)
2019-09-17 19:01:10 】 浏览:91
Tags:20190409 pre_page_sga true 连接 缓慢 问题 .txt
bsp;       79           rt_sigaction
  ....
------ ----------- ----------- --------- --------- ----------------
100.00    0.420259                  1970       227 total

$ man shmdt
...
shmdt() detaches the shared memory segment located at the address specified by shmaddr from the address space of the
calling process.  The to-be-detached segment must be currently attached with shmaddr equal to the value returned by the
attaching shmat() call.

On a successful shmdt() call the system updates the members of the shmid_ds structure associated with the shared memory
segment as follows:

shm_dtime is set to the current time.
shm_lpid is set to the process-ID of the calling process.
shm_nattch is decremented by one.  If it becomes 0 and the segment is marked for deletion, the segment is deleted.

--//给人的感觉好像消耗在调用shmdt,实际上消耗的时间0.419648.也就是这样还是无法定位问题在那里.

$ strace -fTtt  -e shmdt sqlplus -s -l  / as sysdba
Process 6046 attached
[pid  6046] 08:41:55.548586 shmdt(0x7f2c41600000) = 0 <0.000036>
quit
08:41:59.992835 shmdt(0x60000000)       = 0 <0.000042>
08:41:59.992983 shmdt(0x68000000)       = 0 <0.000042>
08:41:59.993097 shmdt(0x6c000000)       = 0 <0.360175>
08:42:00.353446 shmdt(0x4ec000000)      = 0 <0.037200>
08:42:00.390737 shmdt(0x560000000)      = 0 <0.000026>
Process 6046 detached
--//我手工执行quit,可以发现shmdt调用发生在退出阶段,也就是不是它导致登陆缓慢.

$ ipcs -smt

------ Shared Memory Attach/Detach/Change Times --------
shmid      owner      attached             detached             changed
352092161  oracle      Apr 10 17:26:09      Apr 10 17:26:17      Apr 10 17:09:55
352124930  oracle      Apr 10 17:26:09      Apr 10 17:26:17      Apr 10 17:09:55
352157699  oracle      Apr 10 17:26:09      Apr 10 17:26:18      Apr 10 17:09:55
352190469  oracle      Apr 10 17:26:09      Apr 10 17:26:18      Apr 10 17:09:55
352223238  oracle      Apr 10 17:26:09      Apr 10 17:26:18      Apr 10 17:09:55

------ Semaphore Operation/Change Times --------
semid    owner      last-op                    last-changed
310738944 oracle      Wed Apr 10 17:11:33 2019   Wed Apr 10 17:11:33 2019
--//从执行时间看4.5秒并不是消耗在这里.

4.继续分析,排除调用
首页 上一页 1 2 3 4 下一页 尾页 2/4/4
】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
上一篇PhP数据库 Mysql dos命令 下一篇ThinkPhp5学习之新手博客

最新文章

热门文章

Hot 文章

Python

C 语言

C++基础

大数据基础

linux编程基础

C/C++面试题目