Opened 9 years ago

Closed 9 years ago

#4814 closed Bug (worksforme)

transmission-daemon deletes Thumbs.db files that are part of the torrent.

Reported by: telecore Owned by:
Priority: Normal Milestone: None Set
Component: Daemon Version: 2.42
Severity: Normal Keywords: Thumbs.db
Cc: zorlem@…

Description

Seedbox running linux with no other applications except transmission, current version 2.42 (13013).

Cause: suddenly a long time seeding torrents (over 10) stop with error 'piece #xxx is corrupt'. All of them are full blu-ray torrents apparently created with utorrent or Vuze.

First noticed it in transmission 2.13, but was unable to locate the cause of the problem. Then I realized that transmission deletes thumbs.db files even it they are part of the torrent.

Since long time restoring the files manually from archives hoping that the problem will be solved, but apparently no one else reported it, so here I am.

Change History (10)

comment:1 Changed 9 years ago by zorlem

  • Cc zorlem@… added
  • Summary changed from trnamission-daemon deletes Thumbs.db files that are part of the torrent. to transmission-daemon deletes Thumbs.db files that are part of the torrent.

Hello,

I'd like to jump in to confirm this bug. I've noticed the same thing several months ago, with pretty much the same setup as yours - a long-running seedbox, running transmission 2.33 (yesterday I've upgraded to 2.42). To reiterate - these torrents have not been created by me, so they've got the Thumbs.db files and these files should not be removed.

I wasn't able to manually trigger the bug. By checking the code it looks like there is a function in transmission for cleaning Thumbs.db, desktop.ini and similar junk files that are created automatically by external programs or OS functionality removeEmptyFoldersAndJunkFiles(), isJunk(). This function was introduced with #3732. It looks like tr_torrentDeleteLocalData() is the one to blame for this issue. One of the places that this function is called is from setLocation(), so it's possible that the files are removed when one tries to "Set Location" of a new, unrelated, torrent.

HTH, Hristo

comment:2 follow-ups: Changed 9 years ago by cfpp2p

I tried, but I could not trigger the bug...

torrents with ".DS_Store", "desktop.ini", "Thumbs.db"

tried set location in many different ways, among other ways also.

could not trigger, hmmmm???

comment:3 in reply to: ↑ 2 Changed 9 years ago by x190

Replying to cfpp2p:

I tried, but I could not trigger the bug...

torrents with ".DS_Store", "desktop.ini", "Thumbs.db"

tried set location in many different ways, among other ways also.

could not trigger, hmmmm???

Just off the top of my head, did you try "Remove from list" and "Remove data file" and then try to reload the torrent and data?

comment:4 Changed 9 years ago by cfpp2p

Replying to x190:

Just off the top of my head, did you try "Remove from list" and "Remove data file" and then try to reload the torrent and data?

yup, just tried, plus mixed it up a little with some other set location sequences, but still no.

I'll let it rest for now, and try after some more thought.

comment:5 in reply to: ↑ 2 Changed 9 years ago by rb07

Replying to cfpp2p:

I tried, but I could not trigger the bug...

It only shows in Mac OS X, you won't be able to reproduce it on Linux.

I have no idea how the original report sees it in Linux, the code in question is Mac specific.

Version 1, edited 9 years ago by rb07 (previous) (next) (diff)

comment:6 follow-up: Changed 9 years ago by zorlem

The "Set Location" as the cause was just a wild guess. I'm not able to reproduce it on demand, but the Thumbs.db files have been removed at least 5 times so far. I've had to restore them from an archive and initiate a hash check of the failed torrents. The problem is that Transmission doesn't complain about the missing file until it tries to seed it to somebody, so sometimes it could be several days after the files have been removed.

The issue is definitely not Mac specific.

Is there anything else I could do to narrow this down? Maybe adding some logging to the function that removes the files? Although I don't think enough data will be in its scope to review the root cause.

Hristo

comment:7 in reply to: ↑ 6 Changed 9 years ago by telecore

Replying to zorlem:

The problem is that Transmission doesn't complain about the missing file until it tries to seed it to somebody, so sometimes it could be several days after the files have been removed.

Uhm, no.

I created a torrent (95 MB, 741 pieces x 128 kB) with the 'JAR" directories from several blurays. There is no announce URL and this torrent seeds to no one. Yet, the Thumbs.db files were deleted several times so far. Only the Thumbs.db files, everything else is intact.

comment:8 Changed 9 years ago by jordan

  • Version changed from 2.50 to 2.42

I'm not able to reproduce this issue in 2.42 / 2.50.

The description mentions this happening back in 2.13. The "Set Location" code was rewritten from scratch in 2.33 for tickets #3732, #4224, #3781, and #4377 -- so I wonder if maybe the damage was done by earlier versions of Transmission?

If this is still an issue in 2.50, please answer these questions:

  • Is this reproducible?
  • If so, what specific steps should we take to recreate this bug?

This will help us to find and resolve the problem.

comment:9 Changed 9 years ago by telecore

I have not seen the problem lately.

Since the problem appears only when the transmission tries to send the damaged block, this can happen weeks and even months after the files were deleted (I have many torrents that are seeded for years).

So it might be the case that the files were deleted in previous versions and now everything is OK.

comment:10 Changed 9 years ago by livings124

  • Resolution set to worksforme
  • Status changed from new to closed

Please reopen if this occurs with current versions.

Note: See TracTickets for help on using tickets.