Page 1 of 1

[Tip] Changing the script-option on whole queue

Posted: September 9th, 2010, 4:13 pm
by zhiva
Hello all, thought I´d share a tip I just had to use.

Because of an error on my side, all new downloads in the tv-category got the wrong script assigned. My queue was 20 pages long, so it seemed a bit tedious to do everyone manually. What I did:

1. Stop SABnzbd
2. Command: cd /home/[username]/.sabnzbd/cache
3. Command: find ./ -type f -exec sed -i 's/[name_of_wrong_script]/[name_of_correct_script]/' {} \;
  * Type in without the [] around script. For me it became: find ./ -type f -exec sed -i 's/mediarover-sort.sh/sabToSickBeard.py/' {} \;
4. Start SABnzbd (sudo invoke-rc.d sabnzbd restart if you use Ubuntu)

Now, the queue has changed to the new script.

BEWARE: This can seriously mess up your queue, do a backup of the cache-directory first!

Re: [Tip] Changing the script-option on whole queue

Posted: September 9th, 2010, 4:26 pm
by shypike
Rather risky, given that the queue admin files are binary.

Re: [Tip] Changing the script-option on whole queue

Posted: September 10th, 2010, 5:16 am
by zhiva
Yeah, but I found alot of the text was cleartext, so sed-ing it seemed ok. Didnt harm my list at least, and its worth a shot if people have a huge list and find it tedious to change all dropdown boxes.