Thanks everyone for all of the information in this post, it was very helpful. Here are my notes, I hope they help someone else:
I had this happen the other day where I believe Parallels locked up the system while shrinking a VM volume via "Real time virtual disk optimization". I ended up with these errors after I had to reboot the system:
error: invalid dstream.size (89584566272), is greater than dstream.alloced_size (84972142592)
error: xf : INO_EXT_TYPE_DSTREAM : invalid dstream
error: inode_val: object (oid 0x4d872b): invalid xfields
fsroot tree is invalid.
The volume could not be verified completely.
I have since disabled Optimization -> "Real time virtual disk optimization" on all of my VMs. I hope this ends the problem I have where after about 1 month of uptime, my VMs get slower, and I have problems shutting them down (or they just lock up on their own).
To recover the VM file that was damage during the shrink, I was able to go into Time Machine, find the VM folder in the ~/Documents/Parallels folder, and restore a copy from time machine before the machine locked up to my Desktop, then delete the damaged files in ~/Documents/Parallels and move the files from my Desktop back to ~/Documents/Parallels.
I was surprised I could use time machine to recover the VM since the Parallels folder is excluded from my time machine backups, but for whatever reason this worked (i'm guessing time machine restored it from the prior snapshot).
Running "First Aid" in Disk Utility will still show problems with the snapshots, but deleting the bad APFS snapshots (see another post above) resolves that problem.
Anyhow, I hope turning off the "Real time virtual disk optimization" does the trick in making these problems go away.
Time will tell!
Last edited: Aug 11, 2018