Uploaded image for project: 'Sqoop (Retired)'
  1. Sqoop (Retired)
  2. SQOOP-2147

configure-sqoop can corrupt the classpath in some cases

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.4.6
    • None
    • tools

    Description

      On my cluster, I had the following as hadoop classpath when running a sqoop import command:

      ...:/opt/cloudera/parcels/CDH-5.3.1-1.cdh5.3.1.p0.5/lib/hive-hcatalog/bin/hcat: Cannot find lib dir within HIVE_HOME : /home/mgrover/hive:....
      

      Yup, that's an error message in the classpath. Now, you may wonder how that happened.

      In configure-sqoop, we call (see here

      hcat -classpath
      

      However, hcat script is not perfect. It prints out error messages on stdout instead of stderr (see here and since configure-sqoop doesn't do any error checking, the error message gets appended to classpath.

      I'd recommend the script to check for exit code when calling hcat -classpath and only append if the exit code is 0.

      Attachments

        Activity

          People

            Unassigned Unassigned
            mgrover Mark Grover
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: