1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

Segmentation fault (core dumped) - how can I debug this?

Discussion in 'Help' started by the dood, Dec 15, 2016.

  1. the dood

    the dood Spider

    Messages:
    12
    I just merged from e790573 to 5dca11d and now when I start my server it progresses to loading one of my worlds then crashes.

    Code:
    [09:04:33] [Server thread/WARNING]: Non-packaged PocketMine-MP installation detected, do not use on production.
    [09:04:33] [Server thread/INFO]: Loading pocketmine.yml...
    [09:04:33] [Server thread/INFO]: Loading server properties...
    [09:04:33] [Server thread/INFO]: Selected English (eng) as the base language
    [09:04:33] [Server thread/INFO]: Starting Minecraft: PE server version v0.16.0.5 alpha
    [09:04:33] [Server thread/INFO]: Opening server on 1.2.3.4:19132
    [09:04:33] [Server thread/INFO]: This server is running PocketMine-MP version 1.6.1dev "Unleashed" (API 2.1.0)
    [09:04:33] [Server thread/INFO]: PocketMine-MP is distributed under the LGPL License
    [09:04:34] [Server thread/INFO]: Loading recipes...
    [09:04:34] [Server thread/INFO]: Loading DevTools v1.11.0
    [09:04:34] [Server thread/INFO]: Enabling DevTools v1.11.0
    [09:04:34] [Server thread/INFO]: Loading source plugin ManyWorlds v2.1.0
    [09:04:34] [Server thread/INFO]: Loading source plugin EmptyWorld v1.1.1
    [09:04:34] [Server thread/INFO]: Loading source plugin SimpleAuth v1.7.2
    [09:04:34] [Server thread/INFO]: Loading source plugin WorldProtect v2.3.0
    [09:04:34] [Server thread/INFO]: Loading source plugin Scorched v1.5.0
    [09:04:34] [Server thread/INFO]: Loading source plugin FastTransfer v1.0.2
    [09:04:34] [Server thread/INFO]: Loading source plugin WorldGM v9
    [09:04:34] [Server thread/INFO]: Loading source plugin SignWarp v1.6.0
    [09:04:34] [Server thread/INFO]: Loading source plugin GrabBag v2.5.0
    [09:04:34] [Server thread/INFO]: Loading source plugin SimpleWarp v2.1.1
    [09:04:34] [Server thread/INFO]: [DevTools] Registered folder plugin loader
    [09:04:34] [Server thread/INFO]: Enabling EmptyWorld v1.1.1
    [09:04:34] [Server thread/INFO]: Enabling SimpleAuth v1.7.2
    [09:04:34] [Server thread/INFO]: [SimpleAuth] Everything loaded!
    [09:04:34] [Server thread/INFO]: Enabling WorldProtect v2.3.0
    [09:04:34] [Server thread/INFO]: [WorldProtect] Enabled 4 features
    [09:04:34] [Server thread/INFO]: Enabling FastTransfer v1.0.2
    [09:04:34] [Server thread/INFO]: Preparing level "lobby"
    [09:04:34] [Server thread/INFO]: Preparing level "world"
    Segmentation fault (core dumped)
    

    My server.log file has nothing useful in it. Is there anything I can do (other than rolling back the merge) to determine what is causing the problem?

    Thanks
     
  2. the dood

    the dood Spider

    Messages:
    12
    Well... I disabled auto loading of my worlds and then the server eventually started (after several core dumps). I then stopped the server and re-enabled auto loading of my worlds and the server now starts. However, sometimes it core dumps and needs 2-3 attempts at starting before it is successful. If there was some debug flag I could set to help sort this out I would be happy to help, otherwise I'll keep on keepin' on. Thanks to all you developers out there that keep this project rolling along.
    Cheers.
     
    HimbeersaftLP and Magicode like this.
  3. Magicode

    Magicode Baby Zombie

    Messages:
    183
    GitHub:
    magicode1
    I always love it when people (When they find the answers to their problems), instead of keeping it to themselves, post it so that it can help others as well. Thanks for doing that! :)
     
    HimbeersaftLP likes this.
  4. robske_110 (Tim)

    robske_110 (Tim) Wither Skeleton Poggit Reviewer

    Messages:
    1,342
    GitHub:
    robske110
    Well, you could use some tools to look inside the core dump, but it probably wouldn't help at all.
    The segmentation fault is what we fear most, especially in php. Because most of the time, php fucked some memory (RAM) handling up and the stack trace only contains the function that were called in the C code of php, that mostly consists of some ZEND_DO_ALLOC_VM shit. If we actually would develop in C we could see the stack trace of our code, instead of that we see the stack trace of code that we never have written, the php interpreter. Also worth noting is, that this is mostly pthreads fault. (At least you can read that out of a core dump)
     
  5. SOFe

    SOFe Administrator Staff Member PMMP Team Poggit Admin

    Messages:
    1,968
    GitHub:
    sof3
    By my own experience this is usually caused by memory failure, especially infinite recursion. Most likely PocketMine issue. No reliable fix. Consider using another world.
     
  6. dktapps

    dktapps Administrator Staff Member PMMP Team

    Messages:
    774
    GitHub:
    dktapps
    Awzaw likes this.
  7. robske_110 (Tim)

    robske_110 (Tim) Wither Skeleton Poggit Reviewer

    Messages:
    1,342
    GitHub:
    robske110
    Infinte recursion should not result into a segfault though :[
     
  8. SOFe

    SOFe Administrator Staff Member PMMP Team Poggit Admin

    Messages:
    1,968
    GitHub:
    sof3
    I mean native infinite recursions,like this one.
    http://stackoverflow.com/q/40870614
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.