Results 1 to 7 of 7
Like Tree1Likes
  • 1 Post By Tolls

Thread: Classpath Nullpointer error

  1. #1
    nnani is offline Member
    Join Date
    Feb 2013
    Posts
    3
    Rep Power
    0

    Default Classpath Nullpointer error

    Hello All,

    Basically , I am a database guy. So Please don't mind If my questions are sounding silly.
    Here is the problem that I have got.

    I am trying to install a hadoop distribution named hadoopdb.

    I was instructed to place installed hadoopdb.jar file under $HADOOP_HOME/lib

    Basically the downloaded hadoopdb package contains 3 files

    1. Catalog.properties file
    2. hadoopdb.jar file
    3, SMS_dist.tar.gz

    The third file is nothing but Hive distribution of hadoop.

    Now the issues is according to the quick start guide

    To generate a HadoopDB.xml file we need to use command

    Java Code:
    java -cp hadoopdb.jar edu.yale.cs.hadoopdb.catalog.SimpleCatalogGenerator path_to_Catalog.properties
    When I use the above command

    Java Code:
    [hduser@node1 lib]$ java -cp hadoopdb.jar edu.yale.cs.hadoopdb.catalog.SimpleCatalogGenerator /usr/local/hdb/hadoopdb/Catalog.properties                       
     Exception in thread "main" java.lang.NullPointerException
            at edu.yale.cs.hadoopdb.catalog.SimpleCatalogGenerator.parseArguments(SimpleCatalogGenerator.java:71)
            at edu.yale.cs.hadoopdb.catalog.SimpleCatalogGenerator.main(SimpleCatalogGenerator.java:54)
    [hduser@node1 lib]$
    I am completely clueless about this. As I cannot find the above mentioned packages(SimpleCatalogGenerator) anywhere .
    Can anyone please help me to solve this issue. It is very important for me.

    Thanks

  2. #2
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    SW Missouri
    Posts
    17,306
    Rep Power
    25

    Default Re: Classpath Nullpointer error

    Exception in thread "main" java.lang.NullPointerException
    at edu.yale.cs.hadoopdb.catalog.SimpleCatalogGenerato r.parseArguments(SimpleCatalogGenerator.java:71)
    The error message says that there is a variable at line 71 that has a null value when that line is executed.
    Look at line 71, find the variable with the null value and then backtrack to see why it does not have a valid value.
    If you don't understand my response, don't ignore it, ask a question.

  3. #3
    nnani is offline Member
    Join Date
    Feb 2013
    Posts
    3
    Rep Power
    0

    Default Re: Classpath Nullpointer error

    Hello,

    Which file to look for the line 71 in.I don't see the packages anywhere in the specified directory or on my system.

  4. #4
    Tolls is offline Moderator
    Join Date
    Apr 2009
    Posts
    11,817
    Rep Power
    19

    Default Re: Classpath Nullpointer error

    The code is in the jar file.
    Whether there is source code I have no idea.
    Please do not ask for code as refusal often offends.

    ** This space for rent **

  5. #5
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    SW Missouri
    Posts
    17,306
    Rep Power
    25

    Default Re: Classpath Nullpointer error

    Which file to look for the line 71 in
    The error message says this:
    SimpleCatalogGenerator.java:71
    If you don't understand my response, don't ignore it, ask a question.

  6. #6
    nnani is offline Member
    Join Date
    Feb 2013
    Posts
    3
    Rep Power
    0

    Default Re: Classpath Nullpointer error

    Hello,

    I wanted some more information on this.
    The quick start guide says just to download the hadoopdb.jar file and place it under $HADOOP_HOME/lib

    while the package contains two other files too.
    1. Catalog properties
    2. hadoopdb.jar
    3. SMS_dist.tar.gz ( Hive distribution )

    While there is one more tutorial on a famous blog which describes the following step like this

    Now we can download HadoopDB. I'm going to download both the jar file and check out the source from Subversion: Now we can download HadoopDB. After downloading the jar file, we need to copy it into Hadoop's lib directory so it has access to it:
    Java Code:
    cp hadoopdb.jar $HADOOP_HOME/lib
    I also checked out the source code from Subversion in case I needed to re-build the jar file at any time:
    Java Code:
    vn co https://hadoopdb.svn.sourceforge.net/svnroot/hadoopdb hadoopdb

    This is how the person describes the following step.
    Can you please tell me what difference does it make between the quick start guide step and the tutorial on blog step.

  7. #7
    Tolls is offline Moderator
    Join Date
    Apr 2009
    Posts
    11,817
    Rep Power
    19

    Default Re: Classpath Nullpointer error

    As far as running the code, nothing at all.
    The only thing the second one has is the downloading of the source files, which are not required to run the code.

    This is really not something we can handle here, we're a coding/development forum.
    Since this is not your code you will have to check with the people that wrote it as to why you are having problems.
    DarrylBurke likes this.
    Please do not ask for code as refusal often offends.

    ** This space for rent **

Similar Threads

  1. Replies: 1
    Last Post: 05-03-2011, 02:28 AM
  2. Classpath error
    By Arnokeh in forum New To Java
    Replies: 4
    Last Post: 04-03-2011, 05:35 PM
  3. NullPointer help
    By moosick in forum AWT / Swing
    Replies: 1
    Last Post: 04-02-2011, 02:35 AM
  4. Nullpointer error
    By teppel in forum New To Java
    Replies: 0
    Last Post: 07-10-2010, 08:38 PM
  5. Replies: 3
    Last Post: 08-14-2009, 12:57 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •