Uploaded image for project: 'Lustre'
  1. Lustre
  2. LU-19163

add verbose stats to "lfs migrate -m"

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Unresolved
    • Major
    • None
    • None

    Description

      It would be useful to add progress stats to "lfs migrate -m" with an option "--stats". The time interval should be specified (e.g. "--stats-interval=N", but should default to once per 5s).

      It is not possible/practical to show an overall "percent completion" bar for "lfs migrate -m", since the number of files in the directory tree is not practical to know in advance, but it should definitely be possible for "lfs migrate" to show the percent completion metric for migrating individual directories.

      For "lfs migrate" it can show something like the following in YAML format, so that it is also possible to parse this output for consumption by other tools:

      filename:
      - { seconds: <seconds>, rfps: <MiB/s>, wfps: <MiB/s>, migrated: <NUM>, total: <NUM>, pct: <done>% }
      

      Whether the status update line ends in a newline "\n" for logging or piped to another program, or only a carriage return "\r" (that overprints the previous line for more user-friendly output) can be determined by calling isatty. The seconds: field is the total elapsed time. The rfps: (files read over read time) and wfps: (files written over write time) values would be a decaying average data transfer rate across files if a single invocation is migrating multiple files, since small files would barely have time to print anything before they are completed, so the instantaneous transfer rates may not be very useful. migrated: is the total number of files migrated for the current directory, and total: is the total directory size, pct: = migrated/total.

      See LU-13482 and "lfs migrate --stats [--stats-interval]" for file migration for details.

      Attachments

        Issue Links

          Activity

            People

              wc-triage WC Triage
              adilger Andreas Dilger
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: