[SERVER-46398] Suggest explicit dbpath when starting mongod on macOS and the default dbpath isn't found Created: 25/Feb/20  Updated: 29/Oct/23  Resolved: 27/Apr/20

Status: Closed
Project: Core Server
Component/s: Storage
Affects Version/s: None
Fix Version/s: 4.0.19, 4.2.7, 3.6.19, 4.4.0-rc4, 4.7.0

Type: Task Priority: Major - P3
Reporter: Kelsey Schubert Assignee: Gregory Wlodarek
Resolution: Fixed Votes: 0
Labels: neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Documented
is documented by DOCS-13449 [Server] Remove default dbpath when s... Closed
Problem/Incident
Backwards Compatibility: Fully Compatible
Backport Requested:
v4.4, v4.2, v4.0, v3.6
Sprint: Execution Team 2020-05-04
Participants:
Linked BF Score: 0

 Description   

macOS Catalina runs in a dedicated, read-only system volume. Consequently, the default dbpath of "/data/db" is not able to be created. This issue is discussed in more detail in https://stackoverflow.com/questions/58283257/mongodb-cant-find-data-directory-after-upgrading-to-mac-os-10-15-catalina

Since this default will not work on Catalina and later, we should suggest an explicit dbpath be specified when starting mongod on macOS.



 Comments   
Comment by Githook User [ 01/May/20 ]

Author:

{'name': 'Gregory Wlodarek', 'email': 'gregory.wlodarek@mongodb.com', 'username': 'GWlodarek'}

Message: SERVER-46398 Fix include
Branch: v4.0
https://github.com/mongodb/mongo/commit/919cc73d751111856c048d82eebd110f2c4b0c60

Comment by Githook User [ 01/May/20 ]

Author:

{'name': 'Gregory Wlodarek', 'email': 'gregory.wlodarek@mongodb.com', 'username': 'GWlodarek'}

Message: SERVER-46398 Expand the data directory not found message on startup to be more informative
Branch: v3.6
https://github.com/mongodb/mongo/commit/ff5ba2d3b0334580dbfc340ea8552defd7ddfdab

Comment by Githook User [ 01/May/20 ]

Author:

{'name': 'Gregory Wlodarek', 'email': 'gregory.wlodarek@mongodb.com', 'username': 'GWlodarek'}

Message: SERVER-46398 Expand the data directory not found message on startup to be more informative

(cherry picked from commit 06755cd5a43d08b5e1e9163e060177d728ae6696)
Branch: v4.0
https://github.com/mongodb/mongo/commit/86c5888a258476d3c04a8d360685635b96ff9a4f

Comment by Githook User [ 01/May/20 ]

Author:

{'name': 'Gregory Wlodarek', 'email': 'gregory.wlodarek@mongodb.com', 'username': 'GWlodarek'}

Message: SERVER-46398 Expand the data directory not found message on startup to be more informative

(cherry picked from commit 06755cd5a43d08b5e1e9163e060177d728ae6696)
Branch: v4.2
https://github.com/mongodb/mongo/commit/79248bcaa5c21f0d711fc371269da51a2e633e43

Comment by Githook User [ 01/May/20 ]

Author:

{'name': 'Gregory Wlodarek', 'email': 'gregory.wlodarek@mongodb.com', 'username': 'GWlodarek'}

Message: SERVER-46398 Expand the data directory not found message on startup to be more informative

(cherry picked from commit 06755cd5a43d08b5e1e9163e060177d728ae6696)
Branch: v4.4
https://github.com/mongodb/mongo/commit/73cdd941c748eeaab4a53afb4f7d4e1b1b58fdce

Comment by Githook User [ 27/Apr/20 ]

Author:

{'name': 'Gregory Wlodarek', 'email': 'gregory.wlodarek@mongodb.com', 'username': 'GWlodarek'}

Message: SERVER-46398 Expand the data directory not found message on startup to be more informative
Branch: master
https://github.com/mongodb/mongo/commit/06755cd5a43d08b5e1e9163e060177d728ae6696

Comment by Connie Chen [ 03/Mar/20 ]

Thanks Brian! nominating this as a Q2 QW then

Comment by Brian Lane [ 03/Mar/20 ]

SGTM milkie - I chatted with Stennie as well about your proposal and he is OK with it.

connie.chen In regard to priority, not a blocker for 4.4 but could go into the QW epic.

Comment by Eric Milkie [ 28/Feb/20 ]

To make this less painful for users, we can simply change the error message when the default dbpath isn't found.
The current message is:

NonExistentPath: Data directory /data/db not found.

Typically, the workflow is that the user then attempts to create this directory. For macOS, we could expand on this message to suggest that dbpath be overridden to something else instead.

Comment by Connie Chen [ 27/Feb/20 ]

brian.lane can you review this for priority? 

Generated at Thu Feb 08 05:11:23 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.