[SERVER-4794] Unable to run command shardCollection Created: 27/Jan/12  Updated: 30/Mar/12  Resolved: 27/Jan/12

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: 2.0.2
Fix Version/s: None

Type: Bug Priority: Major - P3
Reporter: Johnny Boy Assignee: Unassigned
Resolution: Done Votes: 0
Labels: commands, mongos, sharding
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Mongos running on FreeBSD.
Config servers and two shards running on debian linux.


Operating System: ALL
Participants:

 Description   

I have several databases/collections with identical structure and index keys but different values.
Enabling sharding works for all but one database which gives me this:

mongos> db.runCommand({"shardCollection": "xxx_ar.relevancyScores", "key":

{source: 1, date: 1}

})
{
"ok" : 0,
"errmsg" : "exception: invalid parameter: expected an object ()"
}

I have tried running the command in lowercase without any luck.



 Comments   
Comment by Johnny Boy [ 27/Jan/12 ]

Yes it was, now it works.
Thanks!

Comment by Johnny Boy [ 27/Jan/12 ]

Date doesn't exist for some.
I guess this is the problem then

Comment by Eliot Horowitz (Inactive) [ 27/Jan/12 ]

Do all of your documents have a source and date field?

Comment by Johnny Boy [ 27/Jan/12 ]

Same problem if I instead try to use a linux mongos

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