[19. June 2013] Soundcloud® available now | [7. June 2013] Youporn available now | [11 Jan. 2013] Customize your A-400 Home Screen

Firmware: A-400 [13 May 2013] | C-300 [30 Nov. 2012] | A-300 [30 Nov. 2012] | C-200 RC1 [13 June 2013] | A-200/A-210 RC1 [13 June 2013]

Just got your NMT | WIKI has the answers | Search the forum | Forum Rules/Policy | Firmware & Official NMT News | Popcornhour manuals



User(s) browsing this thread: 1 Guest(s)
Thread Closed 
NZBGet won't unpack rar-files
10-07-2009, 08:06 PM (This post was last modified: 10-07-2009 08:08 PM by Dvz.)
Post: #1
NZBGet won't unpack rar-files
Hi guys,

I'm using NZBGet to download stuff from usenet to my NMT. So far so good, all goes well including repairing, but somehow it won't unpack my files.

This is how the config file (unrar.sh) looks:

Code:
#! /bin/sh
DownloadDir="$1"  
NzbFile="$2"
ParCheck=$4
NzbState=$5  
ParFail=$6

# Make a logfile
log="$DownloadDir"/unrar.log
export PATH=$PATH:/opt/sybhttpd/localhost.drives/HARD_DISK/Download

# Check if all is downloaded and repaired
if [ "$NzbState" -eq 1 -a "$ParCheck" -eq 2 -a "$ParFail" -eq 0 ]
then
   cd "$DownloadDir"

# Make a temporary directory to store the unrarred files
   mkdir extracted
  
# Remove the Par files
   rm *.[pP][aA][rR]2
  
# Pause NZBGet download until script finishes
   /mnt/syb8634/bin/nzbget -P -c /opt/sybhttpd/localhost.drives/HARD_DISK/.nzbget/nzbget.conf
  
# Unrar the files (if any) to the temporary directory, if there are no rar files this will do nothing
      if (ls *.rar >/dev/null)
   then
   /mnt/syb8634/bin/unrar x -y -p- -o+ "*.rar"  ./extracted/
   fi
  
# Remove the rar files (Temporaly disabled just remove # to activate it)
#   rm *.r[0-9][0-9]
#   rm *.rar
#   rm *.s[0-9][0-9]
  
# Go to the temp directory and try to unrar again.  
# If there are any rars inside the extracted rars then these will no also be unrarred
   cd extracted
   if (ls *.rar >/dev/null)
   then
   /mnt/syb8634/bin/unrar x -y -p- -o+ "*.rar"
   fi
  
# Delete the Rar files (Temporaly disabled just remove # to activate it)
   rm *.r[0-9][0-9]
   rm *.rar
   rm *.s[0-9][0-9]
  
# Move everything back to the Download folder
   mv * ..
   cd ..
  
# Clean up the temp folder
   rmdir extracted
   chmod -R a+rw .
   rm *.nzb
   rm *.1

# Rename img file to iso so the NMT can read it
# It will be renamed to .img.iso so you can see that it has been renamed
   if (ls *.img >/dev/null)
   then
   imgname=`find . -name "*.img" |awk -F/ '{print $NF}'`
   mv $imgname $imgname.iso
   fi  
  
  
# Unpause NZBGet
   /mnt/syb8634/bin/nzbget -U -c /opt/sybhttpd/localhost.drives/HARD_DISK/.nzbget/nzbget.conf

fi  
#################

When I use the above config, I'm getting the following message: (after repairing has been succesfully done)

DETAIL Wed, 07 Oct 2009 18:48:29 +0000 Post-Process: /bin/sh: can't open
INFO Wed, 07 Oct 2009 18:48:29 +0000 Completed post-process-script for test/test
INFO Wed, 07 Oct 2009 18:48:29 +0000 Cleaning up download queue for test(1)

Apparently the first row in the config file "#! /bin/sh" is creating this problem, so I tried removing it. This generates another error message:

Post-Process: unpak.sh: applet not found

So I'm kinda stuck right now. Anyone knows what the problem is and how to fix the config-file?

(ps. is there a way to manually unpack the files that I have already download? I tried to connect to my NMT using Telnet, but somehow I can't get connected)
Find all posts by this user
10-08-2009, 06:05 AM
Post: #2
RE: NZBGet won't unpack rar-files
In another thread I read that it may be caused by opening and saving the file with notepad, so the layout has been modified.

Does anyone happen to have the original unrar.sh somewhere for me to try?
Find all posts by this user
10-08-2009, 08:33 AM
Post: #3
RE: NZBGet won't unpack rar-files
Why don't you install Oversight, it will auto configure you conf files and will also extract shows to a TV folder and films to a Movie folder.

If you dont want the jukebox functions of Oversight just untick "boot at startup" in the CSI.

Dont use windows noetpad for editing these files, use somthing like Notepad++, its free

My Popcorn Hour A110 Trakt.tv (TESTING)
[Image: watched-fanart.jpg]
Community Software Installer - For All Your User Apps
PchTrakt - Millers Mods Download

A-400 - Onkyo TX SR608 AV receiver, C-200, A110
Find all posts by this user
10-08-2009, 01:14 PM (This post was last modified: 10-08-2009 01:21 PM by Dvz.)
Post: #4
RE: NZBGet won't unpack rar-files
Mmm, well actually I don't know why. Probably because I never really dug into it and don't really know what Oversight can do for me.

I will look into it further tonight, thanks.
Find all posts by this user
10-08-2009, 01:24 PM
Post: #5
RE: NZBGet won't unpack rar-files
You could map to the drive of the NMT from a PC and unpack through the PC.
Find all posts by this user
10-08-2009, 07:18 PM
Post: #6
RE: NZBGet won't unpack rar-files
I know, only this takes (literally) hours.. Can't I do it through NMT by using Telnet or something?
Find all posts by this user
10-08-2009, 08:06 PM (This post was last modified: 10-08-2009 08:55 PM by joshua.lyon.)
Post: #7
RE: NZBGet won't unpack rar-files
(10-08-2009 07:18 PM)Dvz Wrote:  I know, only this takes (literally) hours.. Can't I do it through NMT by using Telnet or something?

Yes you can do it by telnet. As someone else mentioned above, I would recommend installing Oversight (movie jukebox) which installs the latest version of unpak.sh and configures it for use with NZBget.

It's an enhanced unpacking script which can also move the files based on their content type (eg. TV shows -> TV, Movies -> Videos, etc) as well as a number of other nice features.

Unpak.sh is one of those "set it and forget it" type apps. It works really well and I rarely (if ever) have issues with it.

NewzBook - Automatic Newzbin bookmark fetcher, Newzbin search, and NZBget interface (mobile phone friendly)
http://boshdirect.com - my website / blog about technology, automotive, and general interests.
Find all posts by this user
10-09-2009, 10:13 AM (This post was last modified: 10-09-2009 10:14 AM by Dvz.)
Post: #8
RE: NZBGet won't unpack rar-files
OK, so I installed the newest version of NZBGet using CSI. All works fine now according to the log, but after the whole process has been completed, I can't see the downloaded files anywhere?? Also during the whole process I couldn't find them anywhere, even though the download dir has been set to \Share\Download.

Here is the (almost complete) log:

Code:
INFO Fri, 09 Oct 2009 09:09:31 +0000 Unpausing queue after post- process- script
INFO Fri, 09 Oct 2009 09:09:31 +0000 post- process- script for heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL sucessful
INFO Fri, 09 Oct 2009 09:09:31 +0000 Completed post- process- script for heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL
INFO Fri, 09 Oct 2009 09:09:31 +0000 Post- Process: Cleaning up
INFO Fri, 09 Oct 2009 09:09:31 +0000 Post- Process: mv: cannot rename '*. nzb': No such file or directory
INFO Fri, 09 Oct 2009 09:09:31 +0000 Moving downloaded nzb- files into incoming nzb- directory for further download
INFO Fri, 09 Oct 2009 09:09:31 +0000 Post- Process: /share/Apps/NZBget/postprocess. sh: line 254: wc: not found
INFO Fri, 09 Oct 2009 09:09:30 +0000 Post- Process: /share/Apps/NZBget/postprocess. sh: line 253: wc: not found
INFO Fri, 09 Oct 2009 09:09:29 +0000 Post- Process: Deleting rar- files
INFO Fri, 09 Oct 2009 09:09:29 +0000 Post- Process: All OK
INFO Fri, 09 Oct 2009 09:09:29 +0000 Post- Process: . . . Heroes. S04E03. HDTV. XvID- FQM_ NL. avi 63% OK
[.....]
INFO Fri, 09 Oct 2009 09:05:23 +0000 Post- Process: Extracting from Heroes. S04E03. HDTV. XvID- FQM_ NL. part06. rar
INFO Fri, 09 Oct 2009 09:05:23 +0000 Post- Process: . . . Heroes. S04E03. HDTV. XvID- FQM_ NL. avi 24% 25% 26%
INFO Fri, 09 Oct 2009 09:05:03 +0000 Post- Process: Extracting from Heroes. S04E03. HDTV. XvID- FQM_ NL. part05. rar
INFO Fri, 09 Oct 2009 09:05:03 +0000 Post- Process: . . . Heroes. S04E03. HDTV. XvID- FQM_ NL. avi 21% 22% 23%
INFO Fri, 09 Oct 2009 09:04:42 +0000 Post- Process: Extracting from Heroes. S04E03. HDTV. XvID- FQM_ NL. part04. rar
INFO Fri, 09 Oct 2009 09:04:42 +0000 Post- Process: . . . Heroes. S04E03. HDTV. XvID- FQM_ NL. avi 18% 19% 20%
INFO Fri, 09 Oct 2009 09:04:23 +0000 Post- Process: Extracting from Heroes. S04E03. HDTV. XvID- FQM_ NL. part03. rar
INFO Fri, 09 Oct 2009 09:04:23 +0000 Post- Process: . . . Heroes. S04E03. HDTV. XvID- FQM_ NL. avi 15% 16% 17%
INFO Fri, 09 Oct 2009 09:04:01 +0000 Post- Process: Extracting from Heroes. S04E03. HDTV. XvID- FQM_ NL. part02. rar
INFO Fri, 09 Oct 2009 09:04:01 +0000 Post- Process: Extracting . /extracted/Heroes. S04E03. HDTV. XvID- FQM_ NL. avi 11% 12% 13% 14%
INFO Fri, 09 Oct 2009 09:03:42 +0000 Post- Process: Extracting from Heroes. S04E03. HDTV. XvID- FQM_ NL. part01. rar
INFO Fri, 09 Oct 2009 09:03:42 +0000 Post- Process: UNRAR 3. 80 freeware Copyright (c) 1993- 2008 Alexander Roshal
INFO Fri, 09 Oct 2009 09:03:42 +0000 Post- Process: Unraring
INFO Fri, 09 Oct 2009 09:03:41 +0000 Post- Process: Post- process script successfully started
INFO Fri, 09 Oct 2009 09:03:41 +0000 Executing post- process- script for heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL
INFO Fri, 09 Oct 2009 09:03:41 +0000 Successfully repaired heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL
INFO Fri, 09 Oct 2009 09:03:28 +0000 Verifying repaired file Heroes. S04E03. HDTV. XvID- FQM_ NL. part02. rar
INFO Fri, 09 Oct 2009 09:03:16 +0000 Verifying repaired file Heroes. S04E03. HDTV. XvID- FQM_ NL. part01. rar
INFO Fri, 09 Oct 2009 08:59:50 +0000 Repairing heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL
INFO Fri, 09 Oct 2009 08:59:50 +0000 File Heroes. S04E03. HDTV. XvID- FQM_ NL. vol03+04. PAR2 successfully loaded for par- check
INFO Fri, 09 Oct 2009 08:59:49 +0000 Verifying file Heroes. S04E03. HDTV. XvID- FQM_ NL. vol03+04. PAR2
INFO Fri, 09 Oct 2009 08:59:49 +0000 Successfully downloaded heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL. vol03+04. PA2
INFO Fri, 09 Oct 2009 08:59:48 +0000 Need more 4 par- block(s) for heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL
INFO Fri, 09 Oct 2009 08:59:48 +0000 File Heroes. S04E03. HDTV. XvID- FQM_ NL. vol00+01. PAR2 successfully loaded for par- check
INFO Fri, 09 Oct 2009 08:59:47 +0000 Verifying file Heroes. S04E03. HDTV. XvID- FQM_ NL. vol00+01. PAR2
INFO Fri, 09 Oct 2009 08:59:47 +0000 Successfully downloaded heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL. vol00+01. PAR2
INFO Fri, 09 Oct 2009 08:59:44 +0000 Unpausing heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL. vol00+01. PAR2 for par- recovery
INFO Fri, 09 Oct 2009 08:59:44 +0000 Unpausing heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL. vol03+04. PAR2 for par- recovery
INFO Fri, 09 Oct 2009 08:59:44 +0000 Need more 5 par- block(s) for heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL
[.....]
INFO Fri, 09 Oct 2009 08:56:43 +0000 Verifying file Heroes. S04E03. HDTV. XvID- FQM_ NL. part03. rar
WARNING Fri, 09 Oct 2009 08:56:43 +0000 File Heroes. S04E03. HDTV. XvID- FQM_ NL. part02. rar has 1 bad block(s) of total 33 block(s)
INFO Fri, 09 Oct 2009 08:56:31 +0000 Verifying file Heroes. S04E03. HDTV. XvID- FQM_ NL. part02. rar
WARNING Fri, 09 Oct 2009 08:56:31 +0000 File Heroes. S04E03. HDTV. XvID- FQM_ NL. part01. rar has 4 bad block(s) of total 33 block(s)
INFO Fri, 09 Oct 2009 08:56:15 +0000 Verifying file Heroes. S04E03. HDTV. XvID- FQM_ NL. part01. rar
INFO Fri, 09 Oct 2009 08:56:05 +0000 Loading file Heroes. S04E03. HDTV. XvID- FQM_ NL. par2
INFO Fri, 09 Oct 2009 08:56:04 +0000 Verifying heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL
INFO Fri, 09 Oct 2009 08:56:04 +0000 Checking pars for heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL
INFO Fri, 09 Oct 2009 08:56:04 +0000 Pausing queue before par- check
INFO Fri, 09 Oct 2009 08:56:04 +0000 Unpausing queue after post- process- script
INFO Fri, 09 Oct 2009 08:56:04 +0000 Queueing heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL for par- check
INFO Fri, 09 Oct 2009 08:56:04 +0000 post- process- script for heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL requested par- check/repair for all collections
INFO Fri, 09 Oct 2009 08:56:04 +0000 Completed post- process- script for heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL
INFO Fri, 09 Oct 2009 08:56:04 +0000 Post- Process: Requesting par- repair

ERROR Fri, 09 Oct 2009 08:56:04 +0000 Post- Process: Unrar failed
INFO Fri, 09 Oct 2009 08:56:04 +0000 Post- Process: Total errors: 1
INFO Fri, 09 Oct 2009 08:56:04 +0000 Post- Process: Extracting from Heroes. S04E03. HDTV. XvID- FQM_ NL. part18. rar
[....]
INFO Fri, 09 Oct 2009 08:55:56 +0000 Post- Process: Extracting from Heroes. S04E03. HDTV. XvID- FQM_ NL. part01. rar
INFO Fri, 09 Oct 2009 08:55:56 +0000 Post- Process: UNRAR 3. 80 freeware Copyright (c) 1993- 2008 Alexander Roshal
INFO Fri, 09 Oct 2009 08:55:56 +0000 Post- Process: Unraring
INFO Fri, 09 Oct 2009 08:55:55 +0000 Post- Process: Post- process script successfully started
INFO Fri, 09 Oct 2009 08:55:55 +0000 Executing post- process- script for heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL
INFO Fri, 09 Oct 2009 08:55:55 +0000 Pausing queue before post- process- script
INFO Fri, 09 Oct 2009 08:55:55 +0000 Queueing heroes seizoen(2)/Heroes. S04E03. HDTV. XvID- FQM_ NL for par- check
INFO Fri, 09 Oct 2009 08:55:55 +0000 Collection heroes seizoen(2) completely downloaded

Anyone knows where it stores the downloaded files? This is getting kinda frustrating by now Sad
Find all posts by this user
10-09-2009, 11:18 AM
Post: #9
RE: NZBGet won't unpack rar-files
The files should be in "\share\Download\heroes seizoen(2)", if you didn't change the paths in the config file.
It's better to check the option "DstDir" via web-interface.
Visit this user's website Find all posts by this user
10-09-2009, 01:50 PM
Post: #10
RE: NZBGet won't unpack rar-files
I found the problem. Apparently folders on the NMT are case-sensitive. I set it to download to share\download while the right directory is called share\Download, with an uppercase 'D'.

When I access both dirs using my PC they have the same content, but on the NMT I see the correct content in both dirs. I set the download dir back to \share\Download so now I only have to figure out how to delete the download dir. When I try this on my PC it wants to delete both dirs.
Find all posts by this user
Thread Closed 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  nzbget does not download twentefan 1 124 06-18-2013 12:49 PM
Last Post: chris57
  NZBget daemon dying raven219 0 111 06-15-2013 03:54 PM
Last Post: raven219
  NZBGet holding onto connections? wanstronian 0 179 06-07-2013 05:57 PM
Last Post: wanstronian
  Can't save NZBGet Web Interface settings jurjongo 2 737 05-29-2013 10:18 PM
Last Post: jhmiller
Star NZBGet 9.0/10.0 discussion hugbug 473 43,630 05-21-2013 06:45 PM
Last Post: say170
  Unrar unpack unzip torrents dpslusser 6 2,911 04-08-2013 10:55 AM
Last Post: DathRarhek
  NZBGet download x pars instead of one/all/none shazada 0 577 04-07-2013 03:46 PM
Last Post: shazada
  NZBGet on the PCH/NMT Manual and F.A.Q. Philos 147 178,052 03-10-2013 11:33 AM
Last Post: blobe
Tongue Script to send NZB(url) to NZBGet using iOS mrmaximum 18 7,275 03-05-2013 12:23 AM
Last Post: rvdet
  NZBGET postprocess to specified folder Goldrolly 2 1,181 02-15-2013 06:09 PM
Last Post: jhmiller

Forum Jump: