V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
nower
V2EX  ›  数据库

mysql 每几个小时就重启,求指点

  •  
  •   nower · 2015-05-24 14:21:33 +08:00 · 1201 次点击
    这是一个创建于 3478 天前的主题,其中的信息可能已经有所发展或是发生改变。

    mysql 版本是5.1.60

    err log如下
    150524 8:55:44 - mysqld got signal 11 ;
    This could be because you hit a bug. It is also possible that this binary
    or one of the libraries it was linked against is corrupt, improperly built,
    or misconfigured. This error can also be caused by malfunctioning hardware.
    We will try our best to scrape up some info that will hopefully help diagnose
    the problem, but since we have already crashed, something is definitely wrong
    and this may fail.

    key_buffer_size=16777216
    read_buffer_size=262144
    max_used_connections=5
    max_threads=151
    threads_connected=1
    It is possible that mysqld could use up to
    key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 133912 K
    bytes of memory
    Hope that's ok; if not, decrease some variables in the equation.

    Thread pointer: 0x1d885d0
    Attempting backtrace. You can use the following information to find out
    where mysqld died. If you see no messages after this, something went
    terribly wrong...
    stackbottom = 0x7f53d14f3cf0 thread_stack 0x40000
    [0x6895a4]
    [0x4bdd6b]
    [0x62b440]
    /lib/x86_64-linux-gnu/libc.so.6(get_nprocs+0x10d) [0x7f53d2e2a4ed]
    /lib/x86_64-linux-gnu/libc.so.6(+0x7f13e) [0x7f53d2db713e]
    /lib/x86_64-linux-gnu/libc.so.6(
    _libc_malloc+0x1ab) [0x7f53d2dbb0fb]
    /lib/x86_64-linux-gnu/libc.so.6(+0x6f20b) [0x7f53d2da720b]
    /lib/x86_64-linux-gnu/libnss_files.so.2(_nss_files_gethostbyaddr_r+0x1bb) [0x7f53d260050b]
    [0x7ad740]
    [0x7ad4c6]
    [0x4c49dc]
    [0x4c5f00]
    [0x4c670f]
    [0x62763a]
    [0x7a9b89]

    Trying to get some variables.
    Some pointers may be invalid and cause the dump to abort.
    Query ((nil)): is an invalid pointer
    Connection ID (thread ID): 630
    Status: NOT_KILLED

    7 条回复    2015-08-22 15:32:37 +08:00
    sanddudu
        1
    sanddudu  
       2015-05-24 14:22:51 +08:00
    mysqld got signal 11 ;
    This could be because you hit a bug. It is also possible that this binary
    or one of the libraries it was linked against is corrupt, improperly built,
    or misconfigured. This error can also be caused by malfunctioning hardware.
    We will try our best to scrape up some info that will hopefully help diagnose
    the problem, but since we have already crashed, something is definitely wrong
    and this may fail.

    这里不是写着么
    nower
        2
    nower  
    OP
       2015-05-24 15:29:19 +08:00
    @sanddudu 求详解。从堆栈信息看,是在函数_nss_files_gethostbyaddr_r里面,但是进一步怎么定位问题所在呢?
    shakespark
        3
    shakespark  
       2015-05-24 16:28:15 +08:00
    我百度了一下/lib/x86_64-linux-gnu/libnss_files.so.2(_nss_files_gethostbyaddr_r
    看到这个帖子
    http://www.oschina.net/question/100161_107237

    霸气千秋 问题解决了,mysql配置文件缺少一个thread_cache_size=8 导致Threads_created不断增大,现在数据库已经正常运行两个消失了 (2年前)
    nower
        4
    nower  
    OP
       2015-05-24 21:53:16 +08:00
    @shakespark 谢谢,按照帖子的方法修改了配置,问题仍然存在,sigh
    ryd994
        5
    ryd994  
       2015-05-25 07:54:47 +08:00 via Android
    你用的什么发行版,MySQL来源是哪里?
    shakespark
        6
    shakespark  
       2015-05-25 08:50:23 +08:00
    如果真的是内存问题,那么你可以开top观察一下mysql占用的内存是否不断增大,超过了说明中说的130M内存。如果是这样的话,建议重新弄一份干净的配置文件再试,或者换别的mysql版本
    realpg
        7
    realpg  
       2015-08-22 15:32:37 +08:00
    重新编译一份 MYSQL
    重新在 MYSQL 给的 my.cnf 基础上修改配置
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   914 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 21ms · UTC 21:21 · PVG 05:21 · LAX 13:21 · JFK 16:21
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.