(I realize this isn't really the best place to ask this question as it's
rather a user-level API question, not a filesys designer's question, but I
give it a try anyway because I didn't have luck finding answers elsewhere
so far.)

My question is: How can a user level app determine whether an automounted
NFS share is currently accessible or not?

E.g, if using the /etc/auto_master etc. files, to mount NFS file shares
from another computer under a private directory such as /mymounts/, how can
I tell if the mounts there, such as /mymounts/server1/ are currently
accessible? I know that the automount-daemon maintains a state about it
because it prints messages into the console when the mount becomes
available or vanishes, and often, when trying to access the mount's dir, it
would simply return an empty dir and/or some error state. Yet, sometimes,
when I blindly attempt to read the mount's dir, this causes an attempt to
reach the (off-line) networked computer, leading to a timeout after many
seconds - and that's what I like to avoid as it'll stall my app and cause
all sorts of usability trouble.

Using lstat or looking at the flags from FSGetVolumeParms doesn't show me
any indication about this state.

How is that done, does anyone know?

I also asked the question on SO, if anyone likes to read or comment there:

http://stackoverflow.com/questions/28567054/

Thomas
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Filesystem-dev mailing list      (Filesystem-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/filesystem-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to