New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Skip local volumes scan when remote filesystem is mounted / unmounted #869
Comments
Can you please check if you see any uevents reported in This should not cause distractions as UDisks is only monitoring block devices and their mounts. Just tried |
mount nfs: umount nfs: mount sshfs: umount sshfs: The filesystem on the sleeping HDD's is ext4. For the media layout, see the table in #868 (the /BigData volume). |
Thanks, this looks clean. I still couldn't think of a reason why this is happening. Given your complex layered structure I can only guess that the mdraid udev rules hooks or the udisks lvm2 module might cause some refresh. Probably worth further debugging. |
I think this is the problem: udisks/src/udiskslinuxprovider.c Lines 1561 to 1625 in 3ca2fd7
While certainly not good to update all objects and subject to further optimization, at least it would benefit from #949 as well in the sleeping/wakeup case. |
Well ... I don't have detailed knowledge about the inner workings of udisks, so please forgive me if I get something wrong. However, I agree that update_all_block_objects looks kind of excessive and subject to optimization. When I opened this issue, I wrote I'd like to learn about the reason why a full scan has to be done at all. In my PC user history, I often encountered software where this check everything approach is done just to be sure we didn't miss anything and I have a feeling this is the case here too. :-) About my background: I'm a developer, but not at OS/services level. I do only end user applications (mostly web, and a bit arduino and android) |
Yes, I guess so. The update everything approach is definitely safer yet too expensive, given how many operations are involved in the update chain. However, one can't always fully realize the consequences and all corner cases. In this case it looks simple, even a complex layered scenario has a single end block object that is marked as filesystem. |
This issue is a follow-up of #611 (comment). Having two aspects, I think it helps to separate them into individual issues. This is the smaller one.
The bigger one is #868.
I noticed that sleeping HDD's are woken up even when I mount or unmount remote filesystems such as nfs or even sshfs. Part of my job is taking care of a handful of web servers. This results in me being a heavy user of sshfs. :-)
I'm aware that solving #868 will be a big effort and will take some time. That's why I've come up with this idea. It is (hopefully) much easier to implement and will help be in about 80% of my use cases:
When the mount / unmount operation relates to a remote filesystem, it should be unnecessary to do a scan of local volumes.
The text was updated successfully, but these errors were encountered: