Connect directly to host with deluge-console?

General support for problems installing or using Deluge
Post Reply
Formula Juan
Member
Member
Posts: 11
Joined: Mon Oct 28, 2019 6:53 pm

Connect directly to host with deluge-console?

Post by Formula Juan »

Since upgrading from 1.3.15, I've found that when I run deluge-console, rather than connect straight to my daemon, I'm instead show a screen where I have to select the daemon. I've also tried using variations of deluge-console -d 127.0.0.1:58846 to connect directly to my preferred daemon but it's still showing the manual selection screen.

How can I use a single deluge-console command to connect directly to a specific host / daemon?

[EDIT] If I use the deluge-console connect 127.0.0.1:58846, I run into the issue discussed in this thread viewtopic.php?t=56262... so do I need to update to 2.1.2?
Formula Juan
Member
Member
Posts: 11
Joined: Mon Oct 28, 2019 6:53 pm

Re: Connect directly to host with deluge-console?

Post by Formula Juan »

I think I've answered my own question. I have been hacking around, so it's possible that something other than what I explain below, is responsible for the deluge-console connection now working. So YMMV.

1. Run deluge-console and confirm that you're able to connect to the host.
1.a. Add a connection to your desired host, using either a user already in the auth file, or a user you have added to said file.
2. Use the following command to connect to your preferred host deluge-console -d >ip_address< -p >port< -U >username< -P >password<.

If you're in the same boat as I am, and you're using the deluge-console in an execute script, then you can use the above command in your script, and append the deluge-console command to the end. like so-

deluge-console -d >ip_address< -p >port< -U >username< -P >password< "recheck >toreent_id<"
mhertz
Moderator
Moderator
Posts: 2216
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: Connect directly to host with deluge-console?

Post by mhertz »

Yes deluge-console mimicks gtk-ui in deluge v2.x. You can run it non-interactively as you found, where it will auto-connect as before, with same rules for localclient mechanism I.e run under same user account as deluged, or else need to do what you did, I.e add the switches for ip/user/pass, use 'connect' command and semicolons to delimit rest commands to run after logging in, use '-c <CONFIG-DIR>' or 'sudo -u <user> deluge-console'.

Thanks for your helpful post(s) for others BTW :)

Edit: Forgot mention the "deferred" error can be fully ignored, though I posted a line to fix once, and is fixed in dev branch also.

Edit2: Can first press 'l' and enter command-line mode(deluge-console v1.x style) after logging-in I see - however only needs press return to login for listed/saved hosts, e.g. default localclient(possibly needing 'sudo' or '-c' switch to initiate). Btw, there's some fixes in develop branch for various issues I see/remember now, e.g. you cannot add a host currently, as will complain host not an integer etc - I posted commands previously for that too, though for now can just do what OP nicely suggested i.e. add manually to hostlist.conf/auth.
Post Reply