NZBGet Automatic Updates

Get help, report and discuss bugs.
SubNoize
Posts: 8
Joined: 20 Oct 2014, 00:36

NZBGet Automatic Updates

Post by SubNoize » 20 Oct 2014, 00:44

I can't find anything on automatic updates. I'm just curious what's the best way to keep NZBGet up to date? I'm currently using the testing version.

"Currently installed: 14.0-testing-r1145
Automatic updates are not configured for your platform."

How do I configure them ?

clintonhall
Posts: 449
Joined: 15 Dec 2012, 01:52
Location: Australia
Contact:

Re: NZBGet Automatic Updates

Post by clintonhall » 20 Oct 2014, 02:28

What system do you have and how is is packaged?

See http://nzbget.net/Packaging for details on how to build and maintain updates within a package.

SubNoize
Posts: 8
Joined: 20 Oct 2014, 00:36

Re: NZBGet Automatic Updates

Post by SubNoize » 20 Oct 2014, 22:56

clintonhall wrote:What system do you have and how is is packaged?

See http://nzbget.net/Packaging for details on how to build and maintain updates within a package.
I use a windows 64it machine. Running the "testing" version.

"The maintainer needs to compile new version of NZBGet and make it available via Internet. When user starts auto-update function the program uses a special configuration file (provided along with installed package) to retrieve information about availability of new binary packages. If new version was found user can install it. For installation NZBGet calls an update-script, which is again written and provided by package maintainer. The script then downloads and installs new version and restarts NZBGet."

Where do i find that

hugbug
Developer & Admin
Posts: 7541
Joined: 09 Sep 2008, 11:58
Location: Germany

Re: NZBGet Automatic Updates

Post by hugbug » 21 Oct 2014, 07:45

http://nzbget.net/Packaging is a document for package creators.
The Windows version available for download from the NZBGet home page doesn't support automatic update at the moment.

SubNoize
Posts: 8
Joined: 20 Oct 2014, 00:36

Re: NZBGet Automatic Updates

Post by SubNoize » 22 Oct 2014, 03:39

hugbug wrote:http://nzbget.net/Packaging is a document for package creators.
The Windows version available for download from the NZBGet home page doesn't support automatic update at the moment.
Oh, how annoying. Thanks for that. Any idea when it will be supported ? It seems odd you host the updated versions yet don't allow for automatic updating from those files.

hugbug
Developer & Admin
Posts: 7541
Joined: 09 Sep 2008, 11:58
Location: Germany

Re: NZBGet Automatic Updates

Post by hugbug » 22 Oct 2014, 05:28

It's not about "not allowing", this feature like any other must be implemented first.
No plans for that yet.

FKuypers
Posts: 20
Joined: 04 Jun 2013, 04:55

Re: NZBGet Automatic Updates

Post by FKuypers » 26 Oct 2014, 19:28

Well,

I have written a script to support this... it should work for you as well. I am using the testing build which get posted at "http://gralsburg.org/NZBGet-Builds/"

Just put the content of the RAR in your Script/Webui directory and try "check for updates"...

Feedback would be welcome...

The script assumes the following:

- Your NZBGET is installed in C:\NZBGET
- Powershell.exe is in path
- NZBGET is running as a service and is called "NZBGet"

Thanks,

Frank
Attachments
scripts.rar
(2.76 KiB) Downloaded 117 times

miteepingwin
Posts: 33
Joined: 28 Aug 2012, 02:11

Re: NZBGet Automatic Updates

Post by miteepingwin » 07 Nov 2014, 23:31

This is exactly what I was looking for Frank!
Unfortunately I'm having problems getting it to work.
First some side-notes:
1. You may have to allow powershell scripts to run. Run powershell as Admin and enter: Set-ExecutionPolicy Unrestricted
2. On Windows 8, you need to unblock the Powershell scripts. Right-click and choose Unblock.

Here's the error I get when manually running update.cmd:
Update initiated....
Downloading latest version to \temp\
You cannot call a method on a null-valued expression.
At C:\nzbget\scripts\update.ps1:87 char:5
+ $webclient.DownloadFile($DownloadURLComplete,"$Dest")
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : InvokeMethodOnNull

x -y -o\temp\_unpack \temp\
Start-Process : Cannot validate argument on parameter 'FilePath'. The argument
is null or empty. Provide an argument that is not null or empty, and then try
the command again.
At C:\nzbget\scripts\update.ps1:96 char:15
+ Start-Process "$WinZipDir" -ArgumentList "$ArgList" -Wait
+ ~~~~~~~~~~~~
+ CategoryInfo : InvalidData: (:) [Start-Process], ParameterBindi
ngValidationException
+ FullyQualifiedErrorId : ParameterArgumentValidationError,Microsoft.Power
Shell.Commands.StartProcessCommand

Files have been unpacked to \*
Will be copying Files... From \* to
Stopping Service NZBGet
Copying Files... From \* to

FKuypers
Posts: 20
Joined: 04 Jun 2013, 04:55

Re: NZBGet Automatic Updates

Post by FKuypers » 08 Nov 2014, 10:48

Hi,

you can not run the update.cmd manually, since some of the variables will not be set correctly...

Did you try the "SETTINGS/SYSTEM/Check for Updates" button?

The error should also be visibile in the messages tab then, if it does not work.

If you want to run the powershell script in the IDE to debug, if have added the following lines to my script to be able to run it without being called from NZBGET:

# For Debuggging

#$env:NZBOP_DESTDIR = "\\Server\Downloads"
#$env:NZBOP_SEVENZIPCMD = "\\Server\nzbget\7zip\7za.exe"
#$env:NZBUP_BRANCH = "DEVEL"
#$env:NZBOP_APPDIR = "C:\Temp\nzbget"

So just remove the starting hashes (except on the "for Debugging" - of course) and fill in the right paths that fits your setup - then you should be able to run the script independently...

Hope this helps - just remember to set the hashes again after you are done, otherwise you will always overwrite the values provided by NZBGET.

Frank

miteepingwin
Posts: 33
Joined: 28 Aug 2012, 02:11

Re: NZBGet Automatic Updates

Post by miteepingwin » 08 Nov 2014, 17:30

I tried from the Check Updates button first, but it doesn't find anything.
Here's the error log from Nzbget:
http://pastebin.com/AkkhvHNV

And what I get with the debug turned on:
C:\NZBGet\scripts>update.cmd
Update initiated....
Installing Testing Version
http://sourceforge.net/projects/nzbget/ ... -bin-win32
.zip
Testing version found at http://sourceforge.net/projects/nzbget/files/nzbget-14.
0-testing-r1153-bin-win32.zip - nzbget-14.0-testing-r1153-bin-win32.zip
Downloading latest version http://sourceforge.net/projects/nzbget/files/nzbget-1
4.0-testing-r1153-bin-win32.zip to \temp\nzbget-14.0-testing-r1153-bin-win32.zip

x -y -o\temp\_unpack \temp\nzbget-14.0-testing-r1153-bin-win32.zip
Start-Process : Cannot validate argument on parameter 'FilePath'. The argument
is null or empty. Provide an argument that is not null or empty, and then try
the command again.
At C:\nzbget\scripts\update.ps1:101 char:15
+ Start-Process "$WinZipDir" -ArgumentList "$ArgList" -Wait
+ ~~~~~~~~~~~~
+ CategoryInfo : InvalidData: (:) [Start-Process], ParameterBindi
ngValidationException
+ FullyQualifiedErrorId : ParameterArgumentValidationError,Microsoft.Power
Shell.Commands.StartProcessCommand

Get-ChildItem : Cannot find path 'C:\temp\_unpack' because it does not exist.
At C:\nzbget\scripts\update.ps1:108 char:15
+ $UnPackRoot = Get-ChildItem $UnPackTo
+ ~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (C:\temp\_unpack:String) [Get-Ch
ildItem], ItemNotFoundException
+ FullyQualifiedErrorId : PathNotFound,Microsoft.PowerShell.Commands.GetCh
ildItemCommand

Files have been unpacked to \*
Will be copying Files... From \* to
Stopping Service NZBGet
Stop-Service : Service 'NZBGet (NZBGet)' cannot be stopped due to the
following error: Cannot open NZBGet service on computer '.'.
At C:\nzbget\scripts\update.ps1:127 char:1
+ Stop-Service $ServiceName
+ ~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : CloseError: (System.ServiceProcess.ServiceContro
ller:ServiceController) [Stop-Service], ServiceCommandException
+ FullyQualifiedErrorId : CouldNotStopService,Microsoft.PowerShell.Command
s.StopServiceCommand

Post Reply

Who is online

Users browsing this forum: No registered users and 11 guests