Awesome software you have here. Must have been a lot of your hardwork put into it. Thank you, Good sir.
Hardware is QNAP - TS212P , 2 bay NAS running Debian 8. It has an ARMv5 processor. I use it as my NAS and download station and also a bit of home automation. By default all my custom services run under user "dload", a near admin user.
Code: Select all
root@GrayNAS:/# cat /etc/debian_version
8.2
root@GrayNAS:/# uname -a
Linux GrayNAS 4.3.0-0.bpo.1-kirkwood #1 Debian 4.3.3-5~bpo8+1 (2016-01-07) armv5tel GNU/Linux
Code: Select all
root@GrayNAS:~# java -version
java version "1.8.0_65"
Java(TM) SE Embedded Runtime Environment (build 1.8.0_65-b17, headless)
Java HotSpot(TM) Embedded Client VM (build 25.65-b01, mixed mode)
Code: Select all
root@GrayNAS:/opt/filebot# ./filebot.sh -script fn:sysinfo
FileBot 4.6.1 (r3454)
JNA Native: /opt/filebot/data/root/temp/jna-3506402/jna8892473533402168105.tmp: /opt/filebot/data/root/temp/jna-3506402/jna8892473533402168105.tmp: cannot open shared object file: No such file or directory
MediaInfo: java.lang.NoClassDefFoundError: Could not initialize class com.sun.jna.Native
7-Zip-JBinding: net.sf.sevenzipjbinding.SevenZipNativeInitializationException: Failed to load 7z-JBinding: no 7-Zip-JBinding in java.library.path
Chromaprint: fpcalc version 1.2.0 (fpcalc)
Extended Attributes: OK
Groovy Engine: 2.4.5
JRE: Java(TM) SE Embedded Runtime Environment 1.8.0_65 (headless)
JVM: 32-bit Java HotSpot(TM) Embedded Client VM
CPU/MEM: 1 Core / 121 MB Max Memory / 9 MB Used Memory
OS: Linux (arm)
Package: PORTABLE
Data: /opt/filebot/data/root
uname: Linux GrayNAS 4.3.0-0.bpo.1-kirkwood #1 Debian 4.3.3-5~bpo8+1 (2016-01-07) armv5tel GNU/Linux
Done ヾ(@⌒ー⌒@)ノ
Code: Select all
ADD_ARGS="$ADD_ARGS-Djna.debug_load.jna=true "
ADD_ARGS="$ADD_ARGS-Djna.library.path=$APP_ROOT -Djava.library.path=$APP_ROOT "
Code: Select all
root@GrayNAS:/opt/filebot# ./filebot.sh -script fn:sysinfo
FileBot 4.6.1 (r3454)
Trying (via loadLibrary) jnidispatch
Found jnidispatch on system path
JNA Native: Can't obtain updateLastError method for class com.sun.jna.Native
MediaInfo: java.lang.NoClassDefFoundError: Could not initialize class com.sun.jna.Native
7-Zip-JBinding: 9.20
Chromaprint: fpcalc version 1.2.0 (fpcalc)
Extended Attributes: OK
Groovy Engine: 2.4.5
JRE: Java(TM) SE Embedded Runtime Environment 1.8.0_65 (headless)
JVM: 32-bit Java HotSpot(TM) Embedded Client VM
CPU/MEM: 1 Core / 121 MB Max Memory / 9 MB Used Memory
OS: Linux (arm)
Package: PORTABLE
Data: /opt/filebot/data/root
uname: Linux GrayNAS 4.3.0-0.bpo.1-kirkwood #1 Debian 4.3.3-5~bpo8+1 (2016-01-07) armv5tel GNU/Linux
Done ヾ(@⌒ー⌒@)ノ
But still the same errors were popping up, Filebot either finds an old version with updateLastError or incompatible linux-arm lib inside the jar.
Finally when i was abt to give up, I tried a temporary solution, I replaced the com/libjnidispatch.so as an experiment.
Code: Select all
jar uf FileBot.jar com/sun/jna/linux-arm/libjnidispatch.so


Code: Select all
root@GrayNAS:/opt/filebot# ./filebot.sh -script fn:sysinfo
FileBot 4.6.1 (r3454)
Looking in classpath from sun.misc.Launcher$AppClassLoader@10dea4e for /com/sun/jna/linux-arm/libjnidispatch.so
Found library resource at jar:file:/opt/filebot/FileBot.jar!/com/sun/jna/linux-arm/libjnidispatch.so
Trying /opt/filebot/data/root/temp/jna-3506402/jna8017015433184415889.tmp
Found jnidispatch at /opt/filebot/data/root/temp/jna-3506402/jna8017015433184415889.tmp
JNA Native: 4.0.1
MediaInfo: MediaInfoLib - v0.7.70
7-Zip-JBinding: 9.20
Chromaprint: fpcalc version 1.2.0 (fpcalc)
Extended Attributes: OK
Groovy Engine: 2.4.5
JRE: Java(TM) SE Embedded Runtime Environment 1.8.0_65 (headless)
JVM: 32-bit Java HotSpot(TM) Embedded Client VM
CPU/MEM: 1 Core / 121 MB Max Memory / 9 MB Used Memory
OS: Linux (arm)
Package: PORTABLE
Data: /opt/filebot/data/root
uname: Linux GrayNAS 4.3.0-0.bpo.1-kirkwood #1 Debian 4.3.3-5~bpo8+1 (2016-01-07) armv5tel GNU/Linux
Done ヾ(@⌒ー⌒@)ノ
I went in reverse and verified there are no old files and verified paths and all. Still i am not sure why filebot is not able to find the system libs. I dont want to modifiy the jar file but rather keep it untouched for updates.
My filebot.sh ->
Code: Select all
#!/bin/sh
PRG="$0"
# resolve relative symlinks
while [ -h "$PRG" ] ; do
ls=`ls -ld "$PRG"`
link=`expr "$ls" : '.*-> \(.*\)$'`
if expr "$link" : '/.*' > /dev/null; then
PRG="$link"
else
PRG="`dirname "$PRG"`/$link"
fi
done
# make it fully qualified
WORKING_DIR=`pwd`
PRG_DIR=`dirname "$PRG"`
APP_ROOT=`cd "$PRG_DIR" && pwd`
# restore original working dir
cd "$WORKING_DIR"
# user per user app data location to avoid permission conflicts between root and admin users
APP_DATA="$APP_ROOT/data/$USER"
# add APP_ROOT to LD_LIBRARY_PATH
if [ ! -z "$LD_LIBRARY_PATH" ]
then
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$APP_ROOT"
else
export LD_LIBRARY_PATH="$APP_ROOT"
fi
# force JVM language and encoding settings
export LANG="en_US.UTF-8"
export LC_ALL="en_US.UTF-8"
ADD_ARGS=" "
ADD_ARGS="$ADD_ARGS-Djna.debug_load.jna=true "
#ADD_ARGS="$ADD_ARGS-Djna.library.path=$APP_ROOT -Djava.library.path=$APP_ROOT "
# ADD_ARGS="$ADD_ARGS-verbose:class "
ADD_ARGS="$ADD_ARGS-Djna.nosys=true "
# FileBot settings
EXTRACTOR="SevenZipNativeBindings" # use the lib7-Zip-JBinding.so native library
# EXTRACTOR="SevenZipExecutable" # use the 7z executable
# EXTRACTOR="ApacheVFS" # use Apache Commons VFS2 with junrar plugin
java $JAVA_OPTS \
-Djna.library.path="$APP_ROOT" \
-Djava.library.path=="$APP_ROOT" \
-Dunixfs=false \
-DuseGVFS=false \
-DuseExtendedFileAttributes=true \
-DuseCreationDate=false \
-Dfile.encoding="UTF-8" \
-Djava.net.useSystemProxies=false \
-Dsun.net.client.defaultConnectTimeout=10000 \
-Dsun.net.client.defaultReadTimeout=60000 \
-Dapplication.deployment=portable \
-Dnet.filebot.Archive.extractor="$EXTRACTOR" \
-Dnet.filebot.AcoustID.fpcalc="fpcalc" \
-Dapplication.dir="$APP_DATA" \
-Djava.io.tmpdir="$APP_DATA/temp" \
-Duser.home="$APP_DATA" \
-Djava.util.prefs.PreferencesFactory=net.filebot.util.prefs.FilePreferencesFactory \
-Dnet.filebot.util.prefs.file="$APP_DATA/prefs.properties" \
$ADD_ARGS \
-jar \
"$APP_ROOT/FileBot.jar" "$@"