mongodb - Where are mongo replication settings stored? -
after complete reinstall of mongo, has still remembered replica set configuration before; has stored this?
i installed mongo on linux server, using our project's user account, directory owned user. set replication , had working fine. then, test out finer install points, removed whole mongo directory , did reinstall. entering mongo, found replication set before; appear mongo storing information somewhere.
i have checked several areas might have been holding replica set config:
- first, in mongo directory, deleted.
- in traditional linux structure owned root, project user not have root access , mongo, run same, should not either.
- the project user's home directory. have .dbshell file containing command line history, that. did not see other files there related.
- some location specified in mongo configuration. have 2 paths mentioned in there, 1 system log (
systemlog.path
) , other storage (storage.dbpath
), , both point mongo directory, deleted.
does know mongo storing configuration information?
the replication data stored in local database in each node (as of mongodb 3.2.9). database contains information replica set, , contains oplog (the oplog.rs
collection). replica set information stored in system.replset
collection in local
database.
the physical files database (and other databases) stored in dbpath directory, can configured using:
- the
--dbpath
parameter when startingmongod
- the
storage.dbpath
setting in configuration file
the default dbpath
value /data/db
your replica set setting not retained if emptied dbpath
directory. if find replication settings being retained, possible dbpath
setting incorrect.
Comments
Post a Comment