Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
Sqoop >> mail # user >> Sqoop 1.4.2 checkout from trunk (installation problem) -sqoop 1.4.1 incompatible with MSSQL Server Connector


Copy link to this message
-
Re: Sqoop 1.4.2 checkout from trunk (installation problem) -sqoop 1.4.1 incompatible with MSSQL Server Connector
Hi Victor,

I was able to reproduce your error having the following connector file in
the manager.d dir (/etc/sqoop/conf/managers.d):

com.microsoft.sqoop.SqlServer.MSSQLServerManagerFactory

Can you please double-check if you have any file that doesn't contain
key-value pairs in the manager.d directory? If you do, that should be the
problem.

Thanks,
Cheolsoo
On Wed, Jun 27, 2012 at 9:01 AM, Cheolsoo Park <[EMAIL PROTECTED]>wrote:

> Hi Victor,
>
>         at org.apache.sqoop.ConnFactory.addManagersFromFile(
>> ConnFactory.java:152)
>
>
> I suspect that the error that you're seeing is a regression of
> SQOOP-505. Can you please what the content of your connector file looks
> like? For example,
>
>
> com.microsoft.sqoop.SqlServer.MSSQLServerManagerFactory=/usr/lib/sqoop/lib/sqoop-sqlserver-1.0.jar
>
> Thanks,
> Cheolsoo
>
>
> On Wed, Jun 27, 2012 at 8:32 AM, Victor Sanchez <[EMAIL PROTECTED]
> > wrote:
>
>>  Hi,
>>
>>
>>
>> I have a test cluster that runs RHEL6. I installed Cloudera Manager 4
>> (which includes CDH4). I had installed SQOOP.
>>
>>
>>
>> # sqoop version
>>
>> *Sqoop 1.4.1-cdh4.0.0*
>>
>> git commit id 44ef1bef07d93e3fcf79bdc1150de6c278ad7845
>>
>> Compiled by jenkins on Mon Jun  4 17:43:14 PDT 2012
>>
>>
>>
>> After all the installation configuration and stuff I ran into the problem
>> on not been able to sqoop import. I figured out that there is a bug for MS
>> SQL Connector for SQL Server 2008 R2 (
>> https://issues.apache.org/jira/browse/SQOOP-480).
>>
>>
>>
>> So I checkout the code
>>
>>
>>
>> 'svn co https://svn.apache.org/repos/asf/sqoop/trunk/ sqoop'
>>
>>
>>
>> And I build a project by executing ant. I got as a result (inside the
>> build folder) 2 jar files
>>
>>
>>
>> *sqoop-1.4.2-incubating-SNAPSHOT.jar*
>>
>> *sqoop-test-1.4.2-incubating-SNAPSHOT.jar***
>>
>>
>>
>> After all this I used this files for replacing the files in the instance
>> with the sqoop installation.
>>
>> So I removed the jar files in /usr/lib/sqoop/  (sqoop-1.4.1-cdh4.0.0.jar
>> and sqoop-test-1.4.1-cdh4.0.0.jar) replacing them with the files above.
>>
>>
>>
>> After that I get
>>
>> # sqoop version
>>
>> *Sqoop 1.4.2-incubating-SNAPSHOT*
>>
>> git commit id
>>
>> Compiled by victor.sanchez on Wed Jun 27 10:33:01 EDT 2012
>>
>>
>>
>> But when I tried to run the list-tables … it fails like this:
>>
>>
>>
>> # sqoop list-tables --connect
>> 'jdbc:sqlserver://hadooptest01;username=victor;password=victor;database=hadoopDB_SQL'
>>
>> *12/06/27 16:18:29 ERROR tool.BaseSqoopTool: Got error creating database
>> manager: java.lang.StringIndexOutOfBoundsException: String index out of
>> range: -1*
>>
>>         at java.lang.String.substring(String.java:1937)
>>
>>         at
>> org.apache.sqoop.ConnFactory.addManagersFromFile(ConnFactory.java:152)
>>
>>         at
>> org.apache.sqoop.ConnFactory.loadManagersFromConfDir(ConnFactory.java:224)
>>
>>         at
>> org.apache.sqoop.ConnFactory.instantiateFactories(ConnFactory.java:83)
>>
>>         at org.apache.sqoop.ConnFactory.<init>(ConnFactory.java:60)
>>
>>         at com.cloudera.sqoop.ConnFactory.<init>(ConnFactory.java:36)
>>
>>         at
>> org.apache.sqoop.tool.BaseSqoopTool.init(BaseSqoopTool.java:200)
>>
>>         at
>> org.apache.sqoop.tool.ListTablesTool.run(ListTablesTool.java:44)
>>
>>         at org.apache.sqoop.Sqoop.run(Sqoop.java:145)
>>
>>         at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70)
>>
>>         at org.apache.sqoop.Sqoop.runSqoop(Sqoop.java:181)
>>
>>         at org.apache.sqoop.Sqoop.runTool(Sqoop.java:220)
>>
>>         at org.apache.sqoop.Sqoop.runTool(Sqoop.java:229)
>>
>>         at org.apache.sqoop.Sqoop.main(Sqoop.java:238)
>>
>>         at com.cloudera.sqoop.Sqoop.main(Sqoop.java:57)
>>
>>
>>
>>
>>
>> Notice if I put back the “old” jar files sqoop list-tables works, but of
>> course the incompatibility bug (
>> https://issues.apache.org/jira/browse/SQOOP-480) is still there.
>>
>>
>>
>> If anyone has an idea of how to update my current sqoop installation with