summaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authordwight <dwight@10gen.com>2011-03-18 03:11:12 -0400
committerdwight <dwight@10gen.com>2011-03-18 03:11:12 -0400
commita691ba4d41d8e82f4bd0b2c16d0f82bd3bea2b59 (patch)
tree3fb7a0c10ba26289f90e22a375c6e530af5fd894 /db
parent772ce197454b5b753512a763f58d73545c9d86ca (diff)
downloadmongo-a691ba4d41d8e82f4bd0b2c16d0f82bd3bea2b59.tar.gz
bad error msg SERVER-2711
Diffstat (limited to 'db')
-rw-r--r--db/instance.cpp23
1 files changed, 16 insertions, 7 deletions
diff --git a/db/instance.cpp b/db/instance.cpp
index 54fdcf2eac0..37106aabae7 100644
--- a/db/instance.cpp
+++ b/db/instance.cpp
@@ -915,12 +915,21 @@ namespace mongo {
}
}
else {
- errmsg = str::stream()
- << "************** \n"
- << "old lock file: " << name << ". probably means unclean shutdown\n"
- << "recommend removing file and running --repair\n"
- << "see: http://dochub.mongodb.org/core/repair for more information\n"
- << "*************";
+ if (dur::haveJournalFiles()) {
+ errmsg = str::stream() << "**************\n"
+ << "Error: journal files are present in journal directory, yet starting without --dur enabled.\n"
+ << "It is recommended that you start with journaling enabled so that recovery may occur.\n"
+ << "Alternatively (NOT recommended), you can backup everything, then delete the journal files, and run --repair\n"
+ << "**************";
+ }
+ else {
+ errmsg = str::stream()
+ << "************** \n"
+ << "old lock file: " << name << ". probably means unclean shutdown\n"
+ << "recommend removing file and running --repair\n"
+ << "see: http://dochub.mongodb.org/core/repair for more information\n"
+ << "*************";
+ }
}
if (!errmsg.empty()) {
@@ -940,7 +949,7 @@ namespace mongo {
cout << "**************" << endl;
cout << "Error: journal files are present in journal directory, yet starting without --dur enabled." << endl;
cout << "It is recommended that you start with journaling enabled so that recovery may occur." << endl;
- cout << "Alternatively (not recommended), you can backup everything, then delete the journal files, and run --repair" << endl;
+ cout << "Alternatively (NOT recommended), you can backup everything, then delete the journal files, and run --repair" << endl;
cout << "**************" << endl;
uasserted(13597, "can't start without --dur enabled when journal/ files are present");
}