On 04/21/10 03:24 AM, Darren J Moffat wrote:
On 21/04/2010 05:09, Edward Ned Harvey wrote:
From: zfs-discuss-boun...@opensolaris.org [mailto:zfs-discuss-
boun...@opensolaris.org] On Behalf Of Nicolas Williams

The .zfs/snapshot directory is most certainly available over NFS.

I'm not sure you've been following this thread. Nobody said .zfs/snapshot
wasn't available over NFS. It was said that all the snapshot
subdirectories
".zfs/snapshot/frequent-blah" and ".zfs/snapshot/hourly-foo" and so on
...

Over NFS there's no way to know the time those snapshots were taken.
There
is a convention of writing the time of the snapshot into the name of the
snapshot, but if you can't rely on that, then the NFS client doesn't know
the order of snapshots.

Correct and think this is because POSIX has not such thing as a file
creation date (ctime,mtime,atime is all it has) - ZFS actually does have
a creation date but there isn't a way to expose that over NFS that I'm
aware of and ls/stat can't see it because stat(2) doesn't have a way to
expose it.

You can see it with ls:
# ls -ld -% all /net/server/export/ws/timh/nvc
drwxr-xr-x 9 timh staff 13 Apr 21 01:25 /net/server/export/ws/timh/nvc/
         timestamp: atime         Apr 21 07:54:05 2010
         timestamp: ctime         Apr 21 01:25:48 2010
         timestamp: mtime         Apr 21 01:25:48 2010
         timestamp: crtime         Jun 22 08:27:23 2009

and I believe you can retrieve it with fgetattr() from the read/write
view.

-tim

The snapshot dir is just another directory and over NFS you are looking
at it with NFS so it shows the ctime,mtime,atime of the top level
directory of the ZFS dataset at the time the snapshot was created.

This RFE if it were to be implemented could give a possible way to get
this information from a remote filesystem client:

6527390 want to read zfs properties over nfs (eg via .zfs/props)


_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to