Description

 This page provides solution to the error  " java.lang.NoClassDefFoundError:sun/io/ByteTocharConverter Caused by :java.lang.ClassNotFoundException"  which is encountered while choosing schema under Schema to extract or during the DB2 UDB Extraction step if the schema to extract has been added manually.

 

The complete stack is as shown below :

An error has occurred during command processing
---
java.lang.NoClassDefFoundError:sun/io/ByteToCharConverter
at com.ibm.db2.jcc.b.r.a(r.java:159)
at com.ibm.db2.jcc.a.d.a(d.java:1009)
at com.ibm.db2.jcc.a.db.a(db.java:1723)
at com.ibm.db2.jcc.a.db.a(db.java:1651)
at com.ibm.db2.jcc.a.db.n(db.java:570)
at com.ibm.db2.jcc.a.db.j(db.java:257)
at com.ibm.db2.jcc.a.db.c(db.java:57)
at com.ibm.db2.jcc.a.r.c(r.java:42)
at com.ibm.db2.jcc.a.sb.h(sb.java:169)
at com.ibm.db2.jcc.b.zc.p(zc.java:1223)
at com.ibm.db2.jcc.b.zc.a(zc.java:1859)
at com.ibm.db2.jcc.b.zc.a(zc.java:497)
at com.ibm.db2.jcc.b.zc.executeQuery(zc.java:481)
at com.castsoftware.connection.JdbcConnection.executeQuery(JdbcConnection.java:817)
...
Caused by java.lang.ClassNotFoundException:sun.io.ByteToCharConverter
at java.net.URLClassLoader.findClass(:0)
at java.lang.ClassLoader.loadClass(:0)
at java.lang.ClassLoader.loadClass(:0)
at com.ibm.db2.jcc.b.r.a(r.java:159)
at com.ibm.db2.jcc.a.d.a(d.java:1009)
at com.ibm.db2.jcc.a.db.a(db.java:1723)
at com.ibm.db2.jcc.a.db.a(db.java:1651)
at com.ibm.db2.jcc.a.db.n(db.java:570)
at com.ibm.db2.jcc.a.db.j(db.java:257)
at com.ibm.db2.jcc.a.db.c(db.java:57)

Observed in CAST AIP
Release
Yes/No
8.3.x(tick)
8.2.x(tick)
8.1.x(tick)
8.0.x(tick) 
7.3.x(tick)
7.2.x(tick)
7.0.x(error)
Observed on RDBMS
This section is not applicable for this page(DMT)

 

RDBMS
Yes/No
Oracle ServerNA
Microsoft SQL ServerNA
CSS2NA
CSS1NA
Step by Step Scenario
  1. Open DMT from AIC Portal
  2. Configure DB2 UDB using the option "Live connection to your DB2 UDB Server".
  3. Enter the DB2 details and add manually the list of schema to extract.
  4. Click package.
  5. The packaging fails at the Extraction step.
Action Plan
  1. This issue occurs because the file ByteToCharConverter class does not exist in your <Your Java Folder>\lib\rt.jar file that is in your Java Installation folder.
  2. Close the DMT.
  3. To check that point, open the rt.jar as an archive file (using an archiver utility like 7z or Winrar)
  4. Go to the folder sun\io\. The file ByteToCharConverter.class file does not exist :



  5. If it does not exist you must add the db2jcc4.jar jar file in your <JAVA INSTALLATION FOLDER>\jre<version>\lib\ext
  6. Open the DMT
  7. Package the DB2 UDB schema again.
  8. If the issue still exists use the JAVA Version 7 instead of the one installed on your machine.
  9. If the issue still occurs, contact CAST Technical Support with the Relevant Input
Notes/comments
 Ticket # 2108 / 10315
Related Pages