Reply
New Contributor
Posts: 2
Registered: ‎10-07-2018

The formatting on the Manual Instruction page for LZO Configuration results in Errors [ New ]

I successfully installed LZO as described at the bottom of the cloudera instructions here.

 

I configured the core-site.xml file as described here which copy and pasted, is:

 

  <property>
    <name>io.compression.codecs</name>
  <value>
org.apache.hadoop.io.compress.DefaultCodec,org.apache.hadoop.io.compress.GzipCodec,
org.apache.hadoop.io.compress.BZip2Codec,com.hadoop.compression.lzo.LzoCodec,com.hadoop.compression.lzo.LzopCodec,
org.apache.hadoop.io.compress.SnappyCodec
  </value>
  </property>

This results in:

 

java.lang.RuntimeException: Error in configuring object

at ...

Caused by: java.lang.IllegalArgumentException: Compression codec
org.apache.hadoop.io.compress.DefaultCodec not found.
        at org.apache.hadoop.io.compress.CompressionCodecFactory.getCodecClasses(CompressionCodecFactory.java:134)
        at org.apache.hadoop.io.compress.CompressionCodecFactory.<init>(CompressionCodecFactory.java:174)
        at org.apache.hadoop.mapred.TextInputFormat.configure(TextInputFormat.java:38)
        ... 34 more
Caused by: java.lang.ClassNotFoundException: Class
org.apache.hadoop.io.compress.DefaultCodec not found
        at org.apache.hadoop.conf.Configuration.getClassByName(Configuration.java:1680)
        at org.apache.hadoop.io.compress.CompressionCodecFactory.getCodecClasses(CompressionCodecFactory.java:127)


Searching Google told me to modify the core-site.xml file by removing line breaks and white spaces, which I have copied and pasted here:

 

  <property>
    <name>io.compression.codecs</name>
 <value>org.apache.hadoop.io.compress.DefaultCodec,org.apache.hadoop.io.compress.GzipCodec,org.apache.hadoop.io.compress.BZip2Codec,com.hadoop.compression.lzo.LzoCodec,com.hadoop.compression.lzo.LzopCodec,org.apache.hadoop.io.compress.SnappyCodec</value>
  </property>

This solves the problem.

 

Interestingly, even if you do:

 

  <property>
    <name>io.compression.codecs</name>
 <value>org.apache.hadoop.io.compress.DefaultCodec,org.apache.hadoop.io.compress.GzipCodec,org.apache.hadoop.io.compress.BZip2Codec,com.hadoop.compression.lzo.LzoCodec,com.hadoop.compression.lzo.LzopCodec,org.apache.hadoop.io.compress.SnappyCodec

</value>
  </property>

It will result in a Class Not Found error for the SnappyCodec.

Announcements