Error when trying to access web GUI.

Ask for help and report issues not specific to either the Mac OS X or GTK+ versions of Transmission
falconed
Posts: 6
Joined: Fri Dec 26, 2008 4:38 am

Error when trying to access web GUI.

Post by falconed »

Hey everyone!

I have installed transmission on my headless Ubuntu 8.04.1 server and am having troubles accessing the web GUI for it on the same network.

I have 1.42 installed (using transmissioncli -v):

Code: Select all

Transmission 1.42 (7495) - http://www.transmissionbt.com/
No torrent specified!
When I try to access http://192.168.0.17:9091/ I get the following error:
401: Unauthorized

Unauthorized IP Address.

Either disable the IP address whitelist or add your address to it.

If you're editing settings.json, see the 'rpc-whitelist' and 'rpc-whitelist-enabled' entries.

If you're still using ACLs, use a whitelist instead. See the transmission-daemon manpage for details.
I went to my settings.json file and it looks like this:

Code: Select all

{
    "blocklist-enabled": 0, 
    "download-dir": "\/home\/jamie", 
    "download-limit": 600, 
    "download-limit-enabled": 0, 
    "encryption": 1, 
    "max-peers-global": 200, 
    "peer-port": 51413, 
    "pex-enabled": 1, 
    "port-forwarding-enabled": 0, 
    "rpc-authentication-required": 0, 
    "rpc-password": "", 
    "rpc-port": 9091, 
    "rpc-username": "", 
    "rpc-whitelist": "127.0.0.1", 
    "upload-limit": 10, 
    "upload-limit-enabled": 0
}
I tried adding and changing the IP address in the "rpc-whitelist" to my Servers IP address and I still get the same error.

Is there a solution to this?

Any help will be great.
exiztone

Re: Error when trying to access web GUI.

Post by exiztone »

-
Last edited by exiztone on Wed Jul 24, 2013 5:57 pm, edited 1 time in total.
Waldorf
Posts: 1024
Joined: Wed Dec 27, 2006 10:46 am
Location: Belgium

Re: Error when trying to access web GUI.

Post by Waldorf »

Try setting the rpc-whitelist to "127.0.0.1,192.168.*.*".
falconed
Posts: 6
Joined: Fri Dec 26, 2008 4:38 am

Re: Error when trying to access web GUI.

Post by falconed »

Waldorf wrote:Try setting the rpc-whitelist to "127.0.0.1,192.168.*.*".
I did do that and I still got the same message. Must the IP be the servers IP or the IP of the PC trying to connect to it?
falconed
Posts: 6
Joined: Fri Dec 26, 2008 4:38 am

Re: Error when trying to access web GUI.

Post by falconed »

Must I install any other things? Like transmission-remote or clutch?
rb07
Posts: 1400
Joined: Sun Aug 24, 2008 3:14 am

Re: Error when trying to access web GUI.

Post by rb07 »

You need to stop the daemon, change settings.json, then start the daemon.

And yes, the address(es) that go in there are the computers that you want to have access to the daemon (either using a Web browser or transmission-remote). The example Waldorf gave you means all your local network, since you showed your server as being 192.168.0.17, the LAN could be 192.168.0.* or if you have sub-LANs 192.168.*.*
jdarias
Posts: 21
Joined: Tue May 13, 2008 2:31 pm

Re: Error when trying to access web GUI.

Post by jdarias »

Thank you waldorf and rb07. I was having the same issue.
jeztastic
Posts: 2
Joined: Sun Dec 28, 2008 1:53 am

Re: Error when trying to access web GUI.

Post by jeztastic »

Hi,

I am having the same problem, but that solution has not helped... Any ideas?

Thanks,

Jez

Code: Select all

    "blocklist-enabled": 0,
    "download-dir": "\/home\/jez",
    "download-limit": 600,
    "download-limit-enabled": 0,
    "encryption": 1,
    "max-peers-global": 200,
    "peer-port": 16868,
    "pex-enabled": 1,
    "port-forwarding-enabled": 0,
    "rpc-authentication-required": 0,
    "rpc-password": "",
    "rpc-port": 9091,
    "rpc-username": "jez",
    "rpc-whitelist": "127.0.0.1,192.168.*.*,192.168.1.65"
    "upload-limit": 5,
    "upload-limit-enabled": 0
falconed
Posts: 6
Joined: Fri Dec 26, 2008 4:38 am

Re: Error when trying to access web GUI.

Post by falconed »

rb07 wrote:You need to stop the daemon, change settings.json, then start the daemon.

And yes, the address(es) that go in there are the computers that you want to have access to the daemon (either using a Web browser or transmission-remote). The example Waldorf gave you means all your local network, since you showed your server as being 192.168.0.17, the LAN could be 192.168.0.* or if you have sub-LANs 192.168.*.*
Okay I did that and I still get the same error message:

Code: Select all

{
    "blocklist-enabled": 0, 
    "download-dir": "\/media\/store\/torrents", 
    "download-limit": 100, 
    "download-limit-enabled": 0, 
    "encryption": 1, 
    "max-peers-global": 200, 
    "peer-port": 51413, 
    "pex-enabled": 1, 
    "port-forwarding-enabled": 0, 
    "rpc-authentication-required": 0, 
    "rpc-password": "", 
    "rpc-port": 9091, 
    "rpc-username": "",
    "rpc-whitelist": "127.0.0.1,192.168.0.4", 
    "upload-limit": 10, 
    "upload-limit-enabled": 1
}
192.168.0.4 is the IP address of the Vista PC trying to access the web GUI. It still is coming up with the same error message. :(

How do I properly stop and start the daemon?
rb07
Posts: 1400
Joined: Sun Aug 24, 2008 3:14 am

Re: Error when trying to access web GUI.

Post by rb07 »

OK, actually the answer was not complete.

There are 3 ways to make the daemon use a whitelist:
  • Using a parameter when starting the daemon (i.e. -a 127.0.0.1,192.168.0.1);
  • Adding/changing the rpc-whitelist line to settings.json;
  • the default which is: only 127.0.0.1 has access, by not using one or both of the previous ways.
Since in your first message you showed what seems to be the result of the default way, we assumed you were not using the first way. If the daemon is started with '-a 127.0.0.1' it will behave as before but also, when shut-down, it will overwrite settings.json and the rpc-whitelist will show only 127.0.0.1 .

You could test if the running daemon is using that default whitelist by running on your headless server 'transmission-remote -l'.

Also you can check if the daemon really stopped by using the usual tools: 'pgrep -l trans' or 'ps -ef | grep trans'; looking at the timestamp on settings.json could be another way (I'm not sure if the file is overwritten when nothing changed).
falconed
Posts: 6
Joined: Fri Dec 26, 2008 4:38 am

Re: Error when trying to access web GUI.

Post by falconed »

rb07 wrote:OK, actually the answer was not complete.

There are 3 ways to make the daemon use a whitelist:
  • Using a parameter when starting the daemon (i.e. -a 127.0.0.1,192.168.0.1);
  • Adding/changing the rpc-whitelist line to settings.json;
  • the default which is: only 127.0.0.1 has access, by not using one or both of the previous ways.
Since in your first message you showed what seems to be the result of the default way, we assumed you were not using the first way. If the daemon is started with '-a 127.0.0.1' it will behave as before but also, when shut-down, it will overwrite settings.json and the rpc-whitelist will show only 127.0.0.1 .

You could test if the running daemon is using that default whitelist by running on your headless server 'transmission-remote -l'.

Also you can check if the daemon really stopped by using the usual tools: 'pgrep -l trans' or 'ps -ef | grep trans'; looking at the timestamp on settings.json could be another way (I'm not sure if the file is overwritten when nothing changed).
Okay here is what shows when I type in the following:

'transmission-remote -l':

Code: Select all

ID    Done  ETA       Up      Down    Ratio  Status       Name
'pgrep -l trans':

Code: Select all

4674 transmission-da
4729 transmission-da
5397 transmission-da
7165 transmission-da
11880 transmission-da
Hmm, not sure what to make of these.
rb07
Posts: 1400
Joined: Sun Aug 24, 2008 3:14 am

Re: Error when trying to access web GUI.

Post by rb07 »

The transmission-remote output is OK, you have no torrents but it shows that the daemon did not complain.

The pgrep output shows that you have 5 daemons running... that's the problem, in fact it probably shows a big bug on the daemon: why it doesn't complain that the first daemon has control over the peer and control ports?

Anyway, I had a similar problem with Gentoo, that's why I started writing the init.d script and configuring things better, in my case the /etc/init.d/transmission (in Gentoo it was named transmission-daemon) script was assuming that the daemon uses a pid file (what other servers put in /var/run/), it doesn't, and when it tries to stop the daemon it doesn't find a pid-file so the script didn't do a thing.

First you have to kill those daemons (masacre in this case), yep 'kill 4671 4729 5397 7165 11880' all of them.

Then you'll have to review the script and see what's wrong with it.
falconed
Posts: 6
Joined: Fri Dec 26, 2008 4:38 am

Re: Error when trying to access web GUI.

Post by falconed »

rb07 wrote:The transmission-remote output is OK, you have no torrents but it shows that the daemon did not complain.

The pgrep output shows that you have 5 daemons running... that's the problem, in fact it probably shows a big bug on the daemon: why it doesn't complain that the first daemon has control over the peer and control ports?

Anyway, I had a similar problem with Gentoo, that's why I started writing the init.d script and configuring things better, in my case the /etc/init.d/transmission (in Gentoo it was named transmission-daemon) script was assuming that the daemon uses a pid file (what other servers put in /var/run/), it doesn't, and when it tries to stop the daemon it doesn't find a pid-file so the script didn't do a thing.

First you have to kill those daemons (masacre in this case), yep 'kill 4671 4729 5397 7165 11880' all of them.

Then you'll have to review the script and see what's wrong with it.
Thanks for all the help rb07. I will do that and report back.
lynx
Posts: 4
Joined: Mon Dec 29, 2008 2:32 pm

Re: Error when trying to access web GUI.

Post by lynx »

rb07 wrote:OK, actually the answer was not complete.

There are 3 ways to make the daemon use a whitelist:
  • Using a parameter when starting the daemon (i.e. -a 127.0.0.1,192.168.0.1);
  • Adding/changing the rpc-whitelist line to settings.json;
  • the default which is: only 127.0.0.1 has access, by not using one or both of the previous ways.
Since in your first message you showed what seems to be the result of the default way, we assumed you were not using the first way. If the daemon is started with '-a 127.0.0.1' it will behave as before but also, when shut-down, it will overwrite settings.json and the rpc-whitelist will show only 127.0.0.1 .

You could test if the running daemon is using that default whitelist by running on your headless server 'transmission-remote -l'.

Also you can check if the daemon really stopped by using the usual tools: 'pgrep -l trans' or 'ps -ef | grep trans'; looking at the timestamp on settings.json could be another way (I'm not sure if the file is overwritten when nothing changed).
hello,

i've been using transmission on my openwrt box (Asus WL-500GP) and recently compiled last version 1.42 (7495) and give it a try.
what i don't understant or i don't get the ideea behind it, is the whitelist and the transmission-daemon not starting the webif!

1.
{
...
"rpc-whitelist-enabled": 0,
...
}

if i put this option in settings.json to FALSE, the whitelist should be disabled, right?
here is the output:

Code: Select all

root@wl500gp:~# transmission-daemon -f
Transmission 1.42 (7495) started
RPC Server: Adding address to whitelist: 127.0.0.1
RPC Server: Serving RPC and Web requests on port 9091
RPC Server: Whitelist enabled <-- wtf??
Port Forwarding: Opened port 51413 to listen for incoming peer connections
2.
if i start transmission-daemon it starts without the embeded web server.
if i start transmission-daemon -f it starts, in foreground, with the embeded server started.

really, i don't get it!
rb07
Posts: 1400
Joined: Sun Aug 24, 2008 3:14 am

Re: Error when trying to access web GUI.

Post by rb07 »

lynx wrote:yeap, not working, i've put "rpc-whitelist-enabled": 0 for disabled and the result is still:

Code: Select all

RPC Server: Whitelist enabled
Then file it as a bug at http://trac.transmissionbt.com/report.
without -f option the web server is NOT running!
What do you mean exactly? What test did you do? If you get an "access denied" that IS the web interface answering.
Post Reply