rcksum-xxxxxx temporay files left on disk by zsync

Bug #477551 reported by psl
24
This bug affects 5 people
Affects Status Importance Assigned to Milestone
zsync (Ubuntu)
Confirmed
Medium
Unassigned

Bug Description

Binary package hint: zsync

zsync 0.6, Ubuntu 9.10 i386

# zsync -V
zsync v0.6 (compiled Nov 6 2009 05:52:12)
By Colin Phipps <email address hidden>
Published under the Artistic License v2, see the COPYING file for details.

DESCRIPTION:
zsync creates temporary files rcksum-xxxxxx during read of seed files to the current directory. When zsync is interrupted during this stage (like CTRL-C), temporary file is left on the disk. I think, this file is useless and zsync doesn't use it on next run; it creates new temporary file.

EXAMPLE:

I start with empty directory and start zsync.

$ zsync http://server/zsync/ubuntu-9.10-server-i386.iso.zsync
#################### 100.0% 0.0 kBps DONE

No relevent local data found - I will be downloading the whole file. If that's not what you want, CTRL-C out. You should specify the local file is the old version of the file to download with -i (you might have to decompress it with gzip -d first). Or perhaps you just have no data that helps download the file
downloading from http://nas/zsync/ubuntu-9.10-server-i386.iso:
#####--------------- 25.6% 11713.8 kBps 0:42 ETA ^C

$ ls -ltr
total 176620
-rw------- 1 root root 180674560 2009-11-07 17:01 ubuntu-9.10-server-i386.iso.part

rcksum file was not created, no seed file was available. Restart the process and press CTRL-C:

$ zsync http://server/zsync/ubuntu-9.10-server-i386.iso.zsync
#################### 100.0% 701.8 kBps DONE

reading seed file ubuntu-9.10-server-i386.iso.part: ************************************************************************************************************************************************^C

$ ls -ltr
total 330268
-rw------- 1 root root 671686656 2009-11-07 17:03 ubuntu-9.10-server-i386.iso.part
-rw------- 1 root root 671686656 2009-11-07 17:03 rcksum-ZUfFCc

rcksum temporary file was created and left on the disk. Start the same action again:

$ zsync http://server/zsync/ubuntu-9.10-server-i386.iso.zsync
#################### 100.0% 0.0 kBps DONE

reading seed file ubuntu-9.10-server-i386.iso.part: ***************************************************************************************************************************^C
$ ls -ltr
total 482932
-rw------- 1 root root 671686656 2009-11-07 17:03 ubuntu-9.10-server-i386.iso.part
-rw------- 1 root root 671686656 2009-11-07 17:03 rcksum-ZUfFCc
-rw------- 1 root root 671686656 2009-11-07 17:04 rcksum-oBwWoL

New rcksum temporary file was created. Restart the process, wait till download and interrupt with CTRL-C:

$ zsync http://server/zsync/ubuntu-9.10-server-i386.iso.zsync
#################### 100.0% 0.0 kBps DONE

reading seed file ubuntu-9.10-server-i386.iso.part: ****************************************************************************************************************************************************************************************************************************************************************************************************************************************************Read ubuntu-9.10-server-i386.iso.part. Target 26.9% complete.
downloading from http://server/zsync/ubuntu-9.10-server-i386.iso:
#################--- 88.2% 11804.4 kBps 0:06 ETA ^C

$ ls -ltr
total 896612
-rw------- 1 root root 671686656 2009-11-07 17:03 rcksum-ZUfFCc
-rw------- 1 root root 671686656 2009-11-07 17:04 rcksum-oBwWoL
-rw------- 1 root root 671686656 2009-11-07 17:05 ubuntu-9.10-server-i386.iso.part

No new rcksum temporay file left on the disk (was deleted by zsync during the process). Restart the process and wait till end:

$ zsync http://server/zsync/ubuntu-9.10-server-i386.iso.zsync
#################### 100.0% 0.0 kBps DONE

reading seed file ubuntu-9.10-server-i386.iso.part: ****************************************************************************************************************************************************************************************************************************************************************************************************************************************************Read ubuntu-9.10-server-i386.iso.part. Target 89.9% complete.
downloading from http://server/zsync/ubuntu-9.10-server-i386.iso:
#################### 100.0% 9784.0 kBps DONE

verifying download...checksum matches OK
used 604180480 local, fetched 67506566

$ ls -ltr
total 962600
-rw------- 1 root root 671686656 2009-11-07 17:03 rcksum-ZUfFCc
-rw------- 1 root root 671686656 2009-11-07 17:04 rcksum-oBwWoL
-rw------- 1 root root 671686656 2009-11-07 17:08 ubuntu-9.10-server-i386.iso

SUMARY:
zsync has a bug from my point of view, rcksum-xxxxxx temporary files has to be deleted before zsync exit (after CTRL-C or when disk runs out of space, etc).

Tags: vivid
Steve Beattie (sbeattie)
Changed in zsync (Ubuntu):
status: New → Confirmed
importance: Undecided → Medium
Revision history for this message
Niklas Wenzel (nikwen) wrote :

Experiencing this, too, on Utopic.

Revision history for this message
Daniel Kessel (dkessel) wrote :

Still present on vivid.

tags: added: vivid
Revision history for this message
Gene Soo (genesoo77072) wrote :

Not only is ZSYNC leaving the temporary file, it is also creating that file in the current working directory. In my case, that happens to be the sub folder for all of my Installation and Maintenance BAsH scripts. This temp working file should be created in some sort of temp data folder eligible for cleanup by system processes in case the ZSYNC commands terminates early before work file cleanup can occur.

Revision history for this message
Stefan K. (archilles) wrote :

Xenial is also affected.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.