Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

qBittorrent deleting torrent files #12010

Open
Lucane opened this issue Feb 13, 2020 · 1 comment
Open

qBittorrent deleting torrent files #12010

Lucane opened this issue Feb 13, 2020 · 1 comment

Comments

@Lucane
Copy link

@Lucane Lucane commented Feb 13, 2020

qBittorrent version and Operating System

qBittorrent v4.2.1 (64-bit) Windows 10 Pro 64-bit v1903

What is the problem

For the past couple of weeks I've experienced an issue where for a reason I do not yet fully understand, torrent files are being removed at random. I suspect it might be due to how qB handles app exits, crashes and temporary freezes.

Sometimes I would come home, only to discover that a large portion of torrents are at 0% and have the error message "missing files". There will also be torrents that are at 98% or 75%. What I have noticed is that the same torrents tend to have recurring amounts of missing data over multiple episodes of this behaviour. Then the client starts rechecking a majority of the torrents and the result is that I have lost hundreds of GBs of data.

Oftentimes when this occurs, the client is largely unresponsive and I'm forced to kill the process. I know that the client has not fully crashed before I would decide to kill it myself, because I would be getting floods of Windows notifications from qB that torrents are missing files or the client can't find the files in question. This same behaviour also often occurs when I peacefully close down qB (from the right-click system tray menu) and then later run it again. qB again starts complaining about missing files and starts rechecking everything.

Now, I know what anyone's first guess would be in this scenario: a failing drive. I have made a clone of the 4TB WD Red drive in question onto another identical drive. The issue remains. I have also done a full drive scan for bad sectors and read/write errors, but no errors were encountered. The SMART data for the drive had no red flags that I could see: 0 reallocated/pending sectors, 0 uncorrectable errors, 0 seek errors and the other values were passing as well.

All of these symptoms in my mind either point to a drive caching issue or qBittorrent's inability to properly terminate and then for some reason overwriting the existing data with partially (yet to be) downloaded files, even though this should not be possible. Perhaps qB misinterpretes the .fastresume files or there's some other isolated combination of numerous bugs that causes qB to think it has to redownload the whole torrent from scratch. I'm not yet certain what the exact cause is.

I have also looked over the qB logs, but there is no valuable information to be seen. The most common log errors are "system cannot find the file specified", "file sizes mismatch for torrent", "unable to resume torrent" and "[torrentname] restored" (even though all the files are missing). There are no verbatim log entries to explain what is happening under the hood.

Out of curiosity's sake, I also enabled file auditing in Windows for the affected drive to monitor which processes were accessing and/or deleting the files. What I found was that upon client startup, qBittorrent makes WriteData/AddFile requests for the files that go missing. Here is one such log entry:

An attempt was made to access an object.

Subject:
	Security ID:		[pc-name]\[username]
	Account Name:		[username]
	Account Domain:		[pc-name]
	Logon ID:		0x100E32A

Object:
	Object Server:		Security
	Object Type:		File
	Object Name:		\Device\HarddiskVolume8\Downloads\[filename]
	Handle ID:		0x1028
	Resource Attributes:	S:AI

Process Information:
	Process ID:		0x48e8
	Process Name:		C:\Program Files\qBittorrent\qbittorrent.exe

Access Request Information:
	Accesses:		WriteData (or AddFile)
	Access Mask:		0x2

Steps to reproduce and final thoughts

I don't really have any suggestions to give in terms of reproducing this issue I'm having. Quite clearly this is an isolated case and even though I realise many others have been using qB for a long time without data loss concerns, I do believe this to be a bug inherent to qB, and not caused by outside factors. I've read of similar cases other people have experienced, but there has been no serious attempt made at tracing this bug to the source (assuming it even is one). I've been using qB for probably close to 10 years without ever having had these kinds of issues, and yet, here I am.

I have not yet attempted to reinstall qBittorrent because I first wanted to document the issues I've been facing and in case I need to do follow-up checks I need to maintain my original setup. I'm mainly interested in hearing other people's opinions and possible causes to this problem.

@an0n666

This comment has been minimized.

Copy link
Contributor

@an0n666 an0n666 commented Feb 14, 2020

I have seen other people with the same issue. Qbt deletes files. Maybe it got something to do with bad RAM.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.