Page 1 of 1

Sabnzbd .ini file won't save changes after Sab restart

Posted: November 4th, 2012, 10:36 am
by Greene48
I'm running SABnzbd on a Ubuntu 12.04 server.
All has been running fine for the last few weeks. Today I had to restart my router, and the ip address of my server changed which caused SAB to stop running. I had a feeling that this might happen; I've read that I need to set up static ip's to avoid this, just havent got around to doing it.

So after doing some searching, it's my understanding that I need to edit the sabnzbd.ini file and change host=192.168.x.x to host=0.0.0.0 so that SAB will use the host machines ip adress by default. So I tried making that change to the file; it seems to save fine, but when I restart SAB using 'service sabnzbdplus restart' it still does not seem to be running. So I went back into the sabnzbd.ini file and the host setting has been reset back to host=192.168.x.x

I'm not sure why this is happening, or if it's a SAB issue or a Ubuntu issue (as I'm relatively new to both so I could be making a stupid mistake somewhere). But it seems like when I restart SABnzbd, it is changing the .ini file back to what it was previously. I tried deleting the sabnzbd.ini.bak file before making the change and this didn't help either. Any ideas?

Re: Sabnzbd .ini file won't save changes after Sab restart

Posted: November 4th, 2012, 11:37 am
by shypike
You cannot safely edit the INI file while SABnzbd is running.
So stop it first, change the file and then start.
It could also be that your system's name doesn't resolve to an IP address.
In that case, you're stuck with using the real IP address.
This command should run successfully:
ping `uname -n`

Re: Sabnzbd .ini file won't save changes after Sab restart

Posted: November 5th, 2012, 5:06 pm
by Greene48
Thanks for the quick response, I wasn't back at my computer until now.

Stopping SABnzbd before editing the INI file doesn't seem to help; when I start SABnzbd again it changes the INI file host setting back to what it was previously.

How do I know if the ping command runs successfully? the output I get is:

PING UbuntuServer (127.0.x.x) 56(84) bytes of data.
64 bytes from UbuntuServer (127.0.x.x): icmp_req=1 ttl=64 time=0.070 ms

and then it just keeps repeating that 2nd line.

Re: Sabnzbd .ini file won't save changes after Sab restart

Posted: November 5th, 2012, 5:13 pm
by shypike
I suspect that the address is hard-coded into the startup script:
/etc/init.d/sabnzbdplus
I'm not very familiar with this, because I don't make the package.

Re: Sabnzbd .ini file won't save changes after Sab restart

Posted: November 5th, 2012, 5:46 pm
by jcfp
It's indeed possible to do so, the ip would be set in /etc/default/sabnzbdplus in that case. That would set the host as part of the command line arguments fed to the program on every startup via the init script, overruling sabnzbd.ini.

Re: Sabnzbd .ini file won't save changes after Sab restart

Posted: November 5th, 2012, 6:06 pm
by Greene48
Thanks guys.
It's running fine now after editing the value of host in /etc/default/sabnzbdplus.