java.lang.NoClassDefFoundError: com/sun/jna/Platform with FileBot 4.9.0 and Fedora 31

Any questions? Need some help?
Post Reply
tacoloco
Posts: 8
Joined: 09 Apr 2016, 01:03

java.lang.NoClassDefFoundError: com/sun/jna/Platform with FileBot 4.9.0 and Fedora 31

Post by tacoloco » 16 Mar 2020, 16:08

FileBot 4.8.5 worked fine. Unfortunately, I can't get this new version to work.

I am running openjdk-1.8.0

Does this error output help clarify my problem?

Thanks!

Code: Select all

Rename movies using [TheMovieDB]
Auto-detect movie from context [/storage/samba/videos/Movies/Dogtown.and.Z-Boys.2001.720p.BluRay.H264.AAC-RARBG/Dogtown.and.Z-Boys.2001.720p.BluRay.H264.AAC-RARBG..mp4]
com/sun/jna/Platform
java.lang.NoClassDefFoundError: com/sun/jna/Platform
	at net.filebot.MetaAttributeView.<init>(Unknown Source)
	at net.filebot.media.MetaAttributes.<init>(Unknown Source)
	at net.filebot.media.XattrMetaInfo.xattr(Unknown Source)
	at net.filebot.media.XattrMetaInfo.lambda$getXattrValue$0(Unknown Source)
	at com.github.benmanes.caffeine.cache.BoundedLocalCache.lambda$doComputeIfAbsent$14(BoundedLocalCache.java:2380)
	at com.github.benmanes.caffeine.cache.BoundedLocalCache.doComputeIfAbsent(BoundedLocalCache.java:2378)
	at com.github.benmanes.caffeine.cache.BoundedLocalCache.computeIfAbsent(BoundedLocalCache.java:2361)
	at com.github.benmanes.caffeine.cache.LocalCache.computeIfAbsent(LocalCache.java:108)
	at com.github.benmanes.caffeine.cache.LocalManualCache.get(LocalManualCache.java:62)
	at net.filebot.media.XattrMetaInfo.getXattrValue(Unknown Source)
	at net.filebot.media.XattrMetaInfo.getMetaInfo(Unknown Source)
	at net.filebot.media.MediaDetection.detectMovie(Unknown Source)
	at net.filebot.media.MediaDetection.detectMovieWithYear(Unknown Source)
	at net.filebot.cli.CmdlineOperations.renameMovie(Unknown Source)
	at net.filebot.cli.CmdlineOperations.rename(Unknown Source)
	at net.filebot.cli.ArgumentProcessor.runCommand(Unknown Source)
	at net.filebot.cli.ArgumentProcessor.run(Unknown Source)
	at net.filebot.Main.main(Unknown Source)
Caused by: java.lang.ClassNotFoundException: com.sun.jna.Platform
	... 18 more

Error (o_O)

User avatar
rednoah
The Source
Posts: 17864
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: java.lang.NoClassDefFoundError: com/sun/jna/Platform with FileBot 4.9.0 and Fedora 31

Post by rednoah » 16 Mar 2020, 16:22

How exactly did you install FileBot? Did you perhaps somehow suppress auto-install of recommended dependencies?
https://www.filebot.net/linux/yum.html

Here's all the dependencies that should be installed automatically:

Code: Select all

Recommends:     java-1.8.0-openjdk
Recommends:     java-1.8.0-openjdk-openjfx
Recommends:     jna
Recommends:     mediainfo
Recommends:     p7zip
Recommends:     p7zip-plugins
:idea: According to the error message, jna is missing.
:idea: Please read the FAQ and How to Request Help.

tacoloco
Posts: 8
Joined: 09 Apr 2016, 01:03

Re: java.lang.NoClassDefFoundError: com/sun/jna/Platform with FileBot 4.9.0 and Fedora 31

Post by tacoloco » 16 Mar 2020, 16:33

I installed from your repository.

Here are the rpms mentioned in your post:

Code: Select all

[email protected] /etc/yum.repos.d $ rpm -qa | grep java   
javapackages-filesystem-5.3.0-6.fc31.noarch
tzdata-java-2019c-2.fc31.noarch
java-1.8.0-openjdk-1.8.0.242.b08-0.fc31.x86_64
javapackages-tools-5.3.0-6.fc31.noarch
python3-javapackages-5.3.0-6.fc31.noarch
java-1.8.0-openjdk-openjfx-1.8.0.242.b08-0.fc31.x86_64
java-1.8.0-openjdk-headless-1.8.0.242.b08-0.fc31.x86_64
[email protected] /etc/yum.repos.d $ rpm -qa | grep jna 
jna-contrib-4.5.1-9.module_f31+6793+1c93c38e.noarch
jna-4.5.1-9.module_f31+6793+1c93c38e.x86_64
[email protected] /etc/yum.repos.d $ rpm -qa | grep mediainfo
mediainfo-19.09-1.fc31.x86_64
libmediainfo-19.09-1.fc31.x86_64
[email protected] /etc/yum.repos.d $ rpm -qa | grep p7zip    
p7zip-16.02-15.fc31.x86_64
p7zip-plugins-16.02-15.fc31.x86_64
[email protected] /etc/yum.repos.d $
It looks to me that jna is there.

User avatar
rednoah
The Source
Posts: 17864
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: java.lang.NoClassDefFoundError: com/sun/jna/Platform with FileBot 4.9.0 and Fedora 31

Post by rednoah » 16 Mar 2020, 16:36

1.
What does this say?

Code: Select all

ls -la /usr/share/filebot/jar/jna.jar

2.
What does this say?

Code: Select all

find /usr/lib -name jna.jar
:idea: Please read the FAQ and How to Request Help.

tacoloco
Posts: 8
Joined: 09 Apr 2016, 01:03

Re: java.lang.NoClassDefFoundError: com/sun/jna/Platform with FileBot 4.9.0 and Fedora 31

Post by tacoloco » 16 Mar 2020, 16:39

Code: Select all

[email protected] /etc/yum.repos.d $ ls -la /usr/share/filebot/jar/jna.jar
ls: cannot access '/usr/share/filebot/jar/jna.jar': No such file or directory
[email protected] /etc/yum.repos.d $ find /usr/lib -name jna.jar
/usr/lib/java/jna.jar
/usr/lib/java/jna/jna.jar
[email protected] /etc/yum.repos.d 

User avatar
rednoah
The Source
Posts: 17864
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: java.lang.NoClassDefFoundError: com/sun/jna/Platform with FileBot 4.9.0 and Fedora 31

Post by rednoah » 16 Mar 2020, 18:08

Strange.

Here's what the post install script is supposed to be doing, which somehow didn't happen for you:

Code: Select all

ln -sf /usr/lib/java/jna.jar /usr/share/filebot/jar/jna.jar
:idea: Please read the FAQ and How to Request Help.

tacoloco
Posts: 8
Joined: 09 Apr 2016, 01:03

Re: java.lang.NoClassDefFoundError: com/sun/jna/Platform with FileBot 4.9.0 and Fedora 31

Post by tacoloco » 16 Mar 2020, 18:36

Thanks, rednoah, that did the trick!

User avatar
rednoah
The Source
Posts: 17864
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: java.lang.NoClassDefFoundError: com/sun/jna/Platform with FileBot 4.9.0 and Fedora 31

Post by rednoah » 16 Mar 2020, 18:39

I can only imagine jna was somehow not installed already when you installed filebot. I've updated installer/rpm.sh script to make sure that can't happen.
:idea: Please read the FAQ and How to Request Help.

360andy
Posts: 4
Joined: 21 Mar 2020, 23:09

Re: java.lang.NoClassDefFoundError: com/sun/jna/Platform with FileBot 4.9.0 and Fedora 31

Post by 360andy » 21 Mar 2020, 23:12

Hey I am having the same issue on Linux Mint 19.3.

Any help would be appreciated.

Thanks

Andy

User avatar
rednoah
The Source
Posts: 17864
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: java.lang.NoClassDefFoundError: com/sun/jna/Platform with FileBot 4.9.0 and Fedora 31

Post by rednoah » 22 Mar 2020, 06:18

How did you install FileBot?
https://www.filebot.net/linux/apt.html


1.
What does this say?

Code: Select all

ls -la /usr/share/filebot/jar/jna.jar

2.
What does this say?

Code: Select all

find /usr/lib -name jna.jar
:idea: Please read the FAQ and How to Request Help.

Post Reply