Page 1 of 1

Error with ISO unpack script

Posted: April 4th, 2019, 8:29 am
by kallek
I found this script for "unpacking" iso-files after download is finished:

Code: Select all

#!/bin/sh

cd "$1"
mkdir unpack
cd unpack
# pwd

7z x ../*.iso
7z x ../*.ISO

7z x ../*/*.iso
7z x ../*/*.ISO
I'm trying to run it on my QNAP NAS but get the following error: "7-Zip cannot find the code that works with archives".

Sabnzbd is installed with the sherpa-script. Do I have to install something else to make it work?

Re: Error with ISO unpack script

Posted: April 4th, 2019, 12:19 pm
by sander
"7-Zip cannot find the code that works with archives" ... when I google that, it's all about 7zip on Windows ...

So: where are you running 7z on?

Re: Error with ISO unpack script

Posted: April 5th, 2019, 12:59 am
by kallek
sander wrote: April 4th, 2019, 12:19 pm "7-Zip cannot find the code that works with archives" ... when I google that, it's all about 7zip on Windows ...

So: where are you running 7z on?
I'm running the script on the Qnap NAS so 7zip is also running on the NAS. I found this thread with someone getting the same error on a QNAP:

https://forum.qnap.com/viewtopic.php?t=119147

I will try to call 7zip by it's full path as suggested in that post.

Re: Error with ISO unpack script

Posted: April 5th, 2019, 1:15 am
by OneCD
@kallek, you might also check which 7zips are available. It seems QTS Busybox contains one version, but you should also have an Entware version installed. The order they are found depends on your $PATH. The 'default' is the first one found.

Code: Select all

type -a 7z
Which one is shown first?

Re: Error with ISO unpack script

Posted: April 5th, 2019, 1:28 pm
by kallek
OneCD wrote: April 5th, 2019, 1:15 am @kallek, you might also check which 7zips are available. It seems QTS Busybox contains one version, but you should also have an Entware version installed. The order they are found depends on your $PATH. The 'default' is the first one found.

Code: Select all

type -a 7z
Which one is shown first?
When I run type - 7z I get:

Code: Select all

7z is /usr/local/sbin/7z

7-Zip [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21
p7zip Version 16.02 (locale=en_US.UTF-8,Utf16=on,HugeFiles=on,64 bits,4 CPUs x64
If I run the script with the full path it kind of works but I get a warning about "There are data after the end of archive".

I'm trying to unpack a bluray iso but all I get is some strange files. Guess it unpacks some hidden partition with metadata, not visable to Windows. Maybe 7zip doesn't work very well with bluray isos.

Re: Error with ISO unpack script

Posted: April 5th, 2019, 1:59 pm
by sander
If you want, you can share the NZB with me, so that I try on my Linux.

Re: Error with ISO unpack script

Posted: April 5th, 2019, 2:37 pm
by OneCD
I've just had a look at the p7zip IPKG installed via Entware. It's identical to the version installed with QTS except the Entware version is executed with '7za'.

Sorry, I'm out of ideas. :(