[SERVER-51763] Error message for missing config file is misleading Created: 20/Oct/20  Updated: 29/Oct/23  Resolved: 03/Dec/20

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: 5.0 Desired
Fix Version/s: 4.9.0

Type: Bug Priority: Minor - P4
Reporter: Dave Cuthbert (Inactive) Assignee: Varun Ravichandran
Resolution: Fixed Votes: 0
Labels: neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Operating System: ALL
Steps To Reproduce:

Start mongod using a fictitious config file:

  1. /usr/local/bin/mongod -f /etc/not-the-correct-name.conf

Expected:
'File: /etc/not-the-correct-name.conf not found'

Actual:
Error opening config file: Is a directory
try '/usr/local/bin/mongod --help' for more information

Sprint: Repl 2020-11-30
Participants:

 Description   

The error message when a user supplies the wrong path information for the configuration file is misleading. It should say something like 'File not found' instead it misidentifies the missing file as a directory and directs the user to --help for further information.

  1. /usr/local/bin/mongod -f /etc/not-the-correct-name.conf
    Error opening config file: Is a directory
    try '/usr/local/bin/mongod --help' for more information


 Comments   
Comment by Githook User [ 02/Dec/20 ]

Author:

{'name': 'Varun Ravichandran', 'email': 'varun.ravichandran@mongodb.com', 'username': 'varunravi98'}

Message: SERVER-51763: Rewrite misleading error message for missing config file
Branch: master
https://github.com/mongodb/mongo/commit/c0443454d7a67eb0fc5154da2ca1a53d50992569

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