Java.lang.NoSuchMethodError : org. apache.commons.io.FileUtils.isSymLink(Ljava/io/File;)Z

Java.lang.NoSuchMethodError : org. apache.commons.io.FileUtils.isSymLink(Ljava/io/File;)Z … here is a solution to the problem.

Java.lang.NoSuchMethodError : org. apache.commons.io.FileUtils.isSymLink(Ljava/io/File;)Z

I encounter this error when using sqoop (master) to import data from Oracle DB located on a different machine (i.e. slave). I also replaced the commons.io.jar file.

Solution

This has nothing to do with any particular library. This is a general exception in Java

The question is simple. The method is available at compile time, but not at run time.

One of the reasons may be that you are using the wrong version of the public library. Just open the jar file in any zip viewer and go to the specific location where you can find the class, which will be similar to
org/apache/commons/io/FileUtils and decompiles the class with some class decompiler and checks if the method isSymLink(Ljava/io/File;)Z compiler prompts that the class is available.

It is also possible that there are methods, but the method signatures are different

Related Problems and Solutions