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

EXT2_FLAG_IGNORE_SB_ERRORS undeclared

Details

    • Bug
    • Resolution: Duplicate
    • Major
    • None
    • None
    • RH 7.9
    • 3
    • 9223372036854775807

    Description

      Server Build with ldiskfs of 2.14 RC 3 on RHEL 7.9 system fails due to 3 undefined symbols:
      EXT2_FLAG_IGNORE_SB_ERRORS
      ext2fs_has_feature_quota()
      ext2fs_has_feature_mmp()

      libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I../.. -include /g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/undef.h -include /g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/config.h -I/g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/lnet/include/uapi -I/g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/lustre/include/uapi -I/g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/libcfs/include -I/g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/lnet/utils -I/g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/lustre/include -fPIC -D_GNU_SOURCE -D_LARGEFILE64_SOURCE=1 -D_FILE_OFFSET_BITS=64 -DLUSTRE_UTILS=1 -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -g -O2 -Werror -Wall -Werror -c liblustreapi_fid.c  -fPIC -DPIC -o .libs/liblustreapi_fid.o
      libmount_utils_ldiskfs.c:92:4: error: 'EXT2_FLAG_IGNORE_SB_ERRORS' undeclared here (not in a function)
          EXT2_FLAG_IGNORE_SB_ERRORS | EXT2_FLAG_SUPER_ONLY;
          ^
      libmount_utils_ldiskfs.c: In function 'ldiskfs_write_ldd':
      libmount_utils_ldiskfs.c:167:3: error: implicit declaration of function 'ext2fs_has_feature_mmp' [-Werror=implicit-function-declaration]
         if (!backfs || !ext2fs_has_feature_mmp(backfs->super)) {
         ^
      libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I../.. -include /g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/undef.h -include /g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/config.h -I/g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/lnet/include/uapi -I/g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/lustre/include/uapi -I/g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/libcfs/include -I/g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/lnet/utils -I/g/g0/faaland1/rpmbuild/BUILD/lustre-2.14.0_rc3_1atest/lustre/include -fPIC -D_GNU_SOURCE -D_LARGEFILE64_SOURCE=1 -D_FILE_OFFSET_BITS=64 -DLUSTRE_UTILS=1 -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -g -O2 -Werror -Wall -Werror -c liblustreapi_nodemap.c -o liblustreapi_nodemap.o >/dev/null 2>&1
      libmount_utils_ldiskfs.c: In function 'ldiskfs_enable_quota':
      libmount_utils_ldiskfs.c:1394:2: error: implicit declaration of function 'ext2fs_has_feature_quota' [-Werror=implicit-function-declaration]
        if (backfs && ext2fs_has_feature_quota(backfs->super)) {
        ^
      cc1: all warnings being treated as errors
      make[4]: *** [libmount_utils_ldiskfs_a-libmount_utils_ldiskfs.o] Error 1 

      We have e2fsprogs-devel-1.42.9-19.el7.x86_64 which doesn't define that macro:

      [root@opal185:~]# grep 'define EXT2_FLAG' /usr/include/ext2fs/ext2fs.h | tail
      #define EXT2_FLAG_JOURNAL_DEV_OK        0x1000
      #define EXT2_FLAG_IMAGE_FILE            0x2000
      #define EXT2_FLAG_EXCLUSIVE             0x4000
      #define EXT2_FLAG_SOFTSUPP_FEATURES     0x8000
      #define EXT2_FLAG_NOFREE_ON_ERROR       0x10000
      #define EXT2_FLAG_64BITS                0x20000
      #define EXT2_FLAG_PRINT_PROGRESS        0x40000
      #define EXT2_FLAG_DIRECT_IO             0x80000
      #define EXT2_FLAG_SKIP_MMP              0x100000
      #define EXT2_FLAG_FLUSH_NO_SYNC          1
      

      Do we need to update the specfile BuildRequires to require a newer version of e2fsprogs-devel? Or can we work around this to allow builds on RH 7.9?

      Attachments

        Issue Links

          Activity

            [LU-14439] EXT2_FLAG_IGNORE_SB_ERRORS undeclared

            Shaun's patch https://review.whamcloud.com/46340 "U-13906 build: Enable using ldiskfsprogs without wc tag" addresses this issue.

            adilger Andreas Dilger added a comment - Shaun's patch https://review.whamcloud.com/46340 " U-13906 build: Enable using ldiskfsprogs without wc tag " addresses this issue.
            diff Alexander Lezhoev added a comment - - edited

            My bad, I meant Requires and asking about removing .wc1 suffix from here.

            diff Alexander Lezhoev added a comment - - edited My bad, I meant Requires and asking about removing .wc1 suffix from here.

            diff could you please clarify, maybe in the form of a patch? The current .spec looks like:

            BuildRequires: e2fsprogs-devel >= 1.44.3
            Requires: ldiskfsprogs >= 1.45.6.wc1
            

            so there is no alphabetical suffix for BuildRequires. It would probably be fine to remove the .wc1 suffix from the Requires: line, because only Lustre-patches e2fsprogs will provide ldiskfsprogs, so any version is OK

            adilger Andreas Dilger added a comment - diff could you please clarify, maybe in the form of a patch? The current .spec looks like: BuildRequires: e2fsprogs-devel >= 1.44.3 Requires: ldiskfsprogs >= 1.45.6.wc1 so there is no alphabetical suffix for BuildRequires . It would probably be fine to remove the .wc1 suffix from the Requires: line, because only Lustre-patches e2fsprogs will provide ldiskfsprogs , so any version is OK

            Alphabetic suffixes in BuildRequires cause weird version comparison: e2fsprogs build with "1.45.6.zx" version will meet this requirement,  "1.45.6.ab" will not. Cray/HPE's "cr1" suffix has bad luck.

            Andreas, is it agreeable to keep just "e2fsprogs-devel >= 1.45.6"?

             

            diff Alexander Lezhoev added a comment - Alphabetic suffixes in BuildRequires cause weird version comparison: e2fsprogs build with "1.45.6.zx" version will meet this requirement,  "1.45.6.ab" will not. Cray/HPE's "cr1" suffix has bad luck. Andreas, is it agreeable to keep just "e2fsprogs-devel >= 1.45.6"?  

            Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/41682/
            Subject: LU-14439 build: require a newer version of e2fsprogs
            Project: fs/lustre-release
            Branch: master
            Current Patch Set:
            Commit: 6873482608ed61dc15a309a1384eec86124ca995

            gerrit Gerrit Updater added a comment - Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/41682/ Subject: LU-14439 build: require a newer version of e2fsprogs Project: fs/lustre-release Branch: master Current Patch Set: Commit: 6873482608ed61dc15a309a1384eec86124ca995

            No need for topllnl now that we have these patches.

            ofaaland Olaf Faaland added a comment - No need for topllnl now that we have these patches.

            Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/41683
            Subject: LU-14439 utils: skip server mount libs on client
            Project: fs/lustre-release
            Branch: master
            Current Patch Set: 1
            Commit: e59bc39a93f81258d8b08b22c8d53809d2343aca

            gerrit Gerrit Updater added a comment - Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/41683 Subject: LU-14439 utils: skip server mount libs on client Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: e59bc39a93f81258d8b08b22c8d53809d2343aca

            Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/41682
            Subject: LU-14439 build: require a newer version of e2fsprogs
            Project: fs/lustre-release
            Branch: master
            Current Patch Set: 1
            Commit: 6df18bdec88491ed4746d17e45d3d6c43a24192c

            gerrit Gerrit Updater added a comment - Andreas Dilger (adilger@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/41682 Subject: LU-14439 build: require a newer version of e2fsprogs Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: 6df18bdec88491ed4746d17e45d3d6c43a24192c
            ofaaland Olaf Faaland added a comment -

            I think this caught me by surprise partly because we've been building Lustre 2.12 ldiskfs packages under RHEL 7 with the RH supplied e2fsprogs for long enough I don't remember doing it any other way. I didn't hear from other sites that the ldiskfs we built wasn't working, but I don't know whether that's because they didn't use our packages or because everything worked fine. I am sure that they install the whamcloud e2fsprogs along with lustre on their servers.

            thanks

            (by the way, the e2fsprogs-devel-1.45.6-1.el8 shipped with RHEL 8.3 has
            EXT2_FLAG_IGNORE_SB_ERRORS, ext2fs_has_feature_mmp, and ext2fs_has_feature_mmp; there are about 40 patches on top of that to get to 1.45.6-wc1)

            ofaaland Olaf Faaland added a comment - I think this caught me by surprise partly because we've been building Lustre 2.12 ldiskfs packages under RHEL 7 with the RH supplied e2fsprogs for long enough I don't remember doing it any other way. I didn't hear from other sites that the ldiskfs we built wasn't working, but I don't know whether that's because they didn't use our packages or because everything worked fine. I am sure that they install the whamcloud e2fsprogs along with lustre on their servers. thanks (by the way, the e2fsprogs-devel-1.45.6-1.el8 shipped with RHEL 8.3 has EXT2_FLAG_IGNORE_SB_ERRORS, ext2fs_has_feature_mmp, and ext2fs_has_feature_mmp; there are about 40 patches on top of that to get to 1.45.6-wc1)
            ofaaland Olaf Faaland added a comment -

            Hi Andreas,

            On a server.

            Shouldn't this:

            BuildRequires: e2fsprogs-devel
            

            be this?

            BuildRequires: e2fsprogs-devel >= 1.45.6-wc1
            

            That BuildRequires is indeed in the section for the osd-ldiskfs-mount subpackage, so it's only enforced when building the server.

            ofaaland Olaf Faaland added a comment - Hi Andreas, On a server. Shouldn't this: BuildRequires: e2fsprogs-devel be this? BuildRequires: e2fsprogs-devel >= 1.45.6-wc1 That BuildRequires is indeed in the section for the osd-ldiskfs-mount subpackage, so it's only enforced when building the server.

            People

              adilger Andreas Dilger
              ofaaland Olaf Faaland
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: