[DOCS-9954] Clarify what --nsInclude does exactly in mongorestore Created: 01/Mar/17 Updated: 30/Oct/23 Resolved: 01/Oct/19 |
|
| Status: | Closed |
| Project: | Documentation |
| Component/s: | manual, Server, tools |
| Affects Version/s: | None |
| Fix Version/s: | Server_Docs_20231030 |
| Type: | Bug | Priority: | Minor - P4 |
| Reporter: | Jaap Taal | Assignee: | Kay Kim (Inactive) |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Participants: | |||||||||
| Days since reply: | 4 years, 19 weeks, 1 day ago | ||||||||
| Epic Link: | DOCSP-1769 | ||||||||
| Description |
|
The docs for 3.4 about --nsInclude were confusing to me. Specifically, the phrases specify multiple collections and matches the smallest valid occurence seem to contradict each other. I'm coming from 3.2, for that version I created a script that downloads a backup, unzips it and restores the database to the local mongodb:
That command issues a warning in 3.4:
For me it's unclear how to map -d to --nsInclude. The full docs (https://docs.mongodb.com/manual/reference/program/mongorestore/#cmdoption-nsinclude):
|
| Comments |
| Comment by Kay Kim (Inactive) [ 01/Oct/19 ] |
|
Updated the definition for --nsInclude to:
Specifies a namespace pattern (e.g. "test.myCollection", "reporting.", "dept.bar") to restore only the namespaces that match the pattern. In the pattern, you can use asterisks * as wild cards. For an example of the wildcard pattern, see Restore Collections Using Wild Cards.
Updated the definition for --db to include the blurb:
The use of --db and --collection options are deprecated when restoring from a directory or an archive file. Instead, to restore from an archive or a directory, see --nsInclude instead.
|
| Comment by Kelsey Schubert [ 01/Mar/17 ] |
|
Hi q42jaap, Thanks for the report. Please note that SERVER project is for reporting bugs or feature suggestions for the MongoDB server. Since this issue affects our documentation, I've moved it our DOCS project where we track improvements to our documentation. Please continue to watch this ticket for updates. For MongoDB-related support discussion please post on the mongodb-user group or Stack Overflow with the mongodb tag. Kind regards, |