[SERVER-1415] Giving incorrect parameter syntax to --replSet shows error in log but continues to run. Maybe it should abort like it does if the parameter is missing all together. Also, when parameter is missing, it would be nice to show expected syntax. Created: 13/Jul/10 Updated: 12/Jul/16 Resolved: 29/Jul/10 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Replication |
| Affects Version/s: | None |
| Fix Version/s: | 1.5.7 |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Tony Hannan | Assignee: | Tony Hannan |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
mongodb-linux-x86_64-2010-07-13 |
||
| Participants: |
| Description |
|
> bin/mongod --replSet yo log: |
| Comments |
| Comment by auto [ 27/Jul/10 ] |
|
Author: {'login': 'TonyGen', 'name': 'Tony Hannan', 'email': 'tony@10gen.com'}Message: Parse --replSet parameter into ReplSetCmdline struct in main thread, then fork startReplSets(ReplSetCmdline). We could not create theReplSet in main thread because constructor waits until config is loaded and thus would halt the rest of startup, and we couldn't move config loading out of constructor because other code tests for theReplSet != 0 to see if config is loaded. |
| Comment by auto [ 27/Jul/10 ] |
|
Author: {'login': 'erh', 'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}Message: tony found a bug This reverts commit 7740fb4070ad8326c81129d9d9095b556fe5ce13. |
| Comment by auto [ 27/Jul/10 ] |
|
Author: {'login': 'erh', 'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}Message: Per Eliot's suggestion, instead of calling dbexit in startReplSets thread. Create theReplSet object in main thread, which checks and parses --replSet parameter, then just call its go() methon in startReplSets thread. Conflicts: db/repl/rs.cpp |
| Comment by Eliot Horowitz (Inactive) [ 23/Jul/10 ] |
|
we only close once something is approved and released |
| Comment by Tony Hannan [ 23/Jul/10 ] |
|
dbexit on malformed --replSet parameter |
| Comment by Dwight Merriman [ 14/Jul/10 ] |
|
agree. btw it is showing the expected syntax already. want to try to do this (make it shut down)? see main() in db/db.cpp |