41
41
#include " dbwebserver.h"
42
42
#include " dur.h"
43
43
#include " concurrency.h"
44
+ #if !defined(_WIN32)
44
45
#include < sys/file.h>
46
+ #endif
45
47
46
48
namespace mongo {
47
49
@@ -461,11 +463,12 @@ namespace mongo {
461
463
}
462
464
463
465
if (cmdLine.dur )
464
- enableDurability ();
466
+ dur:: enableDurability ();
465
467
466
468
getDur ().startup ();
467
- if ( cmdLine.durTrace & CmdLine::DurRecoverOnly )
468
- return ;
469
+
470
+ // if( cmdLine.durTrace & CmdLine::DurRecoverOnly )
471
+ // return;
469
472
470
473
repairDatabasesAndCheckVersion ();
471
474
@@ -592,10 +595,6 @@ int initEmbeddedMongo(int argc, char* argv[])
592
595
(" ipv6" , " enable IPv6 support (disabled by default)" )
593
596
;
594
597
595
- #if defined(_WIN32)
596
- CmdLine::addWindowsOptions ( windows_scm_options, hidden_options );
597
- #endif
598
-
599
598
replication_options.add_options ()
600
599
(" fastsync" , " indicate that this instance is starting from a dbpath snapshot of the repl peer" )
601
600
(" autoresync" , " automatically resync if slave data is stale" )
@@ -617,12 +616,6 @@ int initEmbeddedMongo(int argc, char* argv[])
617
616
(" replSet" , po::value<string>(), " specify repl set seed hostnames format <set id>/<host1>,<host2>,etc..." )
618
617
;
619
618
620
- sharding_options.add_options ()
621
- (" configsvr" , " declare this is a config db of a cluster; default port 27019; default dir /data/configdb" )
622
- (" shardsvr" , " declare this is a shard db of a cluster; default port 27018" )
623
- (" noMoveParanoia" , " turn off paranoid saving of data for moveChunk. this is on by default for now, but default will switch" )
624
- ;
625
-
626
619
hidden_options.add_options ()
627
620
(" pretouch" , po::value<int >(), " n pretouch threads for applying replicationed operations" )
628
621
(" command" , po::value< vector<string> >(), " command" )
@@ -635,13 +628,9 @@ int initEmbeddedMongo(int argc, char* argv[])
635
628
636
629
positional_options.add (" command" , 3 );
637
630
visible_options.add (general_options);
638
- #if defined(_WIN32)
639
- visible_options.add (windows_scm_options);
640
- #endif
641
631
visible_options.add (replication_options);
642
632
visible_options.add (ms_options);
643
633
visible_options.add (rs_options);
644
- visible_options.add (sharding_options);
645
634
Module::addOptions ( visible_options );
646
635
647
636
setupCoreSignals ();
@@ -718,13 +707,8 @@ int initEmbeddedMongo(int argc, char* argv[])
718
707
assert ( false );
719
708
#endif
720
709
}
721
- if (params.count (" durTrace" )) {
722
- cmdLine.durTrace = params[" durTrace" ].as <int >();
723
- #if !defined(_DURABLE)
724
- assert ( cmdLine.durTrace == 0 );
725
- #endif
726
- }
727
- if (params.count (" objcheck" )) {
710
+ {
711
+ // objcheck on for safety
728
712
objcheck = true ;
729
713
}
730
714
if (params.count (" appsrvpath" )) {
0 commit comments