Changeset 3701


Ignore:
Timestamp:
Apr 3, 2018, 12:31:02 AM (3 months ago)
Author:
bruno
Message:

Workaround #836 by disabling crc on XFS FS at restore time for now.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3.3/mondo/src/mondorestore/mondo-prep.c

    r3633 r3701  
    787787
    788788res = run_program_and_log_output(program, FALSE);
     789mr_free(program);
    789790if (res) {
    790791    mr_strcat(tmp, "...failed");
     
    794795log_to_screen(tmp);
    795796mr_free(tmp);
     797
     798/*  BR#836: we need to do it a second time if -m wasn't working in that version for XFS */
     799if ((res) && (strcmp(format, "xfs") == 0)) {
     800    mr_asprintf(program, "sh -c 'echo -en \"y\\ny\\ny\\n\" | mkfs.xfs -f -q %s'", device);
     801
     802    mr_asprintf(tmp, "Formatting %s as %s", device, format);
     803    update_progress_form(tmp);
     804
     805    res = run_program_and_log_output(program, FALSE);
     806    mr_free(program);
     807    if (res) {
     808        mr_strcat(tmp, "...failed");
     809    } else {
     810        mr_strcat(tmp, "...OK");
     811    }
     812    log_to_screen(tmp);
     813    mr_free(tmp);
     814}
    796815
    797816retval += res;
     
    21292148    mr_asprintf(program, "mkreiserfs -ff");
    21302149} else if (strcmp(format, "xfs") == 0) {
    2131     mr_asprintf(program, "mkfs.xfs -f -q");
     2150    /*  Cf: https://bugzilla.redhat.com/show_bug.cgi?id=1309498 */
     2151    mr_asprintf(program, "mkfs.xfs -f -q -m crc=0 -n ftype=0");
    21322152} else if (strcmp(format, "jfs") == 0) {
    21332153    mr_asprintf(program, "mkfs.jfs");
Note: See TracChangeset for help on using the changeset viewer.