[SERVER-20793] How Can I drop old system.users collection? Created: 07/Oct/15 Updated: 31/Dec/23 Resolved: 07/Oct/15 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Admin |
| Affects Version/s: | 2.6.10 |
| Fix Version/s: | None |
| Type: | Question | Priority: | Major - P3 |
| Reporter: | Filip Havlí?ek | Assignee: | Unassigned |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Participants: |
| Description |
|
How Can I drop system.users collection in database? In previsus versions of MongoDB every database has its own system.users collection but in newer (I think since 2.6) are credentials stored in admin.system.users. I try to drop obsolete collection (somedatabase.system.users), but I can't. ", |
| Comments |
| Comment by Ramon Fernandez Marina [ 12/Oct/15 ] |
|
filip.havlicek@livesport.eu, the reason these collections are not removed as part of the upgrade and no instructions to remove them are provided is to allow users to revert to 2.4 if they need to. After upgrading to 2.6 these collections are not used for anything, so it's safe to remove them as you described above. To drop them directly you may need to add drop privileges explicitly, but I haven't tested that approach. |
| Comment by Filip Havlí?ek [ 07/Oct/15 ] |
|
Yes, it's true, but nobody knows or nobody want to help.. |
| Comment by Ramon Fernandez Marina [ 07/Oct/15 ] |
|
I see that you've already posted your question in the mongodb-user group, and since we keep the SERVER project for See also our Technical Support page for additional support resources. Regards, |
| Comment by Filip Havlí?ek [ 07/Oct/15 ] |
|
OK.. I find a way which works. Is this a safe way how to drop old $database.system.users, admin.system.backup_users, admin.system.new_users collections? Is it safe for replica sets and sharding clusters too? |