> From: Kevin Wolf [mailto:kw...@redhat.com] > > > > > > However, global -snapshot is just a convenient shortcut for specifying > > > snapshot=on for all -drive arguments. So if -snapshot is incompatible > > > with replay, shouldn't manually marking all drives as snapshot=on be > > > incompatible as well? > > > > > > Maybe you're really interested in some specific drive not having > > > snapshot=on? But then it might be better to check that specific drive > > > instad of forbidding just the shortcut for setting it. > > > > -snapshot adds the flag for top-level drive, making driver operations > > dependent on temporary file structure. > > > > Moving this overlay beneath blkreplay driver makes drive operations > > deterministic for the top-level device. > > So the real requirement is that blkreplay is the top-level node of any > guest device, right? And only because of this, you can't use -snapshot > (or snapshot=on on the blkreplay driver). > > If we instead check e.g. in blk_insert_bs() or blk_attach_dev() that in > record/replay mode, the root node of the BlockBackend is blkreplay, > wouldn't we catch many more incorrect setups?
That sounds interesting. Will it help to check that every backend is connected to blkreplay? How then this check has to be done? Pavel Dovgalyuk