Page 1 of 1

very very low script execution on rapsberry pi

Posted: 30 Jan 2015, 10:51
by bramsss
Hi,

I'm using filebot to sort my media on my raspberry pi. It works but the execution is very very slow (almost 15min !)

Do you have any idea why ? I have a good internet connection (80Mb/s download)

Here is the script.sh I launch:

Code: Select all

/usr/bin/filebot -script fn:amc /media/USBHDD1/Downloads/ --output /media/USBHDD1/ --log-file /var/log/amc.log --action hardlink --conflict skip -non-strict -unixfs --def xbmc=192.168.0.15 --def artwork=n --lang en --encoding UTF-8 --def ignore=".iso|txt|part01|part02|par1|par2" --def clean=y --def excludeList=/tmp/amc-input.txt
Thanks

Re: very very low script execution on rapsberry pi

Posted: 30 Jan 2015, 11:20
by rednoah
I could say Raspberry Pi is just really slow, and FileBot and the amc script are certainly not made or optimized for underpowered devices.

That being said, I'd start by looking into why it's being slow:

* Is CPU the bottleneck?

* Do you have enough memory?

It's either a slow CPU or you're running out of physical memory and it starts swapping all the time (which makes things extremely slow).

So how long does a simple script take?

Code: Select all

time filebot -script fn:sysinfo

Re: very very low script execution on rapsberry pi

Posted: 30 Jan 2015, 12:05
by bramsss
Thanks, here is the result. I have a 32Go fast sd card (80Mb/s writing data which is the fastest in the market)

Code: Select all

pi@raspberrypi ~ $ time filebot -script fn:sysinfo
Jan 30, 2015 1:01:48 PM net.sf.ehcache.store.disk.DiskStorageFactory <init>
WARNING: The index for data file /usr/share/filebot/data/cache/0/web-datasource-lv3.data is out of date, probably due to an unclean shutdown. Deleting index file /usr/share/filebot/data/cache/0/web-datasource-lv3.index
Jan 30, 2015 1:01:52 PM net.sf.ehcache.store.disk.DiskStorageFactory <init>
WARNING: The index for data file /usr/share/filebot/data/cache/0/web-datasource.data is out of date, probably due to an unclean shutdown. Deleting index file /usr/share/filebot/data/cache/0/web-datasource.index


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: /usr/share/filebot/lib7-Zip-JBinding.so: /usr/share/filebot/lib7-Zip-JBinding.so: cannot open shared object file: No such file or directory (Possible cause: can't load IA 32-bit .so on a ARM-bit platform)
chromaprint-tools: java.io.IOException: Cannot run program "fpcalc": error=2, No such file or directory
Extended Attributes: DISABLED
Groovy Engine: 2.3.7
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 / 14 MB Used Memory
OS: Linux (arm)
uname: Linux raspberrypi 3.12.35+ #730 PREEMPT Fri Dec 19 18:31:24 GMT 2014 armv6l GNU/Linux

--- UPDATE AVAILABLE: FileBot 4.5.6 (r2818) ---

Done ヾ(@⌒ー⌒@)ノ

real	2m20.708s
user	0m45.710s
sys	0m11.360s

Re: very very low script execution on rapsberry pi

Posted: 31 Jan 2015, 19:04
by rednoah
Looks like that just initializing the scripting engine is pretty bad on that machine. Memory (RAM) looks fine, so I guess it just doesn't work well on slow armv6l machines.

Please not that if memory is an issue (if you're processing a large amount of files in a single call) and it starts swapping to a "fast" 80 MB/s drive, then the kind of drive won't matter compared to 5 GB/s and up read/write speeds of typical main memory. ;)