[APT] This Time Will Be The Charm

Support for Ubuntu and other Desktop Linux distributions
Post Reply
rammjet
Posts: 3
Joined: 25 Nov 2019, 16:43

[APT] This Time Will Be The Charm

Post by rammjet »

I've been running an old portable version of Filebot. I want to run the latest and will buy a lifetime license.

I have tried updating before and always ran into a problem. And this time as well. But let's get this working.

I have a headless server running Linux Mint 19.

I installed Filebot using APT with this method: viewtopic.php?f=11&t=6028

When I run Filebot, I get the java error:

Code: Select all

# filebot -version
Unrecognized option: --module-path
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
Where do I go next?
User avatar
rednoah
The Source
Posts: 23928
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: [APT] This Time Will Be The Charm

Post by rednoah »

1.
Unrecognized option: --module-path means that you're running on OpenJDK 8, and not OpenJDK 11, so you you need to use the OpenJDK 8 build & repository:
rednoah wrote: 13 Jul 2018, 12:00
  1. OpenJDK 11 build for newer Debian Buster / Ubuntu 18.10 platforms (noarch)

    Code: Select all

    deb [arch=all] https://get.filebot.net/deb/ universal main
  2. OpenJDK 8 build for older Debian Stretch / Ubuntu 18.04 platforms (noarch)

    Code: Select all

    deb [arch=all] https://get.filebot.net/deb/ universal-jdk8 main
:arrow: TL;DR the Java 11 build of FileBot doesn't work with Java 8. You'll need to either upgrade to Java 11, or use the Java 8 build of FileBot.


2.
Did you use the installer script? That should make the correct choices for you automatically:
rednoah wrote: 13 Jul 2018, 12:00 The installer/deb.sh will add the repository and install FileBot for you:

Code: Select all

bash -xu <<< "$(curl -fsSL https://raw.githubusercontent.com/filebot/plugins/master/installer/deb.sh)"
On Linux Mint 19, what is the output if you run this command?

Code: Select all

apt-cache show openjfx --no-all-versions
:idea: Please read the FAQ and How to Request Help.
rammjet
Posts: 3
Joined: 25 Nov 2019, 16:43

Re: [APT] This Time Will Be The Charm

Post by rammjet »

I ran the installer using:

Code: Select all

bash -xu <<< "$(curl -fsSL https://raw.githubusercontent.com/filebot/plugins/master/installer/deb.sh)"
apt-cache show openjfx --no-all-versions
results in:

Code: Select all

# apt-cache show openjfx --no-all-versions
Package: openjfx
Architecture: amd64
Version: 11.0.2+1-1~18.04.2
Priority: optional
Section: universe/java
Origin: Ubuntu
Maintainer: Debian Java Maintainers <[email protected]>
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
Installed-Size: 30
Depends: libopenjfx-java
Recommends: openjfx-source
Filename: pool/universe/o/openjfx/openjfx_11.0.2+1-1~18.04.2_amd64.deb
Size: 9032
MD5sum: a00d06f94dcfa8b579065f958dd76027
SHA1: d875edfa1ed5beb651dd8e90f8bea56c133e85af
SHA256: 0feec068c025efee496e34af33238422fc506fdbfcec6a4e334d228a07d38ea6
Homepage: https://openjfx.io
Description-en: JavaFX/OpenJFX - Rich client application platform for Java
 JavaFX/OpenJFX is a set of graphics and media APIs that enables Java developers
 to design, create, test, debug, and deploy rich client applications that
 operate consistently across diverse platforms.
Description-md5: c81023d9b26926c1219881c76843995a

N: There is 1 additional record. Please use the '-a' switch to see it
However:

Code: Select all

# which java
/usr/local/bin/java
This points to the java contained in the old portable Filebot installation which is Java 8.

So, I delete /usr/local/bin/java which is a symlink. And then:

Code: Select all

# which java
/usr/bin/java
# which filebot
/usr/bin/filebot
Good, but oh, oh:

Code: Select all

# filebot -version
Error: LinkageError occurred while loading main class net.filebot.Main
	java.lang.UnsupportedClassVersionError: net/filebot/Main has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 54.0
All right, found out that Mint 19 is based on Ubuntu 18.04. So, according to the Debian instructions for Filebot, I need Java 8.

Deleted Java 11 which automatically installed Java 8 (cool, I guess). Updated sources list and installed Filebot.

Now:

Code: Select all

# filebot -version
FileBot 4.8.5 (r6224) / Java(TM) SE Runtime Environment 1.8.0_221 / Linux 4.15.0-42-generic (amd64)
So, all is good right now. On to testing to find the next problem.

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

Re: [APT] This Time Will Be The Charm

Post by rednoah »

1.
If JavaFX 11 is available via APT, then I'm pretty sure Java 11 is available via APT as well:

Code: Select all

Package: openjfx
Architecture: amd64
Version: 11.0.2+1-1~18.04.2
:!: I'm not too familiar with packaging on different Linux distros though, and what versions of OpenJDK they prefer to install by default, or make available via APT.



2.
This error effectively translates to "JDK 10 can't run JDK 11 code":

Code: Select all

java.lang.UnsupportedClassVersionError: net/filebot/Main has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 54.0
:idea: https://www.baeldung.com/java-lang-unsu ... on-numbers
:idea: Please read the FAQ and How to Request Help.
rammjet
Posts: 3
Joined: 25 Nov 2019, 16:43

Re: [APT] This Time Will Be The Charm

Post by rammjet »

All issues seem to be resolved.

Downgraded to Java 8.
Reinstalled FileBot.
Added license.
Modified script.

Thank you.
Post Reply