Resume without checking after error

General support for problems installing or using Deluge
Harkonnen
New User
New User
Posts: 8
Joined: Sun Feb 13, 2011 5:48 pm

Resume without checking after error

Post by Harkonnen »

Is there any way to resume torrents after disk error without rechecking? Like tell deluge to assume that all torrents are fully completed? I seed from an external usb drive, and sometimes its restarts for whatever reason. Deluge sets all torrents to error state, and the only way to resume is recheck everything (which takes half a day for >1TB over usb).
Cas
Top Bloke
Top Bloke
Posts: 3679
Joined: Mon Dec 07, 2009 6:04 am
Location: Scotland

Re: Resume without checking after error

Post by Cas »

In 1.3 not really but I am working on the problem to be fixed in 1.4.

The best workaround would be to keep a periodic backup of your state fastresume file and if you see an error close Deluge and restore from last good copy. A pain I know but it's the best I can offer currently.
shamael
Compulsive Poster
Compulsive Poster
Posts: 667
Joined: Sat Oct 08, 2016 9:28 am

Re: Resume without checking after error

Post by shamael »

Hi All,

We are talking about the same error: recent Deluge setup finally done (perf issue etc solved) but each time I need to restart my Pi, I get a lot of torrent in red, "Error: Problem with resume data: missing or invalid 'file sizes' entry" is most of time what I see but tracker issue are displayed too. I need to force-recheck all torrent (on a Pi it takes a ...moment).

And Btw thanks Cas for all the good work :). I almost gave up when I was sticked with poor perf issue and compiling libtorrent 1.0.9 on a pi without swap was not the easiest part for a noob. thanks to itconfig after the compiling I get a really descend setup on a RPI3. I will write about it when I have time :)
shamael
Compulsive Poster
Compulsive Poster
Posts: 667
Joined: Sat Oct 08, 2016 9:28 am

Re: Resume without checking after error

Post by shamael »

For anyone following this topic, I may have a solution. I never restart the daemon w/o having to force-recheck a lot of torrent but this time...
Even a full reboot of my box did not create issue

What did I changed?
Edit your systemd file

Code: Select all

sudo nano /etc/systemd/system/deluged.service
Replace the following line (adapt XXXXX.mount with yours)

Code: Select all

RequiresMountsFor=XXXXX.mount
with

Code: Select all

Requires=XXXXX.mount
After=XXXXX.mount
Please give me a feedback, so I can ask for wiki edition
Cas
Top Bloke
Top Bloke
Posts: 3679
Joined: Mon Dec 07, 2009 6:04 am
Location: Scotland

Re: Resume without checking after error

Post by Cas »

It seems that if noauto is in the mount then Requires and After would need specified:
RequiresMountsFor=

Takes a space-separated list of absolute paths. Automatically adds dependencies of type Requires= and After= for all mount units required to access the specified path.

Mount points marked with noauto are not mounted automatically and will be ignored for the purposes of this option. If such a mount should be a requirement for this unit, direct dependencies on the mount units may be added (Requires= and After= or some other combination).
Cas
Top Bloke
Top Bloke
Posts: 3679
Joined: Mon Dec 07, 2009 6:04 am
Location: Scotland

Re: Resume without checking after error

Post by Cas »

I have updated the guide with those changes as it is a more robust setup that having the check fstab auto details.

http://dev.deluge-torrent.org/wiki/User ... ce/systemd
shamael
Compulsive Poster
Compulsive Poster
Posts: 667
Joined: Sat Oct 08, 2016 9:28 am

Re: Resume without checking after error

Post by shamael »

I planned to do it after first feedback but thanks :).
P4NCH1

Re: Resume without checking after error

Post by P4NCH1 »

Thats a good workaround, but how can I implement it in the normal Linux desktop version? I mean, without the daemon and web-UI, in my Linux Mint Cinnamon the file etc/systemd/system/deluged.service does'nt exist. I've installed trough apt sudo apt-get install deluge

Cheers, and thanks very much for this torrent client! :)
shamael
Compulsive Poster
Compulsive Poster
Posts: 667
Joined: Sat Oct 08, 2016 9:28 am

Re: Resume without checking after error

Post by shamael »

This issue may be present when the daemon setup is done with a target drive mounted via fstab. (The target drive is automatically mounted and Deluge daemon start as a daemon on boot). The new mount way only tells Deluge to wait for the drive to be accessible, it doesn't mount the drive.

Guessing your target drive is accessible already and you start Deluge as an application on your desktop --> not relevant for you :).
operat0r

Re: Resume without checking after error

Post by operat0r »

Yup! FINALY ! the BindsTo= and After= worked for me even tho they local disk and EXT .. I think some how deluge was shutting down before the disk was unounted ? or some how my SSD starts so fast with deluge the other SATA drives are not mounted yet ?? I have no idea what the issue is but this systemd file works for me! THANK YOU! this was the last part of my switch from Ubuntu/Sysv/Upstart > debian/systemd !

Code: Select all

# sdb2 main drive
UUID=b5e2be62-7df8-4eae-9650-5ebafc78fd15       /media/data     auto    defaults,nofail,x-systemd.device-timeout=1 0       2

#moredata
UUID=e07eb8dc-c5dc-4127-a305-845e09649c63       /media/moredata auto    defaults,nofail,x-systemd.device-timeout=1 0       2

#backup
UUID=70CF-1264                                  /media/backup   auto    defaults,nofail,x-systemd.device-timeout=1 0       2

Code: Select all

systemctl -t mount
UNIT                          LOAD   ACTIVE SUB     DESCRIPTION
-.mount                       loaded active mounted Root Mount
dev-hugepages.mount           loaded active mounted Huge Pages File System
dev-mqueue.mount              loaded active mounted POSIX Message Queue File System
media-backup.mount            loaded active mounted /media/backup
media-data.mount              loaded active mounted /media/data
media-moredata.mount          loaded active mounted /media/moredata
proc-sys-fs-binfmt_misc.mount loaded active mounted Arbitrary Executable File Formats File System
run-user-1000.mount           loaded active mounted /run/user/1000
sys-fs-fuse-connections.mount loaded active mounted FUSE Control File System
sys-kernel-debug.mount        loaded active mounted Debug File System

Code: Select all

cat /etc/systemd/system/deluged.service
[Unit]
Description=Deluge Bittorrent Client Daemon
Documentation=man:deluged

After=network-online.target media-moredata.mount   media-data.mount   media-backup.mount
Requires=media-moredata.mount   media-data.mount   media-backup.mount
# Stops deluged if mount points disconnect
BindsTo=media-moredata.mount   media-data.mount   media-backup.mount


[Service]
Type=simple
User=root
Group=adm
UMask=000
ExecStart=/usr/bin/deluged -d -l /var/log/deluge/daemon.log -L debug

Restart=on-failure
# Time to wait before forcefully stopped.
TimeoutStopSec=300
[Install]
WantedBy=multi-user.target
Post Reply