Connecting via a deluge client on remote machine

General support for problems installing or using Deluge
Post Reply
kyats5000
New User
New User
Posts: 6
Joined: Thu Aug 25, 2022 1:31 am

Connecting via a deluge client on remote machine

Post by kyats5000 »

I have a silly question about connecting to my deluge server via the lite client on my remote machine.

Background:

I have a VPS/KVM-hosted ubuntu22.0.4 machine with a deluge server running (deluged service active) on the default port.

web-deluge is working flawlessly, as I am able to connect via http in a browser to my-domain:8112, input the web password, and I'm fine.

However, I want to connect via the lite client remotely, as in, from my local machine which is in a faraway location from the host deluge. My deluge-console correctly states the host is running deluged on 127.0.0.1:58846 ... can it be remote? If so, how can i run deluge to connect via my.vps.external.ip:58846

My presumption right now is that the actual deluge server (2.1.1.) is running on localhost, which deluge-web is configured to point to internally while it serves http get requests externally. This is great and secure, but does not suit my needs as I would prefer to use the client to make magnet links work right away.

Any advice on how to get this resolved? I have remote access enabled and I have restarted deluge; so I know I am good there. My ~/.config/deluge/auth has a seperate user:password:10 format; which is the one I am attempting to use from the 'lite client' in connection manager.
mhertz
Moderator
Moderator
Posts: 2331
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: Connecting via a deluge client on remote machine

Post by mhertz »

Unless I'm misunderstanding you, then you need the user:pass:10 on the vps under /var/lib/deluge/.config/deluge/auth since deluged is running under 'deluge' user(through systemd) and not '~' presumably. Restart deluged service afterwards.

I know official thinclient guide needs updated sorry.
kyats5000
New User
New User
Posts: 6
Joined: Thu Aug 25, 2022 1:31 am

Re: Connecting via a deluge client on remote machine

Post by kyats5000 »

Thanks for replying

Alas, during the initial installation guide I followed, I indeed filled that auth file located at /var/lib/deluge/.config/auth with several users. I don't think that's the issue.

By the way, I know it's not a firewall issue. (ufw allow) for the port also. Does everyone else's deluge-console indicate that server is running on localhost? I want it to be accessible from the ip I have mapped to my domain name
kyats5000
New User
New User
Posts: 6
Joined: Thu Aug 25, 2022 1:31 am

Re: Connecting via a deluge client on remote machine

Post by kyats5000 »

I am now facing what appears to be a separate issue.

Deluge is stuck in a failed state

```
× deluged.service - Deluge Bittorrent Client Daemon
Loaded: loaded (/etc/systemd/system/deluged.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Thu 2022-08-25 12:42:52 UTC; 2s ago
Docs: man:deluged
Process: 163292 ExecStart=/usr/bin/deluged -d (code=exited, status=1/FAILURE)
Main PID: 163292 (code=exited, status=1/FAILURE)
CPU: 1.256s

Aug 25 12:42:52 kyats5000 systemd[1]: deluged.service: Failed with result 'exit-code'.
Aug 25 12:42:52 kyats5000 systemd[1]: deluged.service: Consumed 1.256s CPU time.
Aug 25 12:42:52 kyats5000 systemd[1]: deluged.service: Scheduled restart job, restart counter is at 5.
Aug 25 12:42:52 kyats5000 systemd[1]: Stopped Deluge Bittorrent Client Daemon.
Aug 25 12:42:52 kyats5000 systemd[1]: deluged.service: Consumed 1.256s CPU time.
Aug 25 12:42:52 kyats5000 systemd[1]: deluged.service: Start request repeated too quickly.
Aug 25 12:42:52 kyats5000 systemd[1]: deluged.service: Failed with result 'exit-code'.
Aug 25 12:42:52 kyats5000 systemd[1]: Failed to start Deluge Bittorrent Client Daemon.
```
kyats5000
New User
New User
Posts: 6
Joined: Thu Aug 25, 2022 1:31 am

Re: Connecting via a deluge client on remote machine

Post by kyats5000 »

I have run systemctl restart deluged
Last edited by kyats5000 on Thu Aug 25, 2022 12:58 pm, edited 1 time in total.
kyats5000
New User
New User
Posts: 6
Joined: Thu Aug 25, 2022 1:31 am

Re: Connecting via a deluge client on remote machine

Post by kyats5000 »

Still having the issue with connection manager not allowing me to connect remotely. REmote connections is allowed

Now, when trying to connect to deluge-console I see this after I hit enter. This is new, perhaps unrelated

```
/var/lib/deluge/.config/deluge# cat deluged.log
Cannot start deluged, listen port in use.
Check for other running daemons or services using this port: :58846
Cannot start deluged, listen port in use.
Check for other running daemons or services using this port: :58846
Cannot start deluged, listen port in use.
Check for other running daemons or services using this port: :58846
Cannot start deluged, listen port in use.
Check for other running daemons or services using this port: :58846
Cannot start deluged, listen port in use.
Check for other running daemons or services using this port: :58846
Cannot start deluged, listen port in use.

```
Attachments
failure-to-connect.png
failure-to-connect.png (85.44 KiB) Viewed 7108 times
mhertz
Moderator
Moderator
Posts: 2331
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: Connecting via a deluge client on remote machine

Post by mhertz »

You need to add new host('a' if remember right) with vps deluged credentials in deluge-console. Note there's a bug where this fails(states port entered needs be int, which already is), which I've reported and DjLegolas submitted PR with better fix, but instead of hacking source to fix then you can add said creds to ~/.config/deluge/hostlist.conf on local machine - you can just overwrite the localhost entry there if not needed, if wanted. Then just press return to connect when seeing new vps entry now listed instead of localhost one, when starting deluge-console.
kyats5000
New User
New User
Posts: 6
Joined: Thu Aug 25, 2022 1:31 am

Re: Connecting via a deluge client on remote machine

Post by kyats5000 »

Your steps, as I undersand them, are related to fixing hte password issue shown above? Are you providing a remedy to the first scenario, where I can't connect to the seedbox from my client? Right now, the daemon itself isn't working either. Separate, though now related, issues.

1. add new host with the credentials of my deluged daemon (what would those be? The user:password:10?) in deluge-console ((All operations in my VPS)
2. ON LOCAL MACHINE (laptop not in same country as VPS), add credentials (what would those be? Example?) to ~/.config/deluge/hostlist.conf

My issue here is twofold:
i. My client connection manager I have inputted mydomain.com:correctport, with the credentials. It just doesn't work
ii. My deluged daemon isn't running right anymore and deluge-console shows that it's expecting a password or something?
mhertz
Moderator
Moderator
Posts: 2331
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: Connecting via a deluge client on remote machine

Post by mhertz »

I'm sorry, indeed confused myself :)

Initially I thought you meant GTK-UI with the "lite client" mention, but then when mentioning console-UI I thought maybe that was said lite-client.

Anyway, for the issue with deluged on seedbox, then I don't know if can reboot such, but I would stop service, run just in case 'sudo pkill -9 deluged'(in case local deluged somehow running, blocking systemd's) and delete /var/lib/deluge/.config/deluge if not having anything important(or rename it to end in bak, so gets regenerated and have backup), then start service again from systemd and hopefully works fresh.

If running deluge-console on your VPS to check deluged, then it's normal it states password not match if just pressing return to connect default localhost:58846, but works if using e.g. as quick hack 'sudo -u deluge deluge-console'.

I'm sorry I don't know why cannot connect to seedbox from GTK-UI, unless it's the deluged daemon now acting up, but you had this issue since start though. Does it say online at-least in connection-manager? Does it lists as having that port open from outside from other means like yougetsignal.com? VPS deluged I mean. As you said, remote connections enabled and having e.g. foo:bar:10 under VPS /var/lib/deluge/.config/deluge/auth and connecting to that same user/password/port/url from laptop. Also, maybe try IP instead of URL, though should work with URL but regardless.

The hostlist.conf I mentioned, was just because I thought you used deluge-console to connect to VPS from your laptop, and since deluge-console has bug adding new host so need done that way instead, so not relevant, but adds regardless just in case relevant somehow anyway, and since you also asked:
VPS /usr/lib/deluge/.config/auth: foo:bar:10
laptop ~/.config/deluge/hostlist.conf:

Code: Select all

{
    "file": 3,
    "format": 1
}{
    "hosts": [
        [
            "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
            "VPS-URL",
            58846,
            "foo",
            "bar"
        ]
    ]
}
˝
Post Reply