[Lustre-discuss] How to efficiently get sizes of all files stored in Lustre?

Dilger, Andreas andreas.dilger at intel.com
Tue Sep 16 09:50:56 PDT 2014


The FIDs of OST objects are different than those on MDT objects since this allows more flexibility in creating the layout of the file.

In any case, related to your specific goal - it is possible to get the parent (MDT) FID of each OST object from an xattr on the object itself.

See the code in lustre/utils/ll_decode_filter_fid.c to see details.

Cheers, Andreas

On Sep 16, 2014, at 8:41, "Marcin Barczyński" <mba.lustre.2014 at gmail.com<mailto:mba.lustre.2014 at gmail.com>> wrote:

Hello,

I would like to efficiently get sizes of all files stored in Lustre filesystem.

My first idea was to use Lester, the Lustre lister, and
1) obtain all FIDs of all files from MDT (lester -A fslist -a format=lustre -a show_fid MDT_DEVICE)
2) then scan all OSTs with the same command,
3) and finally match FIDs, and compute file sizes.

Unfortunately, FIDs on MDT are different from FIDs on OSTs. Why is it so?

Is there any way to get sizes of all files efficiently?

--
Best regards,
Marcin

_______________________________________________
Lustre-discuss mailing list
Lustre-discuss at lists.lustre.org<mailto:Lustre-discuss at lists.lustre.org>
http://lists.lustre.org/mailman/listinfo/lustre-discuss



More information about the lustre-discuss mailing list