[SERVER-29556] Consistent names for disk files Created: 12/Jun/17  Updated: 27/Oct/23  Resolved: 16/Jun/17

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

Type: Improvement Priority: Major - P3
Reporter: Chris Kuethe Assignee: Backlog - Storage Execution Team
Resolution: Works as Designed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Storage Execution
Participants:

 Description   

{{/var/lib/mongodb/mydb/collection-5-5764035363882532292.wt
/var/lib/mongodb/mydb/index-2--3830019818973292215.wt
/var/lib/mongodb/mydb/index-3--3830019818973292215.wt}}

What do the names mean? How about naming them 'mycollection', index_id, index_my_index_name, or something else useful?



 Comments   
Comment by Ian Whalen (Inactive) [ 16/Jun/17 ]

Hi Chris, thanks a lot for the feature request. We've talked about this amongst the engineers on the Storage team and this would create conflicts between new and old collections when dropping, recreating and renaming them. As such we're closing as Works As Designed.

Comment by Chris Kuethe [ 13/Jun/17 ]

Thanks for the reply, though it's difficult to ask mongod for the mapping of file-to-collection when the server won't start. I've been using the `wt` command line tool to get that information.

Comment by Mark Agarunov [ 13/Jun/17 ]

Hello chris.kuethe@gmail.com,

Thank you for the report. The names are the URIs of the indexes and collections. You can see which files correspond to which collections/indexes with the following script:

db.getCollectionNames().forEach(
      function(collection){
         var stats=db[collection].stats({indexDetails:true});
         print ("Collection: " +collection + ", uri: "+ stats.wiredTiger.uri);
         s=stats.indexDetails;
         for (var c in s){
            print (" - \t Index: " + c + ", uri: " + s[c].uri);
         }
      });

I've set the fixVersion to "Needs Triage" for this new feature to be scheduled against our currently planned work. Updates will be posted on this ticket as they happen.

Thanks,
Mark

Generated at Thu Feb 08 04:21:12 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.