daniel.gottlieb asked if we had any API to find out what version of log files or some other way to know what version a database was last running. The problem is (from Dan):
- The problem right now with 4.0 is that we'd auto-upgrade 3.4 data files, then FCV parsing would not understand the "3.4" document and we'd shutdown without downgrading to 3.4.
WiredTiger, starting up with 4.0, will create a new log file at the later file format. When MongoDB shuts down due to the 3.4 document, the user can no longer restart with 3.4. So although the user should not be skipping releases, if they do this, the database is now unusable.
A new API to query the format or some other information, would allow MongoDB to not get into this unusable state. The operations would be something like:
So if you added an method to query the log version The startup algorithm could be: 1) Open in read-only mode 2) Query/Check log version - if not acceptable, close/crash 3) Otherwise close the connection and re-open in write-mode
- is depended on by
-
SERVER-32590 RTT 3.6<->4.0 upgrade/downgrade.
- Closed
- related to
-
WT-4029 Bump the log file version
- Closed