usb-creator should drop cache before verifying md5sums

Bug #588348 reported by Graham Inggs
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
usb-creator (Ubuntu)
Expired
Undecided
Unassigned

Bug Description

Binary package hint: usb-creator

I ran into a problem using usb-creator-gtk to create a live USB disk. I first created the disk on a machine with 4GB RAM without error, but the resultant USB disk would not boot. I then tried creating the USB disk on a machine with only 1GB RAM and received the message that the md5sums did not match.

After some experimenting and running md5sum manually I discovered the USB disk had a few bad blocks which do not report read or write errors when accessed. Dropping the filesystem cache or unmounting and mounting the target disk again before checking the md5sums should detect this kind of failure.

Graham Inggs (ginggs)
description: updated
Revision history for this message
komputes (komputes) wrote :

Hello Graham,

The Disk utility (palimpsest) tool is able scan disks and report if you disk is damaged. You can scan your disks using this tool to verify that your media has no bad blocks. Unfortunately, I do not see this as a bug in usb-creator.

Could you please provide the method you use to manually clear filesystem cache and propose what you would like to see usb-creator do in the future. The current process is to format the disk which unmounts it, formats it as FAT32, and mounts it. I am not sure why you would be requesting that usb-creator should do this when it seems to be what it already does.

Changed in usb-creator (Ubuntu):
status: New → Incomplete
Revision history for this message
Graham Inggs (ginggs) wrote :

> The current process is to format the disk which unmounts it, formats it as FAT32, and mounts it.
Thereafter, usb-creator generates md5sums and copies the files to the usb disk. Immediately after writing, it attempts to verify the integrity of those written files by checking the md5sums.

Unfortunately those files may still be in the cache, which makes checking the md5sums pointless.

The method I used to manually verify the files was to eject the disk, remove and re-insert the disk then run
md5sum -c md5sum.txt

I propose that after writing the files to disk, usb-creator should flush the cache before checking the md5sums.
I believe the way of doing this is to unmount and then re-mount the disk, or possibly the following programmatically:
http://linux-mm.org/Drop_Caches

Incidentally, I do not believe palimpsest is able to detect these "soft" bad blocks.

summary: - usb-creator should drop cache before calculating md5sums
+ usb-creator should drop cache before verifying md5sums
Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for usb-creator (Ubuntu) because there has been no activity for 60 days.]

Changed in usb-creator (Ubuntu):
status: Incomplete → Expired
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.