[SERVER-2786] db.printShardingStatus() causes all config servers to immediately crash (segfault) Created: 17/Mar/11  Updated: 12/Jul/16  Resolved: 18/Mar/11

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: 1.8.0
Fix Version/s: 1.9.0

Type: Bug Priority: Critical - P2
Reporter: Benedikt Waldvogel Assignee: Kristina Chodorow (Inactive)
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:
  1. lsb_release -a
    LSB Version: n/a
    Distributor ID: SUSE LINUX
    Description: openSUSE 11.2 (x86_64)
    Release: 11.2
    Codename: n/a

Operating System: ALL
Participants:

 Description   

All config servers reproducible crash with a segfault if db.printShardingStatus() is executed on a mongo router (mongos).

The config server logfiles: https://gist.github.com/874822



 Comments   
Comment by Benedikt Waldvogel [ 18/Mar/11 ]

thanks for solving this issue so quickly.

Comment by auto [ 18/Mar/11 ]

Author:

{u'login': u'kchodorow', u'name': u'Kristina', u'email': u'kristina@10gen.com'}

Message: check for js engine before running group SERVER-2786
https://github.com/mongodb/mongo/commit/8c8c3368df0df6e354a32bf5ec70e1fd65b9e110

Comment by Kristina Chodorow (Inactive) [ 18/Mar/11 ]

db.printShardingStatus() calls group(), which is like map/reduce (executing JavaScript on the server). --noscripting means you can't execute JS on the server, so it should give you a better error (i.e., not crash), but db.printShardingStatus won't produce the right result unless you get rid of the --noscripting.

Comment by Kristina Chodorow (Inactive) [ 18/Mar/11 ]

Aha! You can't use --noscripting on the config servers, db.printShardingStatus() uses group(), which uses JavaScript.

Comment by Benedikt Waldvogel [ 18/Mar/11 ]

I've updated the gist. Is that enough of log data?
The server is started with the following options:
mongod --fork --logpath /data/mongodb/logs/config.log --logappend --dbpath /data/mongodb/config --syncdelay 10 --rest --noscripting --cpu --port 27217 --configsvr

Comment by Kristina Chodorow (Inactive) [ 18/Mar/11 ]

Also, can you post a chunk of a log from before the crash?

Comment by Kristina Chodorow (Inactive) [ 18/Mar/11 ]

What options did you start the config servers with? If you used a config file, can you paste its contents (and any command line ops)?

Comment by Benedikt Waldvogel [ 17/Mar/11 ]

using the 64 bit binary from http://fastdl.mongodb.org/linux/mongodb-linux-x86_64-1.8.0.tgz

  1. uname -a
    Linux mongo120 2.6.31.12-0.1-desktop #1 SMP PREEMPT 2010-01-27 08:20:11 +0100 x86_64 x86_64 x86_64 GNU/Linux
Comment by Eliot Horowitz (Inactive) [ 17/Mar/11 ]

Which binary are you using? 32 or 64 bit, static?
Also, can you send uname -a

Generated at Thu Feb 08 03:01:11 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.