Page 1 of 1
[GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 12 Nov 2013, 12:05
by Lukeid
:: THIS GUIDE IS OUTDATED ::
Hello,
I have spent a lot of time trying to get Filebot with mediainfo working on my Raspberry Pi.
I've read some post but none of them provided a full solution. So this post is to help others, because I finally got it working.
These are the main steps you will need to do:
+ Install JAVA 8
+ Install Filebot v3.8
+ Configure Filebot for Raspberry Pi
+ Install JNA 4.0.0
+ Configure JNA links
+ Install MediaInfo
+ Configure MediaInfo links
+ Test it works
And the detailed step by step:
+ Install JAVA 8 (get latest JAVA ARMv6 from
https://jdk8.java.net/download.html)
Code: Select all
$ wget --no-check-certificate http://www.java.net/download/jdk8/archive/b108/binaries/jdk-8-ea-b108-linux-arm-vfp-hflt-18_sep_2013.tar.gz
$ sudo tar zxvf jdk-8-ea-b108-linux-arm-vfp-hflt-18_sep_2013.tar.gz -C /opt
$ sudo ln -s /opt/jdk1.8.0/bin/java /usr/bin/java
$ /opt/jdk1.8.0/bin/java -version
+ Install Filebot v3.8
Code: Select all
$ wget http://sourceforge.net/projects/filebot/files/filebot/FileBot_3.8/filebot_3.8_arm.ipk/download
$ mv filebot_3.8_arm.ipk /tmp/filebot
$ cd /tmp/filebot
$ ar -x filebot_3.8_arm.ipk
$ tar zxvf data.tar.gz
$ sudo cp -r opt/usr/share/* /usr/share/
$ sudo ln -s /usr/share/filebot/bin/filebot.sh /usr/bin/filebot
+ Configure Filebot for Raspberry Pi
Code: Select all
$ cd /usr/share/filebot/bin
$ sudo cp –p filebot.sh filebot.sh_old
$ sudo nano /usr/share/filebot/bin/filebot.sh
#!/bin/sh
java -Dunixfs=false -DuseExtendedFileAttributes=false -Dfile.encoding=UTF-8 -Dsun.net.client.defaultConnectTimeout=10000 -Dsun.net.client.defaultReadTimeout=60000 -Dapplication.deployment=ipkg -Dapplication.analytics=true -Duser.home=/usr/share/filebot/data -Dapplication.dir=/usr/share/filebot/data -Djava.io.tmpdir=/usr/share/filebot/data/temp -Djna.library.path=/usr/share/filebot -Djava.library.path=/usr/share/filebot -Dnet.sourceforge.filebot.AcoustID.fpcalc=fpcalc -jar -Xmx400M /usr/share/filebot/FileBot.jar "$@"
+ Install JNA 4.0.0
Code: Select all
$ sudo apt-get install libjna-java
$ mkdir /tmp/jna-4.0.0
$ cd /tmp/jna-4.0.0
$ wget https://maven.java.net/content/repositories/releases/net/java/dev/jna/jna/4.0.0/jna-4.0.0.jar
$ wget https://maven.java.net/content/repositories/releases/net/java/dev/jna/jna-platform/4.0.0/jna-platform-4.0.0.jar
+ Configure JNA links
Code: Select all
$ cd /tmp/jna-4.0.0
$ /opt/jdk1.8.0/bin/jar xf jna-4.0.0.jar
$ cd /usr/lib/jni
$ sudo cp -p /tmp/jna-4.0.0/com/sun/jna/linux-arm/libjnidispatch.so libjnidispatch_4.0.0.so
$ sudo mv libjnidispatch.so libjnidispatch_3.2.7.so
$ sudo ln -s libjnidispatch_4.0.0.so libjnidispatch.so
$ cd /usr/share/java
$ sudo rm jna.jar
$ sudo rm jna-platform.jar
$ sudo cp /tmp/jna-4.0.0/*.jar .
$ sudo ln -s jna-4.0.0.jar jna.jar
$ sudo ln -s jna-platform-4.0.0.jar jna-platform.jar
$ java -jar jna-jar
Java Native Access (JNA) API Version 4
Version: 4.0.0 (b2)
Native: 4.0.0 (1a6047467b59e8748f975e03016ce3d9)
Prefix: linux-arm
+ Install MediaInfo
+ Configure MediaInfo links
Code: Select all
$ cd /usr/share/filebot
$ sudo mv libzen.so libzen.so_old
$ sudo mv libmediainfo.so libmediainfo.so_old
$ sudo ln -s /usr/lib/arm-linux-gnueabihf/libmediainfo.so libmediainfo.so
$ sudo ln -s /usr/lib/arm-linux-gnueabihf/libzen.so libzen.so
+ Test it works
Code: Select all
$ sudo filebot -script "fn:sysinfo"
FileBot 3.8 (r1808)
chromaprint-tools: <ERROR>
JNA Native: 4.0.0
MediaInfo: MediaInfoLib - v0.7.58
7-Zip-JBinding: <ERROR>
Extended Attributes: DISABLED
Java(TM) SE Runtime Environment 1.8.0-ea (headless)
32-bit Java HotSpot(TM) Client VM
Linux (arm)
Done ヾ(@⌒ー⌒@)ノ
Hope this helps.
Edited: Removed "-Xms400M" option from filebot.sh
Re: Filebot + MediaInfo + Raspberry Pi
Posted: 12 Nov 2013, 14:50
by rednoah
Good work!
I'd only comment on the JVM memory settings:
You're making the JVM hog 400M right on initialization. I recommend not setting -Xms and let the JVM scale up memory as needed. It'll rarely ever need more than 70-80M anyway.
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 22 May 2014, 18:59
by beck2929
Some minor typographic mistakes:
+ Install Filebot v3.8 section
a) if you use that wget command you get a file named "download" instead of "filebot_3.8_arm.ipk"
b)
Code: Select all
$ mv filebot_3.8_arm.ipk /tmp/filebot
has to be changed in
Code: Select all
$ mv filebot_3.8_arm.ipk /tmp/filebot/filebot_3.8_arm.ipk
upon creation of the filebot folder
c)
and
commands need sudo
+ Configure JNA links section
a) change
in
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 02 Aug 2014, 15:07
by rwickra
Hi guys,
I used this guide to install Filebot on my Raspberry Pi. The whole installation went quite well. The only caveat that I found was that filebot was installed on step 1, not on /opt/usr/share but rather on /opt/share -- which I then correctly copied into /usr/share.
The problem is that even after directly copy/pasting everything and installing and configuring MediaLink, I am getting a MediaLink error. Below is what I get when I execute sysinfo.
I don't quite understand what it means that it cannot find the native library in the resource path. (and why is it looking at a .Jar file for the library)? The libraries it is referencing are present in /usr/share/filebot
Code: Select all
rasi@sepalika ~ $ sudo filebot -script "fn:sysinfo"
FileBot 4.2 (r2326)
JNA Native: 4.0.0
MediaInfo: java.lang.UnsatisfiedLinkError: Unable to load library 'mediainfo': Native library (linux-arm/libmediainfo.so) not found in resource path ([file:/usr/share/filebot/FileBot.jar])
7-Zip-JBinding: net.sf.sevenzipjbinding.SevenZipNativeInitializationException: Failed to load 7z-JBinding: /usr/share/filebot/lib7-Zip-JBinding.so: /usr/share/filebot/lib7-Zip-JBinding.so: cannot open shared object file: No such file or directory
chromaprint-tools: java.io.IOException: Cannot run program "fpcalc": error=2, No such file or directory
Extended Attributes: DISABLED
Groovy Engine: 2.3.4
JRE: Java(TM) SE Runtime Environment 1.8.0-ea (headless)
JVM: 32-bit Java HotSpot(TM) Client VM
CPU/MEM: 1 Core / 386 MB Max Memory / 10 MB Used Memory
OS: Linux (arm)
uname: Linux sepalika 3.12.22+ #691 PREEMPT Wed Jun 18 18:29:58 BST 2014 armv6l GNU/Linux
Done ヾ(@⌒ー⌒@)ノ
In fact, my /usr/share/filebot directory has the following files, all with full accessibility permissions (777)
Code: Select all
Bin data FileBot.jar fpcalc lib7-Zip-JBinding.so libmediainfo.so libzen.so
Any ideas?
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 02 Aug 2014, 16:46
by rednoah
System error messages about native libraries are generally misleading. If it says "can't find" it may mean "can't find one that can be loaded".
Check the filebot.sh script and check the jna.library.path property and make sure it points to the folder where the libraries are. If it doesn't work then it's because the libraries simply are not compatible with your platform. There's a good chances the binaries are only compatible with armv7hf and won't work on armv6.
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 21 Sep 2014, 08:03
by chuckbell3
To correct this issue I installed the mediainfo-dev...
MediaInfo: java.lang.UnsatisfiedLinkError: Unable to load library 'mediainfo': Native library (linux-arm/libmediainfo.so) not found in resource path ([file:/usr/share/filebot/FileBot.jar])
I also didn't have to link the files.
Hope that helps
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 30 Sep 2014, 15:54
by p4tch3r
What do you mean with "installed the mediainfo-dev"? Can you explain that. I have the same problem.
Thanks a lot....
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 06 Nov 2014, 16:39
by daddyfix
I had the same problem with MediaInfo.
Error
Code: Select all
MediaInfo: java.lang.UnsatisfiedLinkError: Unable to load library 'mediainfo': Native library (linux-arm/libmediainfo.so) not found in resource path ([file:/usr/share/filebot/FileBot.jar])
HW: Raspberry Pi Model B+
OS: Raspbian (minimal) Debian
[Solution]
MediaInfo: libmediainfo.so and libzen.so have .0 in filename.
Code: Select all
sudo ln -s /usr/lib/arm-linux-gnueabihf/libmediainfo.so.0 libmediainfo.so
sudo ln -s /usr/lib/arm-linux-gnueabihf/libzen.so.0 libzen.so
Code: Select all
$ filebot -script "fn:sysinfo"
FileBot 4.5 (r2612)
JNA Native: 4.0.0
MediaInfo: MediaInfoLib - v0.7.58
7-Zip-JBinding: net.sf.sevenzipjbinding.SevenZipNativeInitializationException: Failed to load 7z-JBinding: no 7-Zip-JBinding in java.library.path
chromaprint-tools: fpcalc version 1.1.0 (/usr/share/filebot/fpcalc)
Extended Attributes: OK
Groovy Engine: 2.3.7
JRE: Java(TM) SE Runtime Environment 1.8.0_06 (headless)
JVM: 32-bit Java HotSpot(TM) Client VM
CPU/MEM: 1 Core / 118 MB Max Memory / 8 MB Used Memory
OS: Linux (arm)
uname: Linux PiMedia 3.12.26+ #707 PREEMPT Sat Aug 30 17:39:19 BST 2014 armv6l GNU/Linux
Done ヾ(@⌒ー⌒@)ノ
Thanks for Filebot! I love it!
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 23 Dec 2014, 14:51
by Derpowa
Hello, I followed the guide and everything looked fine (jna working, java working, etc.). But at filebot testing, I get this error (see below), any ideas? Thanks.
Java working:

JNA working:

Filebot error:

Thanks a lot for the job.
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 23 Dec 2014, 18:49
by rednoah
Filebot v3.8 is no longer supported. Please use the latest version.
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 23 Dec 2014, 23:49
by Derpowa
rednoah wrote:Filebot v3.8 is no longer supported. Please use the latest version.
Thanks! That worked, but now I get fpcalc error, says it's missing...
root@kyosuke:/home/pi# filebot -script "fn:sysinfo"
FileBot 4.5.3 (r2729)
JNA Native: 4.0.0
MediaInfo: MediaInfoLib - v0.7.58
7-Zip-JBinding: net.sf.sevenzipjbinding.SevenZipNativeInitializationException: Failed to load 7z-JBinding: no 7-Zip-JBinding in java.library.path
dic 24, 2014 12:46:58 AM java.util.prefs.FileSystemPreferences$1 run
INFORMACIÓN: Created user preferences directory.
chromaprint-tools: java.io.IOException: Cannot run program "fpcalc": error=2, No existe el fichero o el directorio(directory or file missing)
Extended Attributes: DISABLED
Groovy Engine: 2.3.7
JRE: Java(TM) SE Runtime Environment 1.8.0_06 (headless)
JVM: 32-bit Java HotSpot(TM) Client VM
CPU/MEM: 1 Core / 386 MB Max Memory / 7 MB Used Memory
OS: Linux (arm)
uname: Linux kyosuke 3.12.31 #2 PREEMPT Wed Oct 29 09:24:56 UTC 2014 armv6l GNU/Linux
Done ヾ(@⌒ー⌒@)ノ
root@kyosuke:/home/pi#
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 24 Dec 2014, 02:43
by rednoah
This guide doesn't show how to comiple 7z jbindings nor fpcalc for ARM6 arch. No one has figured those out yet ...
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 14 Feb 2015, 19:42
by fbot25
Hey so I was following along with this guide using raspbmc on my rpi (got filebot 4.5.6 ipk instead of 3.8) and all was going well until when I tried the final step to see if it all worked I got this
Code: Select all
{myusername}@raspbmc:/usr/share/filebot$ sudo filebot -script "fn:sysinfo"
Exception in thread "main" java.lang.UnsupportedClassVersionError: net/filebot/Main : Unsupported major.minor version 52.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:643)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:277)
at java.net.URLClassLoader.access$000(URLClassLoader.java:73)
at java.net.URLClassLoader$1.run(URLClassLoader.java:212)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
at java.lang.ClassLoader.loadClass(ClassLoader.java:323)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:268)
Could not find the main class: net.filebot.Main. Program will exit.
same thing happened when I tried the command from home directory. Anything in here jump out and say what the problem is and any way I can fix it? I'm a bit out of my depths at this point.
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 25 Feb 2015, 01:38
by rednoah
You're not using Java 8. Please use Java 8. See FAQ.
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 29 Mar 2015, 06:57
by damagu
How up to date is this guide? Would it apply to a rpi2 with OSMC? If not, can someone give me any idea of what needs to change from this guide to make it applicable to rpi2+OSMC
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 31 Mar 2015, 22:22
by cramejo
I just installed it and it works for me with the latest OSMC version (RC)
This is how it works:
Download and install Java
http://download.oracle.com/otn-pub/java ... flt.tar.gz
unpack to /opt/
Code: Select all
sudo tar zxvf jdk-8-linux-arm-vfp-hflt.tar.gz -C /opt
Set update-alternatives for java and javac:
Code: Select all
sudo update-alternatives --install /usr/bin/javac javac /opt/jdk1.8.0_33/bin/javac 1
Code: Select all
sudo update-alternatives --install /usr/bin/java java /opt/jdk1.8.0_33/bin/java 1
select the 1.8 version when/if prompted:
Code: Select all
sudo update-alternatives --config javac
Code: Select all
sudo update-alternatives --config java
If everything worked, you should have 1.8 java now:
Download and install filebot
download the latest arm version of filebot:
http://sourceforge.net/projects/filebot ... k/download
Use 7zip or something similar to unpack it. Unpack the .tar inside. Then copy the filebot folder inside the other folders to your pi.
On your pi, go to the folder you copied the filebot folder to. Then move the filebot folder to /user/share/filebot
edit the filebot.sh file:
Code: Select all
sudo nano /usr/share/filebot/bin/filebot.sh
This might not be the optimal script, but it works for me. Change the script to the following:
Code: Select all
#!/bin/sh
java -Dunixfs=false -DuseExtendedFileAttributes=false -Dsun.net.client.defaultConnectTimeout=10000 -Dsun.net.client.defaultReadTimeout=60000 -Dapplication.deployment=ipkg -Dapplication.analytics=true -Duser.home=/usr/share/filebot/data -Dapplication.dir=/usr/share/filebot/data -Djava.io.tmpdir=/usr/share/filebot/data/temp -Djna.library.path=/usr/share/filebot -Djava.library.path=/usr/share/filebot -jar -Xms400M -Xmx400M /usr/share/filebot/FileBot.jar "$@"
Link the filebot script to your bin folder
Code: Select all
sudo ln -s /usr/share/filebot/bin/filebot.sh /usr/bin/filebot
Install mediainfo
Go to the filebot folder and move not working filebot libraries:
Code: Select all
mv libmediainfo.so libmediainfo.soold
Link the working ones:
Code: Select all
sudo ln -s /usr/lib/arm-linux-gnueabihf/libmediainfo.so.0 libmediainfo.so
Code: Select all
sudo ln -s /usr/lib/arm-linux-gnueabihf/libzen.so.0 libmediainfo.so
check if it works:
This is my output:
FileBot 4.5.6 (r2818)
JNA Native: 4.0.0
MediaInfo: MediaInfoLib - v0.7.70
7-Zip-JBinding: net.sf.sevenzipjbinding.SevenZipNativeInitializationException: Failed to load 7z-JBinding: no 7-Zip-JBinding in java.library.path
chromaprint-tools: java.io.IOException: Cannot run program "fpcalc": error=2, No such file or directory
Extended Attributes: DISABLED
Groovy Engine: 2.3.9
JRE: Java(TM) SE Runtime Environment 1.8.0_33 (headless)
JVM: 32-bit Java HotSpot(TM) Client VM
CPU/MEM: 4 Core / 386 MB Max Memory / 64 MB Used Memory
OS: Linux (arm)
uname: Linux osmc 3.18.9-5-osmc #1 SMP PREEMPT Wed Mar 11 18:59:35 UTC 2015 armv7l GNU/Linux
Done ?(?????)?
There have been many disputes about the filebot.sh file on the raspberry pi. I am using the RPi2 and I have just used my old script.
I hope this works for you. I stole this from many different quides and made my own modifications. While I would like to credit the ops, I don't remember who they were.
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 01 Apr 2015, 10:20
by damagu
Thank you very much for taking the time to post the instructions above. I got it working too but there were problems which I struggled with along the way.
First (I think) there are a few typo errors in your instructions:
1) Because you linked to
http://download.oracle.com/otn-pub/java ... flt.tar.gz, shouldn't this:
Code: Select all
sudo tar zxvf jdk-8-linux-arm-vfp-hflt.tar.gz -C /opt
be this:
Code: Select all
sudo tar zxvf jdk-8u33-linux-arm-vfp-hflt.tar.gz -C /opt
2) Also there's an error here:
it should be this:
3) And this didn't work:
Code: Select all
sudo ln -s /usr/lib/arm-linux-gnueabihf/libzen.so.0 libmediainfo.so
I'm pretty sure it's meant to say:
Code: Select all
sudo ln -s /usr/lib/arm-linux-gnueabihf/libzen.so.0 libzen.so
Apart from these changes, I also struggled with:
- downloading java and filebot from CLI. Because there were no commands for this in your instructions I had to figure it out myself and it took a while because, while I knew about wget already, I didn't realise I needed the "--no-check-certificate" bit.
- unpacking the ipk file. I had to download and install p7zip and work out how to use it before I could move on.
- when I got to your last step "sudo filebot -script "fn:sysinfo"", I got command not found error because I also needed to change permissions on filebot.sh to make it executable.
To you, these things might be really obvious. For me, having only cursory knowledge of the command line and having not used it for years, I only just managed to piece it all together. However, other people might not have even my basic level of knowledge and might not get it working without more info.
These are not complaints though; just feedback in the interest of improving and completing the instructions.
Thanks again

Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 16 Apr 2015, 11:56
by Gutz-Pilz
1. Install java
#download
http://www.oracle.com/technetwork/java/ ... 87472.html
Code: Select all
tar zxvf jdk-8u33-linux-arm-vfp-hflt.gz -C /opt
update-alternatives --install /usr/bin/javac javac /opt/jdk1.8.0_33/bin/javac 1
update-alternatives --install /usr/bin/java java /opt/jdk1.8.0_33/bin/java 1
update-alternatives --config javac
update-alternatives --config java
2. Install filebot:
Code: Select all
mkdir /tmp/filebot && cd /tmp/filebot
wget http://sourceforge.net/projects/filebot/files/filebot/FileBot_4.5.6/filebot_4.5.6_arm.ipk/
ar -x filebot_3.8_arm.ipk
tar zxvf data.tar.gz
cp -r opt/share/* /usr/share/
ln -s /usr/share/filebot/bin/filebot.sh /usr/bin/filebot
3. Install JNA 4.0.0
Code: Select all
apt-get install libjna-java
mkdir /tmp/jna-4.0.0
cd /tmp/jna-4.0.0
wget --no-check-certificate https://maven.java.net/content/repositories/releases/net/java/dev/jna/jna/4.0.0/jna-4.0.0.jar
wget --no-check-certificate https://maven.java.net/content/repositories/releases/net/java/dev/jna/jna-platform/4.0.0/jna-platform-4.0.0.jar
cd /tmp/jna-4.0.0
/opt/jdk1.8.0/bin/jar xf jna-4.0.0.jar
cd /usr/lib/jni
cp -p /tmp/jna-4.0.0/com/sun/jna/linux-arm/libjnidispatch.so libjnidispatch_4.0.0.so
mv libjnidispatch.so libjnidispatch_3.2.7.so
ln -s libjnidispatch_4.0.0.so libjnidispatch.so
cd /usr/share/java
rm jna.jar
rm jna-platform.jar
cp /tmp/jna-4.0.0/*.jar .
ln -s jna-4.0.0.jar jna.jar
ln -s jna-platform-4.0.0.jar jna-platform.jar
java -jar jna.jar
4. Install Mediainfo:
Code: Select all
apt-get install mediainfo
cd /usr/share/filebot
mv libzen.so libzen.soold
mv libmediainfo.so libmediainfo.soold
ln -s /usr/lib/arm-linux-gnueabihf/libmediainfo.so.0 libmediainfo.so
ln -s /usr/lib/arm-linux-gnueabihf/libzen.so.0 libzen.so
5. Install 7-Zip JBinding for pi
Code: Select all
cd cd /usr/share/filebot/
wget http://hannesmueller.com/lib7-Zip-JBinding.so
6. Check
Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 31 Aug 2015, 12:18
by caragato
Hello!
I do really want to install filebot on mi raspberry pi with OSMC but, I have some problems.
I have followed this guide with some changes:
1.Install Java
I´ve done tha t with this videotutorial
https://www.youtube.com/watch?v=8N6hYNj_QzY
2.Install filebot
(Just like you say)
mkdir /tmp/filebot && cd /tmp/filebot
wget
http://sourceforge.net/projects/filebot ... 6_arm.ipk/
ar -x filebot_3.8_arm.ipk
tar zxvf data.tar.gz
cp -r opt/share/* /usr/share/
ln -s /usr/share/filebot/bin/filebot.sh /usr/bin/filebot
3.Install JNA 4.0.0
I have a problem here: "cd /usr/lib/jni"
Because I have no this folder!!!
Please can you help me????

Re: [GUIDE] Filebot + MediaInfo + Raspberry Pi
Posted: 01 Sep 2015, 06:33
by Gutz-Pilz