Re: Unexpected end of input stream

Brian Ehmann <[email protected]>
Newsgroups gmane.comp.db.mysql.java
Message-ID <[email protected]>
Huh, I was afraid I was asking a dumb question.

On Mac os X, there is a java extensions folder in /Library/Java/ 
Extensions.  I found the offending jar in that folder.  As soon as I  
removed it, everything was fine.

- Brian

On Oct 3, 2006, at 10:48 AM, Mark Matthews wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Brian Ehmann wrote:
>> First let me say I am sorry if this is a duplicate.  I've searched  
>> the
>> archives and have found similar questions, but no answers.
>>
>> I just upgraded to MySql 5 (from 4) by installing the following  
>> package
>> on my machine (mac os x 10.4.7)
>> mysql-max-5.0.24a-osx10.4-powerpc.dmg
>>
>> I am able to connect to the database using the included command line
>> client, however when I try to connect
>> using any of the following version of the connector jar, I get an
>> exception. (using ant, I have ensured that only the
>> connector jar I am trying to test is on the classpath).
>>
>> mysql-connector-java-3.0.16-ga-bin.jar
>> mysql-connector-java-5.0.3-bin.jar
>>
>> Has anyone figured this out?
>>
>> Thanks,
>>
>> Brian
>>
>>
>> PS: The Exception:
>>
>> java.sql.SQLException: Communication link failure:  
>> java.io.IOException,
>> underlying cause: Unexpected end of input stream
>>
>> ** BEGIN NESTED EXCEPTION **
>>
>> java.io.IOException
>> MESSAGE: Unexpected end of input stream
>>
>> STACKTRACE:
>>
>> java.io.IOException: Unexpected end of input stream
>>     at com.mysql.jdbc.MysqlIO.readPacket(MysqlIO.java:1073)
>>     at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:619)
>>     at com.mysql.jdbc.Connection.createNewIO(Connection.java:1511)
>>     at com.mysql.jdbc.Connection.<init>(Connection.java:485)
>>     at com.mysql.jdbc.Driver.connect(Driver.java:341)
>>     at java.sql.DriverManager.getConnection(DriverManager.java:512)
>>     at java.sql.DriverManager.getConnection(DriverManager.java:171)
>>     at JDBCTest.main(JDBCTest.java:13)
>
> Brian,
>
> It looks like you're picking up a much older version of the driver  
> (one
> that doesn't understand the 4.1 and newer protocol). I can tell from
> your stack trace, since more modern drivers don't have  
> Driver.connect(),
> Driver extends NonRegisteringDriver and connect() is in there, as well
> as the fact that you'd be down in a method named secureAuth411() if  
> the
> driver was connecting to a newer version of the server...so your stack
> trace doesn't line up with what any of our drivers that are recent do.
>
> Have you checked jre/lib/ext and friends for any JDBC driver versions
> you aren't expecting?
>
> 	-Mark
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.2.2 (MingW32)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFFIngntvXNTca6JD8RAgB0AJ9sNMOPv0c0tvcMH/RgDTBJ6kVivwCcD8UM
> u7+a7R8GCir5iVIvEN3K92k=
> =76VU
> -----END PGP SIGNATURE-----


-- 
MySQL Java Mailing List
For list archives: http://lists.mysql.com/java
To unsubscribe:    http://lists.mysql.com/[email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.