samba xattrs for missing inode metadata

Steve French smfltc at
Tue Nov 16 19:35:36 GMT 2004

Poking around in the definitions of the ondisk format of various Linux
filesystems, I noticed that there will be some additional duplication of
data between the proposed Samba4 xattr and existing inode metadata.

Both ext3 and jfs define 4 time fields (although ext3 differs in the 4th
and none of the ext3 have sufficient granularity for 100nanosecond
e.g.for JFS the ondisk data format includes:
    struct timestruc_t di_atime;    /* 8: time last data accessed */
    struct timestruc_t di_ctime;    /* 8: time last status changed*/
    struct timestruc_t di_mtime;    /* 8: time last data modified */
    struct timestruc_t di_otime;    /* 8: time created */

and for ext3
     __le32  i_atime;        /* Access time */
     __le32  i_ctime;        /* Creation time */
     __le32  i_mtime;        /* Modification time */
     __le32  i_dtime;        /* Deletion Time */

and JFS also includes space in its inode for 16 bits of DOS attributes.

I am a little worried about the create time being maintained in two
places for some filesystems, and also because it is an important one to
make available to other applications (applications that might want
something lighter weight to get at them them the ndr xattr blob). One
advantage of storing all 4 of the time fields in the xattr is it does
get around the primitive on-disk format of the filesystems (such as
ext3) that don't have room for a 64 bit time field.

More information about the samba-technical mailing list