Sometimes, a volume refuses to eject because some program is using them.
Sadly, Finder doesn't give the identity nor gives a way to solve the problem.
So, how do you solve this problem in a clean way, without using a terminal ?
Using the terminal, I may find a way to eject it, but it's not reliable.
sudo lsof | grep volumeName certainly gives some information, but I don't feel like killing random processes in order to unmount a volume. Also, not everybody is willing to run command in a terminal.
I also don't want to force eject the volume. I think we shouldn't have to force the ejection when we didn't initially run the program that locks the volume.
Processes that are frequently involved are:
mds does not guarantee that the ejection of the volume will be possible.
mds process is respawned after getting killed, and continues preventing the ejection of the drive.
I also noticed that
mds can be running and using files, and still not preventing the ejection of the volume, so I'm not even sure that it's
lsofand then killing any troublesome processes actually is the canonical way to solve this problem (and all the tools which allow you to force-eject a drive do this as well), so I'm a bit unclear about what kind of problem you are trying to solve here. Can you please try to frame your question a bit more specifically?