Shutdown when queue done

Support for the Debian/Ubuntu package, created by JCFP.
Forum rules
Help us help you:
  • Are you using the latest stable version of SABnzbd? Downloads page.
  • Tell us what system you run SABnzbd on.
  • Adhere to the forum rules.
  • Do you experience problems during downloading?
    Check your connection in Status and Interface settings window.
    Use Test Server in Config > Servers.
    We will probably ask you to do a test using only basic settings.
  • Do you experience problems during repair or unpacking?
    Enable +Debug logging in the Status and Interface settings window and share the relevant parts of the log here using [ code ] sections.
Post Reply
do0fY
Newbie
Newbie
Posts: 6
Joined: October 29th, 2013, 2:51 pm

Shutdown when queue done

Post by do0fY »

How can i force sabnzbd to shotdown my ubuntu server, when the queue is done?
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: Shutdown when queue done

Post by shypike »

In the menu under the yellow down arrow at the top right of the queue,
there is an entry called "On Finish".
do0fY
Newbie
Newbie
Posts: 6
Joined: October 29th, 2013, 2:51 pm

Re: Shutdown when queue done

Post by do0fY »

Saw that, but this option has to be set every time again AND even when i say "Shutdown Computer", sothing happens :)
User avatar
jcfp
Release Testers
Release Testers
Posts: 1022
Joined: February 7th, 2008, 12:45 pm

Re: Shutdown when queue done

Post by jcfp »

Sab simply sends a call to the os through dbus. What the os does with that isn't quite that straightforward though. From the sab's perspective, the job is done as soon as it sends the request to the os, so you may have better luck getting a detailed answer asking at a forum dedicated to that.

Other than the need to have python-dbus installed, you may also have to configure your system to actually allow the user running sab to shutdown the system. The underlying mechanism differs between various ubuntu releases, nowadays it's mostly one of policykit, upower, consolekit, logind; see e.g. here. The relevant policies and restrictions can also distinguish between whether or not there are multiple logged-in users. And somewhat counterintuitive, you may not have such rights even if you can readily shutdown/reboot from the graphical interface.

A trial run could be to shutdown from the command line as the user running sab without using or bypassing sudo, i.e. shutdown -h now (I didn't test the syntax, for obvious reasons).
Post Reply