Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.8.0
    • Fix Version/s: 0.8.0
    • Component/s: rpm
    • Labels:
      None

      Description

      Error is:

      Found '/projects/apache/bigtop/build/hue/rpm/BUILDROOT/hue-2.5.1-1.fc19.x86_64' in installed files; aborting
      error: Bad exit status from /var/tmp/rpm-tmp.T9MSVV (%install)

      RPM build errors:
      Bad exit status from /var/tmp/rpm-tmp.T9MSVV (%install)
      make: *** [/projects/apache/bigtop/build/hue//.rpm] Error 1

      1. BIGTOP-1169.patch
        0.6 kB
        Guodong Wang

        Activity

        Hide
        rvs Roman Shaposhnik added a comment -

        I can bet a buck there was a failure earlier in the Hue build that led to this problem.

        Show
        rvs Roman Shaposhnik added a comment - I can bet a buck there was a failure earlier in the Hue build that led to this problem.
        Hide
        mantonov Mikhail Antonov added a comment -

        Well, I don't know but I didn't see anything particularly wrong in the logs above. But that error to me doesn't look like it's related to compilation/build of Hue itself,rather to rpm spec/packaging.

        Curious if anyone else observed the same on recent bigtop trunk "make realclean rpm" build.

        Show
        mantonov Mikhail Antonov added a comment - Well, I don't know but I didn't see anything particularly wrong in the logs above. But that error to me doesn't look like it's related to compilation/build of Hue itself,rather to rpm spec/packaging. Curious if anyone else observed the same on recent bigtop trunk "make realclean rpm" build.
        Hide
        plinnell Peter Linnell added a comment -

        Trunk builds fine for me on SLES 11 SP3. I ran make realclean rpm''

        Show
        plinnell Peter Linnell added a comment - Trunk builds fine for me on SLES 11 SP3. I ran make realclean rpm''
        Hide
        mantonov Mikhail Antonov added a comment -

        I"m actually building github master (trunk), not SVN-based (I assume there're the same) on fedora 19. Will try the same from SVN source.

        Did you try to clean manually maven cache (.m2) before the build?

        Show
        mantonov Mikhail Antonov added a comment - I"m actually building github master (trunk), not SVN-based (I assume there're the same) on fedora 19. Will try the same from SVN source. Did you try to clean manually maven cache (.m2) before the build?
        Hide
        mantonov Mikhail Antonov added a comment -

        Still, I'm getting the same error. Anyone else saw it on latest Fedora/Centos?

        Show
        mantonov Mikhail Antonov added a comment - Still, I'm getting the same error. Anyone else saw it on latest Fedora/Centos?
        Hide
        Slaytanic Lei Xiang added a comment -

        I use below to resolve this issue:

        vi /usr/lib/rpm/check-buildroot
        search "exit 1" and comment it
        save and quit and re-run make hue-rpm will build the rpms

        Show
        Slaytanic Lei Xiang added a comment - I use below to resolve this issue: vi /usr/lib/rpm/check-buildroot search "exit 1" and comment it save and quit and re-run make hue-rpm will build the rpms
        Hide
        plinnell Peter Linnell added a comment -

        It is something else. hacking the rpm package files is not an option. I'll try this on a VM soon.

        Show
        plinnell Peter Linnell added a comment - It is something else. hacking the rpm package files is not an option. I'll try this on a VM soon.
        Hide
        wanggd04@gmail.com Guodong Wang added a comment -

        I ran into this issue in the current branch.
        bigtop is 0.8 and hue is 3.6.0.

        My OS is centos 6.4. Is this related to OS env?

        Show
        wanggd04@gmail.com Guodong Wang added a comment - I ran into this issue in the current branch. bigtop is 0.8 and hue is 3.6.0. My OS is centos 6.4. Is this related to OS env?
        Hide
        rvs Roman Shaposhnik added a comment -

        What this typically means is that that the Hue builds itself failed midstream. The weird thing is – it would still exit with 0 but won't produce files expected for packaging.

        Show
        rvs Roman Shaposhnik added a comment - What this typically means is that that the Hue builds itself failed midstream. The weird thing is – it would still exit with 0 but won't produce files expected for packaging.
        Hide
        wanggd04@gmail.com Guodong Wang added a comment -

        Hi Roman Shaposhnik, based on your comments.
        looks like this is a issue for Hue.
        I am going to dig it deeper. If this is a make failure in Hue, I think we need to file a jira to Hue.
        When build failure, make should not return 0.

        Show
        wanggd04@gmail.com Guodong Wang added a comment - Hi Roman Shaposhnik , based on your comments. looks like this is a issue for Hue. I am going to dig it deeper. If this is a make failure in Hue, I think we need to file a jira to Hue. When build failure, make should not return 0.
        Hide
        wanggd04@gmail.com Guodong Wang added a comment -

        I found these log in the error message

        /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/apps/logs/syncdb.log:[09/Jul/2014 02:11:15 ] appmanager   DEBUG    Old-style static directory: /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/apps/zookeeper/static
        /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/apps/logs/migrate.log:[09/Jul/2014 02:11:16 ] appmanager   DEBUG    Old-style static directory: /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/desktop/core/static
        /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/apps/logs/migrate.log:[09/Jul/2014 02:11:16 ] appmanager   DEBUG    Old-style static directory: /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/desktop/libs/indexer/static
        

        Bigtop add migrate/syncdb log to rpm package, then, check_root script fails, because these log file contains BUILD_ROOT string.

        A possible work around is that excludes the file under /usr/lib/hue/apps/logs.

        But I am wondering why Hue does the DB sync and migration when building. Normally, DB migration should be done when the app starts at the first time. No need to init DB during compiling time.

        Show
        wanggd04@gmail.com Guodong Wang added a comment - I found these log in the error message /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/apps/logs/syncdb.log:[09/Jul/2014 02:11:15 ] appmanager DEBUG Old-style static directory: /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/apps/zookeeper/static /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/apps/logs/migrate.log:[09/Jul/2014 02:11:16 ] appmanager DEBUG Old-style static directory: /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/desktop/core/static /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/apps/logs/migrate.log:[09/Jul/2014 02:11:16 ] appmanager DEBUG Old-style static directory: /home/gordon/bigtop/build/hue/rpm/BUILDROOT/hue-3.6.0-1.el6.x86_64/usr/lib/hue/desktop/libs/indexer/static Bigtop add migrate/syncdb log to rpm package, then, check_root script fails, because these log file contains BUILD_ROOT string. A possible work around is that excludes the file under /usr/lib/hue/apps/logs. But I am wondering why Hue does the DB sync and migration when building. Normally, DB migration should be done when the app starts at the first time. No need to init DB during compiling time.
        Hide
        rvs Roman Shaposhnik added a comment -

        We need to do DB migration to pre-populate the database with app registration.

        Show
        rvs Roman Shaposhnik added a comment - We need to do DB migration to pre-populate the database with app registration.
        Hide
        wanggd04@gmail.com Guodong Wang added a comment -

        got it!
        Then, the solution might be remove all the log file in install-hue.sh.
        IMO, no need to include the log into the rpm, because it is not generated by users.

        What's your opinion? Roman Shaposhnik

        Show
        wanggd04@gmail.com Guodong Wang added a comment - got it! Then, the solution might be remove all the log file in install-hue.sh. IMO, no need to include the log into the rpm, because it is not generated by users. What's your opinion? Roman Shaposhnik
        Hide
        wanggd04@gmail.com Guodong Wang added a comment -

        BTW: we'd better add target: locales in current hue do-component-build to support multi-language.

        Show
        wanggd04@gmail.com Guodong Wang added a comment - BTW: we'd better add target: locales in current hue do-component-build to support multi-language.
        Hide
        rvs Roman Shaposhnik added a comment -

        +1 to that and the multi-language support.

        Show
        rvs Roman Shaposhnik added a comment - +1 to that and the multi-language support.
        Hide
        romainr Romain Rigaux added a comment -

        Let us know if they are other problems (Hue compiles fin in CDH currently).

        I don't know if it would help here or later, but Hue 2 used to need only the 'syncdb' command, Hue 3 needs the 'syncdb' and 'migrate' command (South changed when upgrading it).

        Show
        romainr Romain Rigaux added a comment - Let us know if they are other problems (Hue compiles fin in CDH currently). I don't know if it would help here or later, but Hue 2 used to need only the 'syncdb' command, Hue 3 needs the 'syncdb' and 'migrate' command (South changed when upgrading it).
        Hide
        wanggd04@gmail.com Guodong Wang added a comment -

        Romain Rigaux, since syncdb and migrate are needed during building Hue 3, I think excluding these logs in install-hue might be the right way to fix this.

        Roman Shaposhnik, would you mind to assign this to me? I think I can provide a patch later.

        Show
        wanggd04@gmail.com Guodong Wang added a comment - Romain Rigaux , since syncdb and migrate are needed during building Hue 3, I think excluding these logs in install-hue might be the right way to fix this. Roman Shaposhnik , would you mind to assign this to me? I think I can provide a patch later.
        Hide
        rvs Roman Shaposhnik added a comment -

        All yours Guodong Wang!

        Show
        rvs Roman Shaposhnik added a comment - All yours Guodong Wang !
        Hide
        jmspaggi Jean-Marc Spaggiari added a comment -

        Just faced this issue. Might be happy to try a patch if anything is available.

        Show
        jmspaggi Jean-Marc Spaggiari added a comment - Just faced this issue. Might be happy to try a patch if anything is available.
        Hide
        rvs Roman Shaposhnik added a comment -

        Looks like the official builds are all fine: http://bigtop01.cloudera.org:8080/view/Bigtop-trunk/job/Bigtop-trunk-Hue/

        Perhaps you can take a hint of how to configure your env. from our Jenkins configuration.

        Show
        rvs Roman Shaposhnik added a comment - Looks like the official builds are all fine: http://bigtop01.cloudera.org:8080/view/Bigtop-trunk/job/Bigtop-trunk-Hue/ Perhaps you can take a hint of how to configure your env. from our Jenkins configuration.
        Hide
        mantonov Mikhail Antonov added a comment - - edited

        Jean-Marc Spaggiari there was also a hack suggested above here to comment out exit command in /check-buildroot file, if you need any kind of fix soon. May work for you.

        Show
        mantonov Mikhail Antonov added a comment - - edited Jean-Marc Spaggiari there was also a hack suggested above here to comment out exit command in /check-buildroot file, if you need any kind of fix soon. May work for you.
        Hide
        jmspaggi Jean-Marc Spaggiari added a comment -

        This is the way I went I have implenented a similar hack in the check-buildroot file but just a bit more cleaner:

        find "$RPM_BUILD_ROOT" \! \( \
            -name '*.pyo' -o -name '*.pyc' -o -name '*.elc' -o -name '.packlist' \
            \) -type f -print0 | grep -v DEBUG | \
            LANG=C xargs -0r grep -F "$RPM_BUILD_ROOT" >$tmp
        

        Basically, I just exclude the DEBUG lines.

        Now, I have not been able to find where this script is call from from the BigTop code. If someone points me to the right place, I can take a look at try to submit a patch. I would really prefer a nice solution, but at least now I have the rpms...

        Show
        jmspaggi Jean-Marc Spaggiari added a comment - This is the way I went I have implenented a similar hack in the check-buildroot file but just a bit more cleaner: find "$RPM_BUILD_ROOT" \! \( \ -name '*.pyo' -o -name '*.pyc' -o -name '*.elc' -o -name '.packlist' \ \) -type f -print0 | grep -v DEBUG | \ LANG=C xargs -0r grep -F "$RPM_BUILD_ROOT" >$tmp Basically, I just exclude the DEBUG lines. Now, I have not been able to find where this script is call from from the BigTop code. If someone points me to the right place, I can take a look at try to submit a patch. I would really prefer a nice solution, but at least now I have the rpms...
        Hide
        wanggd04@gmail.com Guodong Wang added a comment -

        upload the patch file

        Show
        wanggd04@gmail.com Guodong Wang added a comment - upload the patch file
        Hide
        wanggd04@gmail.com Guodong Wang added a comment -

        Roman Shaposhnik, I have uploaded the patch to the jira.
        Shall I use any CR tools like review board to start a code reiview?
        I think the patch is simple and straight-forward.

        Show
        wanggd04@gmail.com Guodong Wang added a comment - Roman Shaposhnik , I have uploaded the patch to the jira. Shall I use any CR tools like review board to start a code reiview? I think the patch is simple and straight-forward.
        Hide
        jmspaggi Jean-Marc Spaggiari added a comment - - edited

        Oh! I had done almost the same thing! Added a similar rm exactly at the same place but was not targeting the right directory.

        I just tried your patch on trunk and make hue-rpm passed.

        +1 for me.

        Another option instead of doing RM might be to parse all the files into this directory and remove DEBUG entries from them. But not sure this is required.

        Show
        jmspaggi Jean-Marc Spaggiari added a comment - - edited Oh! I had done almost the same thing! Added a similar rm exactly at the same place but was not targeting the right directory. I just tried your patch on trunk and make hue-rpm passed. +1 for me. Another option instead of doing RM might be to parse all the files into this directory and remove DEBUG entries from them. But not sure this is required.
        Hide
        wanggd04@gmail.com Guodong Wang added a comment -

        The log files in app/logs are written when registering app to hue desktop framework. So, no need to put the logs into the rpm packages. Only put the binary into the rpm is OK.

        Show
        wanggd04@gmail.com Guodong Wang added a comment - The log files in app/logs are written when registering app to hue desktop framework. So, no need to put the logs into the rpm packages. Only put the binary into the rpm is OK.
        Hide
        rvs Roman Shaposhnik added a comment -

        +1 and committed!

        Show
        rvs Roman Shaposhnik added a comment - +1 and committed!

          People

          • Assignee:
            wanggd04@gmail.com Guodong Wang
            Reporter:
            mantonov Mikhail Antonov
          • Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development