[SERVER-1216] ensureIndex on "system.indexes" crashed server Created: 11/Jun/10  Updated: 12/Jul/16  Resolved: 11/Jun/10

Status: Closed
Project: Core Server
Component/s: Index Maintenance
Affects Version/s: 1.4.3
Fix Version/s: 1.5.2

Type: Bug Priority: Major - P3
Reporter: Shannon Fang Assignee: Eliot Horowitz (Inactive)
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Linux 2.6.33.5-112.fc13.i686 #1 SMP (Fedora 13)


Attachments: Text File mongo-bug.txt    
Operating System: Linux
Participants:

 Description   

> use test
> db.users.insert(

{name: "xrfang"}

)
> db.getCollectionNames()
[ "system.indexes", "users" ]
> db.system.indexes.ensureIndex(

{"name":1}

)
Fri Jun 11 17:39:21 MessagingPort recv() errno:104 Connection reset by peer 127.0.0.1:27017
Fri Jun 11 17:39:21 query failed : xrfang.$cmd

{ getlasterror: 1.0 }

to: 127.0.0.1
Fri Jun 11 17:39:21 JS Error: Error: error doing query: failed (anon):1284
Fri Jun 11 17:39:21 trying reconnect to 127.0.0.1
Fri Jun 11 17:39:21 reconnect 127.0.0.1 ok
Fri Jun 11 17:39:21 query failed : xrfang.$cmd

{ getlasterror: 1.0 }

to: 127.0.0.1
Fri Jun 11 17:39:21 JS Error: Error: error doing query: failed (anon):1284

In the above session I incorrectly called the ensureIndex on "system.Indexes" collection, and crashed the server. if I restart the server and try to do the same thing on the same collection, this bug disappear. But if I created a new db, do the same thing, it still crashes server.



 Comments   
Comment by Eliot Horowitz (Inactive) [ 11/Jun/10 ]

This was fixed in 1.5.1 or .2 already

Generated at Thu Feb 08 02:56:24 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.