• 1 reply
  • Latest Post - ‏2019-02-15T17:41:04Z by marc_of_GPFS
171 Posts

Pinned topic ILM, migration status

‏2018-08-29T13:50:09Z | attribute dmapi ilm migration purge status


in a DMAPI-enabled SpScale file system, how could one swiftly access information on the migration / purge status of a file from within an application, i.e. by API functions?


information on the status of a file WRT external pool migration and purging is contained in extended attributes AFAIK. However, I could not get to grips so far how that information is encoded. 

I do see EAs like "  gpfs.dmapi.region", "gpfs.dmapi.eventlist", or "dmapi._GHIATTR" (yep, its HPSS providing the external pool), but what tells me the exact status? The usage of policy scans is not suited for checking on single files, thus this would not help here.

Would these attributes be retrievable by dm_get_dmattr() ?




  • marc_of_GPFS
    50 Posts

    Re: ILM, migration status


    Look in gpfs.h 

    The gpfs_stat_x or gpfs_fstat_x can fill in a gpfs_iattr64_t for you.

    ia_flags are of interest.  Particularly

    #define GPFS_IAFLAG_TRUNCMANAGED    0x00080000 /* dmapi truncate event enabled */
    #define GPFS_IAFLAG_READMANAGED     0x00100000 /* dmapi read event enabled */
    #define GPFS_IAFLAG_WRITEMANAGED    0x00200000 /* dmapi write event enabled */

    If "readmanaged", the file is migrated out of the live file system.  The data is in the DMAPI system

    If not readmanaged, but it is writemanaged (and/or truncmanaged), then the file has been premigrated.

    If none of those bits are on, then the file is not DMAPI managed.

    For historic reasons

    #define GPFS_IAFLAG_COMANAGED       0x0080 /* file data is co-managed */
    is set whenever any of the trunc, read or write bits are set.

    You're welcome!