Slashdot is powered by your submissions, so send in your scoop

 



Forgot your password?
typodupeerror
×
Media Data Storage

Low-Level Format For a USB Flash Drive? 252

Luyseyal writes "I unwittingly bought one of these terrible flash cards at Fry's and have managed to nuke two of them, successively. I have a USB flash card reader that will read/write the current one at USB 1.0 speed, but it locks up every Ubuntu and XP machine I've come across in high-speed access mode. I have read that if I low-level format it that it could be fixed, though my current one doesn't support it. My Google-fu must be weak because I cannot seem to find a USB flash reader that specifies that it will do low-level formatting." Can anyone offer advice for resurrecting such drives?
This discussion has been archived. No new comments can be posted.

Low-Level Format For a USB Flash Drive?

Comments Filter:
  • by Anonymous Coward on Friday May 28, 2010 @08:53PM (#32385000)
    The typical ask Slashdot articles of late:

    Dear Slashdot,

    Something brown just fell out of my butt and it smells really bad. What should I do?
  • by Anonymous Coward on Friday May 28, 2010 @08:54PM (#32385002)
    • Could it be because he's got an A-Data card? I've never had a lot of luck with their equipment. Then again, I know people who have no luck with Western Digital, and ole WD has never let me down yet. Go figure.

      Hey @luyseyal, do you have good luck with WD drives? Could be you're not gonna jive with A-Data cards!

      • by MikeFM ( 12491 ) on Friday May 28, 2010 @09:58PM (#32385472) Homepage Journal
        Any brand has the occasional lemon but overall WD is decent. People expect unrealistic things from hard drives too. You're talking about a device extremely sensitive to heat, moisture, vibration, and magnetism at the least and people want to cram 2TB of priceless family photos and their thesis paper into a $50 device without making backups. Yeah that's a recipe for disaster. I know - I've made the same mistake and paid for it. Lately I've been using WD Caviar Black 1TB w/ 64MB cache drives in a Drobo Elite and they've been doing pretty well but I expect to lose a couple of them per year under the stress of being in a server. Certain files I keep in RAID5 on Corsair Nova SSD drives and I use the same drives in my laptops and they've done pretty well. And of course everything is backed up to a NAS drive of which I use both WD My Book World Edition II - 2 TB (2 x 1 TB in RAID1) and Drobo FS. Previously I had used a couple cheaper NAS and Firewire/USB/eSATA drives for backup but all of them died. One happened to die at the same time the main drive died which was unpleasant - both were about six months old. I think hard drive manufacturers should have to include free data restoration for the life of the warranty. The main expense of data restoration is getting exact matching parts for your drive so the manufacturer could do it MUCH cheaper and easier than anyone else. Wouldn't hurt to have a drive stop working completely, unless a jumper is switched, when it senses itself dying so it won't self destruct further. Of course if I got to pick I'd like to see standard sized PC and laptop drives come w/ two physically separate drives and RAID 1 so the drive could sense death and go into a read-only recovery mode. Data is way more valuable than hardware so every possible effort should be made to make data possible to recover. 1TB for $150 is fine with me - instead of offering me 2TB for the same price give me the built-in RAID1.
        • by Anonymous Coward on Friday May 28, 2010 @10:21PM (#32385628)

          I used to do on site computer repair for a few big companies (Dell, IBM being the biggest two, plus others) and we replaced hard drives frequently. Every brand. I think hard drives brands are computer geeks full moons. Ask an ER doc or cop if things get crazy on a full moon and the answer is often "Yes", even though objective research shows there's no such correlation. Sure, some brands are a bit worse than others, but for the most part that only rally matters if you're dealing with a huge number of them. Some home users will see failures regardless of brand, and others will not, again, regardless of brand. It's just a crap shoot when you're dealing with just a few drives at a time.

          • If you put in an order for a large number of identical machines chances are they'll have components from the same batch. If that batch was made on a Friday afternoon then you'll naturally conclude that Foocom's stuff is all a bag of crap.

            Meanwhile, the guy down the road who ordered a few days later gets the ones made after they fired the guy who was eating biscuits in the cleanroom and he swears they're the best.

            And the phantom crumb spreader has found a new job at Bartec...

            • by ThePhilips ( 752041 ) on Saturday May 29, 2010 @07:06AM (#32387740) Homepage Journal

              If you put in an order for a large number of identical machines chances are they'll have components from the same batch.

              I'd say it depends.

              Our supplier of storage solution "randomizes" the batches. IT was in the beginning checking the HDDs too, only to find that most deliveries contain drives from several batches.

              Other company I have worked for got Dell servers and also RAID10. Few months later on Thursday one drive died. Dell provided new drive on Friday and recovery was started - only to find that another original drive failed over the weekend too, rendering the storage dead. All drives in the original RAID10 were from the same batch.

              Some companies do get it. Some do not.

              P.S. Having *all* drives from different batches, as was explained to me by data recovery specialists, is also bad if one later would want to try to recover information from the dead drive's platters: different batches might have different controllers with different configurations making them irreplaceable. If you have two drives from the same batch and one of them is dead - recovery would be relatively fast and cheap. Recovering information directly from platters is magnitude(s) more expensive.

            • by sqlrob ( 173498 )

              I worked for a company that did a huge order for POS machines. Prep work required opening and putting in some interface cards, and there were at least 3-4 different types for things that were theoretically the same model. Completely different motherboard layouts, so it wasn't minor changes like different HD models.

        • The main expense of data restoration is getting exact matching parts for your drive so the manufacturer could do it MUCH cheaper and easier than anyone else.

          I think the main expense is paying people's wages.

          One of my uncles had a Samsung drive that melted. Something happened to the motor - it got super hot, and black smoke was billowing out of it. He was quoted $3k for data recovery.

          A bit of networking and a few friends later, he had a nice professional do it for him for about $80+S&H. :)

          I don't feel that warranties should cover data recovery. Failure to understand the technology and make proper backups (even when warned repeatedly) means a lot of people wo

    • by imp ( 7585 ) on Friday May 28, 2010 @10:15PM (#32385592) Homepage

      This formatter won't do anything to help you out. It will just put a new filesystem on the part. You can't 'reformat' FLASH. Bad is bad, and you lose.

      • by dgatwood ( 11270 ) on Saturday May 29, 2010 @03:09AM (#32387004) Homepage Journal

        And it's probably not the fault of the flash part anyway. I'm assuming by "hang", the original poster meant that accesses to the device stall indefinitely. Since the device stalls only when accessed at USB 2.0 speeds, that almost completely rules out the flash part as the culprit. Although flash drives do support multiple protocols, there's really no good reason for a flash controller to implement support for more than one protocol, as flash parts have to support all of them. Thus, they're going to pick the fastest protocol and use it every time, without regard to what speed the USB side of the bridge is using for communication. Therefore, the only way the USB speed should realistically trigger a failure in the flash part is if the flash part can't handle high throughput.

        It's important to understand that actual cameras write data to flash parts as quickly as the flash part can take it. Thus, a failure caused by high throughput (in the absence of specific workarounds in the camera) would cause the card to be completely and totally nonfunctional in basically any real-world camera hardware. Therefore, the fact that this card is even on the market is a pretty strong indication that the problem is on the other side of the USB bridge---either the USB bridge silicon itself, the USB cable, the host silicon, or drivers.

        Yes, lots of people are having trouble with those cards, but in every report, the failure was an outright controller failure, with all data lost, not problems accessing it at certain speeds. I'd be very surprised if that sort of failure were anything other than a junk flash reader.

        Now I know what you're thinking. USB card readers "just work". No, they don't. I was rather miserable using dd to manually work around bugs in a USB flash reader just a few years ago. In that particular case, throwing large requests at the thing over a high speed connection caused the device to randomly return a copy of block zero instead of the expected data. Did I mention that this particular controller silicon was used for dozens of products by at least half a dozen major manufacturers for a couple of years before the flaw was discovered? Or that the bug was never fixed in firmware or silicon? :-) So yeah, a thoroughly broken flash reader would not be at all surprising.

        First thing I'd do is grab yourself a new flash reader and make sure it doesn't use the same chipset as the one you have. If that doesn't help, *then* you can blame the flash part, and there probably isn't anything you can do about it other than ripping it open and making cufflinks out of it.

        If you have access to the flash reader firmware, you might try using a different access mode. I'm guessing that's not an option, though.

        Worst comes to worst, if it worked okay with a camera, you could try using the camera's flash controller to read/write the flash part. It will probably be dog slow, but at least you can copy the data off the card before you toss it out.

      • by Skapare ( 16644 ) on Saturday May 29, 2010 @08:35AM (#32388086) Homepage

        Yes you can low level format flash drives. There is a layer between the real physical flash memory and the presented hard drive, which does things like level out the wear applied to the flash cells by rotating a pool of blocks (why the drive is always a little smaller than the power of two the flash chips can store). A low level format would clear the flash chips themselves and reset the drive emulation layer to initial state (most likely zero assigned blocks and a full pool of unassigned in the canonical order). But the low level formatter would require low level access to do this, and the computer interface (SD slot pins, USB, etc) may not have a way to do this.

        The formatter on the SD Association site, however, appears to be nothing more than a specialized filesystem formatter. Maybe it formats the filesystem and adds some extra stuff afterwards. There is zero indication that it is a low level formatter.

        That said, the OPs problem may be more of a case of defective flash chips and/or defective drive emulation and/or defective interface to the computer via the SD pins. It may be defective only at high speed or it may be defective at all speeds (if the speed can be forced lower). This may be a case of the manufacturer doing overclocking with some higher percentage of manufactured devices that just can't make it at that increased speed. Imagine your computer manufacturer taking 1 GHz CPUs, overclocking them at 3.333 GHz, verifying that the units boot the test utility on the assembly floor, and shipping them to consumers with the OS raw sectored onto the hard drive by never actually booted to see if it can run on a CPU that gets an undetected one-bit error every second.

    • by mcrbids ( 148650 )

      You missed the point. He has shatty hardware. Best advice is to buy another one. price watch? [pricewatch.com]

      • Re: (Score:3, Funny)

        by SEWilco ( 27983 )

        You missed the point. He has shatty hardware. Best advice is to buy another one.

        Best advice is to buy a bunch of them, plug them into a sufficiently large USB hub, put it in a waterproof box, and configure it as a RAID USB device.

  • Give DBAN a try. This tool never fails me for any kind of disk I throw at it.

    http://www.dban.org/download [dban.org]

    • Re: (Score:2, Redundant)

      by X0563511 ( 793323 )

      You don't know what low-level format means, do you?

      • Neither do I, in the context of a flash drive. In the context of a rotational disk, it means spinning the disk and rewriting the sector boundaries on each cylinder to make sure that they align on the platter with where the head stops. It's been a good 15 years since I had any hardware where this was needed. What does it mean in the context of a flash drive? It's just a memory chip with a cell-remapping controller in front of it. It doesn't have sectors that can become misaligned, just cells that can be
      • Re: (Score:2, Redundant)

        by Svartalf ( 2997 )

        I think most people don't. Unless you're doing it to a floppy or an OLD MFM/RLL style hard disk, those "low-level" formatter programs don't DO what people think they do. All they do is a full-disk zero write which triggers a device re-init to factory config which does a recalibration in some cases, and maps spare blocks (if possible) to bad-block spots so the disk looks pristine at the filesystem level. This also works for flash based devices after a fashion.

    • by Homburg ( 213427 ) on Friday May 28, 2010 @09:33PM (#32385326) Homepage

      From what I can see, DBAN deletes and overwrites all the data on the device. I don't see why that would help the OP any more than just repartitioning and reformatting would.

      • by Unequivocal ( 155957 ) on Saturday May 29, 2010 @01:27AM (#32386662)

        I'm not sure either - but here's a guess: If you write data onto every sector of the drive, perhaps the fubar sectors get noticed by the internal controller at that time and get blocked out from future writes. So by reading/writing out the entire drive, maybe you clean it up a bit.. Until of course more bits go bad which it sounds like would be inevitable in the OP's case.

  • by Anonymous Coward

    Not sure when it locks up the system.

    Try

    HP USB Disk Storage Format Tool

    http://www.pcworld.com/downloads/file/fid,64963-order,4/description.html

    • That's the standard USB key high level format utility, he has an SDHC with a USB interface to his PC.

  • GNU Shred? (Score:4, Interesting)

    by Jim Hall ( 2985 ) on Friday May 28, 2010 @09:12PM (#32385150) Homepage

    "... but it locks up every Ubuntu and XP machine I've come across in high-speed access mode. I have read that if I low-level format it that it could be fixed, though my current one doesn't support it. My Google-fu must be weak because I cannot seem to find a USB flash reader that specifies that it will do low-level formatting."

    I wonder if GNU Shred [gnu.org] would be something to try, at the device level? Let's say your flash drive shows up as /dev/sdc, then you'd do this:

    shred -v -n 1 /dev/sdc

    (You might even try -n 3.) I think this would work, but I don't know what wear leveling would do when shredding a USB flash drive.

    Once you run shred, you'll have wiped the entire flash drive. That means you'll need to repartition the device and lay down a new filesystem.

    Might work.

  • Low Level (Score:4, Informative)

    by jythie ( 914043 ) on Friday May 28, 2010 @09:15PM (#32385174)
    Ahm.. has the meaning of this term changed? Last time I heard the term it referred to syncing a drive and it's controller, and thus fell out of usage with the rise of IDE disks.
    • by Barny ( 103770 )

      Yeah, now it generally means to zero-wipe a drive.

      I remember having to do low level formats on my first XT computer, damn MFM controller took about 3 hrs to do a 20MB seagate drive ;(

  • Ridiculous (Score:3, Funny)

    by phantomcircuit ( 938963 ) on Friday May 28, 2010 @09:16PM (#32385194) Homepage

    That's ridiculous. A-DATA sells crap. Reformatting will not change that.

    • by Barny ( 103770 )

      You have not heard of the phrase "chrome plated turd"? :)

    • Re: (Score:3, Interesting)

      by Cylix ( 55374 )

      On a positive note they try tremendously hard to save their awful reputation. At least, they troll newegg a lot and try to encourage customers to contact support.

      It always seemed like a red flag to me.

      Just think... one horribly cheap SD card has forced thousands of individuals to waste some previous bits of their time. The total combined value of those wasted hours would have bought hundreds of SD drives.

  • Not the flash chip (Score:2, Informative)

    by Anonymous Coward

    The controller is probably fried, maybe a voltage spike or static electricity occurred. Or it's just cheap Chinese crap. So it can't talk to the USB host controller properly.

    The actual NAND memory is probably fine but unless you want to resolder a controller chip just toss the drive.

    I've used the industrial paper shredder at work to destroy flash drives when they were no longer recognizible by the host yet they still had potentially sensitive personal or corporate data on them.

    Take the PCB out of the housin

    • Encryption (Score:4, Insightful)

      by xororand ( 860319 ) on Friday May 28, 2010 @09:23PM (#32385244)

      Encrypt your data to avoid such hassles in the future. Encryption makes theft or loss of your medium a non-problem, besides the lost material value.

    • Re: (Score:2, Flamebait)

      by X0563511 ( 793323 )

      Learn to fucking read already will you people?

      THIS [wikipedia.org] IS NOT A USB "DRIVE"

    • "Take the PCB out of the housing, snap off the USB connector and feed the board into it, the flash chip gets ground to bits so no adversaries can recover your data. :D"

      I just shove such drives into a soda can, crush the can under my boot, and put it out with other cans to be recycled.

      • So you're the bugger causing the impurities in my recycled aluminium ingots. You know how much you're costing me to melt and electro-purify them?

      • by znerk ( 1162519 )

        "I just shove such drives into a soda can, crush the can under my boot, and put it out with other cans to be recycled."

        ... thereby introducing toxins [freegeekvancouver.org] to the aluminum recycling industry, and incrementally poisoning soda drinkers (including yourself). Good job!

  • dd of course (Score:5, Informative)

    by v1 ( 525388 ) on Friday May 28, 2010 @09:25PM (#32385264) Homepage Journal

    sudo dd if=/dev/zero of=/dev/rdiskxxx bs=1024000

    or whatever variation you need for your distro. The above is for mac os x. yes, rdisk is a character device I know I know, but for some reason os x io's a LOT faster o that than the block device. (double or better) No idea why. Block works too tho, whatever works for you. Just plug in the correct disk number for the xxx. Careful which device you're nuking, dd is both swift and unforgiving.

    I'd also like to get slightly pedantic and point out that this is NOT a low level format. Low level format refers to laying down the address blocks, and also the data headers and trailers. All dd does is write zeros to the meat of the data block, and update its checksum. There's no such thing as a low level format for non magnetic media because flash drive blocks are electrically addressed, not physically.

    FWIW, you can probably tack on "count=20" to make things go much faster. I assume all you need is the partition table completely zapped, and the first 20mb should do it fine. Without this it will wipe the entire device, which for a flash drive may take a little bit. But then again your distro or whatnot may try to find a backup copy of the boot block and partition table etc at the end of the device in which case just wipe the whole thing to avoid it "fixing it" for you.

    • by bugnuts ( 94678 )

      From everything I've read when researching flash drivers, thumb drives (and most removable flash drives) have auto-wear-levelling, which may map the sector to a different physical sector. You basically cannot do a low level format, so the suggestion above will probably be about as close as possible. Each sector will still have its internal tags which probably will not be overwritten with dd.

      • by v1 ( 525388 )

        doing a full device write will only increment the "total writes" count for every block by 1. In that respect it won't cause any wear level adjustments to take place at all.

        That reminds me of something slightly off-topic here. We discussed recently the problem of block sizes other than 512 bytes causing some systems to baulk. I wonder if any flash drive manufacturer is brave enough to use their flash block size (typically what, 32k? guessing) as their device block size. That would allow the OS to work w

    • I think he meant something that clears all the internal state, in addition to the user data. Flash drives surely keep track of bad blocks and some state for wear-leveling. I think his terminology was correct, because as I understand it, a low-level format of a hard drive for example isn't simply writing zeroes to the user data, it's asking the mechanism to rewrite some of its housekeeping data too.
    • Re: (Score:3, Insightful)

      by Piranhaa ( 672441 )

      Wrong, wrong, wrong. Flash doesn't store its data in "zeros", but rather in "ones"

      Read this: Undeadly Article [undeadly.org]

      Go down to the part that reads:

      One of the tricks you can try is erasing the flash device entirely, but you need to realize the "erased state" for flash is when it is filled with all 1's. People regularly make the mistake of filling flash based storage devices with all zeros (as is typically done with real disks) without every realizing what they are doing.

  • Somewhat offtopic, but related. I have a similar question but with respect to a USB stick. It seems that over time and with repeated use, my USB stick has gotten slower and slower. There was an article here a while ago about such a slowdown with SSDs.

    So is there a utility/tool (for windows) that can test/restore USB memory stick performance?

  • I have used: dd (Score:2, Informative)

    by jemc ( 738933 )

    First find out the device of the flash disk.

    The following fixed a USB disk which was hosed:

    dd if=/dev/random of=/dev/sda
    or
    dd if=/dev/zero of=/dev/sda

    It's not a format, but fixes corrupt files, which can cause the disk to be unuseable.

  • RTFM (Score:5, Funny)

    by Sponge Bath ( 413667 ) on Friday May 28, 2010 @09:53PM (#32385448)

    Can anyone offer advice for resurrecting such drives?

    Spell: Resurrection
    Level: 7
    Range: Touch
    Duration: Instantaneous

    • Re:RTFM (Score:5, Funny)

      by Donniedarkness ( 895066 ) * <Donniedarkness@g ... BSDcom minus bsd> on Friday May 28, 2010 @10:04PM (#32385524) Homepage
      He said "low-level", which I suppose is what's getting you confused. I know it's subjective, but to be considered "low-leveled" for me, it'd have to be under level 5.
      • by Rolman ( 120909 )

        He said "low-level", which I suppose is what's getting you confused. I know it's subjective, but to be considered "low-leveled" for me, it'd have to be under level 5.

        Phoenix Down always works, even at the lowest levels.

    • Aren't there some material components for that spell?
      • Aren't there some material components for that spell?

        The spell requires one dead body.

  • The real answer (Score:5, Interesting)

    by Burz ( 138833 ) on Friday May 28, 2010 @10:06PM (#32385534) Homepage Journal

    If speed is a factor, then none of the answers I read above apply to your issue.

    Your el cheapo flash card has a temperature-sensitive hardware defect which probably turned into an inability to read at hi-speed when the unit heated up to a certain temp and caused some poorly-made part of the chips to act flakey or broken. At USB 1.x speeds, the flash unit remains cool so access to it remains OK. Consider returning that flash card.

    Of course, there is another possible explanation: Your particular flash reader device has an incompatibility with your flash cards (possible but not likely). You could try different readers if you haven't already.

    • by hduff ( 570443 )

      If it's a heat issue, can't you put the device in a freezer for a while and then attempt to at least recover the data? Or would just a little use heat it too much?

      BTW, I know this guy's drive is toast, but I'm just askin'.

      • by Burz ( 138833 )

        AC is right that the freezer isn't a good idea.

        But I might try it in the above-freezing part of the fridge.

        • by znerk ( 1162519 )

          AC is right that the freezer isn't a good idea.
          But I might try it in the above-freezing part of the fridge.

          Hmm... got a laptop? Might try attempting to recover the data *in* the fridge.

  • I have tried adata. Slow and prone to failures. THey are pure pieces of junk. Return it if you can, and if not, then you just got an education.
  • "low level format" is a term relevant to old magnetic disk drives, you can't do that to a solid state logical device like flash.

    you probably can't fix it at all, if it sort of works at low speed and fails athigh speed there is probably a hardware fault not a formatting issue, a formatting issue would present seemingly at random or when writing a certain amount of data, being affected by speed strongly indicates a hardware defect or failure.
  • Low-Level Format (Score:5, Informative)

    by Lord Byron II ( 671689 ) on Friday May 28, 2010 @10:15PM (#32385594)

    There's no such thing as a "low level format" on a flash drive. The term refers to specifying where the tracks are at on a magnetic disk. It was possible, although incredibly stupid, back in the day to perform a low level format on a hard drive and tell it to move the tracks closer together. As a result, you could bump your 10MB disk to 12MB.

    This works only because the physical magnetic disk doesn't "know" anything about tracks and sectors. It always drives me crazy when someone who wants to wipe a drive clean, asks me about a "low level format", when what they want to do is zero out the drive (ie dd if=/dev/zero of=/dev/sda).

    For a flash drive, each memory cell physically has a 1-to-1 correspondence to a bit (or several bits) of information, so there's no low level format.

    • Re:Low-Level Format (Score:5, Interesting)

      by romiz ( 757548 ) on Saturday May 29, 2010 @01:28AM (#32386670)
      You're wrong.

      There is definitely a special 'erase' command for SD-cards. See page 33 for the simplified specification [sdcard.org]. The problem is that unless you have direct access to the SD controller - perhaps on a mobile phone like the N900, the USB mass storage abstraction hides completely this feature. Formatting using this command is usually very fast compared to writing to all existing blocks.

      The reason for that is that the card uses a translation layer to mask the physical deficiencies of the flash memory. Bad blocks in NAND flash are even a bigger problem than on a magnetic disk, but using an error-correction mechanism implemented with a Hamming code and 'spare bits' for each block, the translation layer hides all of this to the user, presenting a 'perfect' storage area. If you send an erase command, the translation layer only needs to take care of bad blocks and clear all others, instead of trying to write 'formatting' data it does not recognize.

      In a way, this command is equivalent to the TRIM command for SSD drives: it is useful in the long term and improves performance, but not obviously missing in day-to-day use. But when SSD users pay a premium to use them in a very efficient way, the absence of consideration for performance of SD-Memory cards users led to the current situation, where the command exists but cannot be accessed easily.

      • by Skapare ( 16644 )

        So where is a Linux program to do this special erase command that exists in the standard ... perhaps doing the erase over the entire drive and/or specified blocks?

  • Flash is cell-based. There is no way to low-level format a Flash chip without advanced chip-making equipment. In addition, nobody wants to do it, because it cannot help any problems.

    So your Google Fu is exactly right, no reader can do it.

    However what you can try is throwing it away and getting some quality storage instead. That is about the only thing that will help.

    • by Skapare ( 16644 )

      "low level" just has a different meaning for drive-emulating flash devices, than it does for spinning metal platter hard drives. Obviously, a lot of posts on this article are from people that don't understand the difference. In your case, you're not acknowledging that there is this layer of emulation, which manages the wear leveling and presents a (supposed to be) more reliable set of data blocks stored in flash chips that can have some cell failures. Maybe the OP's problem can be cured for the time bein

  • How about... (Score:4, Insightful)

    by PNutts ( 199112 ) on Friday May 28, 2010 @10:21PM (#32385634)

    Like any good developer I'm ignoring what the customer asked for and trying to figure out what they need. ;)

    You want to be able to write to the card at more than 1.0 speed. Here's some random thoughts:

    1. Have you tried a different reader? Fry's sells them for as little as $7.99 (Sorry, couldn't resist that one.)
    2. Have you tried a different class of device? How about formatting in a camera or PDA and see if that allows you to then read/write at the faster speed on a PC.
    3. Can you return or exchange it as defective? If it isn't transferring at the advertised rate then that assumption can be made. See if they can get to full speed at Fry's.
    4. You didn't mention what versions of Ubuntu you tried, but is it current? How about Windows 7 or a live CD of another distro? (see #1)

    Of all the ba-jillion cards out there the fact that you've had problems with two of them with the symptoms you describe makes me think the problem might be on your end. Just a guess. Either way, good luck.

  • by ChipMonk ( 711367 ) on Friday May 28, 2010 @10:21PM (#32385642) Journal
    And I do mean one time, but three years later I'm still using the thumb drive. The following assumes a Linux environment. First, pull off any data you can (and want to), then unmount it and type:

    #badblocks -w -s device-path

    Use the entire device, e.g. /dev/sdg, not /dev/sdg1. This guarantees that all the Flash blocks on the chip are reset. The patterns 0xAA, 0x55, 0xFF, and 0x00 are written, then checked; "shred" does no checking, and doesn't report errors. The "-s" is to show continuous progress.

    If you get any errors (and you probably will, if the device is as weak as you say), simply re-run the "badblocks" command, and note if the error count goes down. The one time I did this, I got a few errors (less than 10) the first time, but zero the second time. Whatever badblocks caused on the low level of the device, it was just what the doctor ordered. I hope it can help you, too.
  • by Dahan ( 130247 ) <khym@azeotrope.org> on Friday May 28, 2010 @10:32PM (#32385708)

    Here's what I used to use for a low-level format:

    A>debug
    g=c800:5

    If you've got a fairly speedy machine, set the interleave to 1:1. Don't forget to input the list of bad blocks so the drive won't try to store data in them. There's some more info in this KB article [microsoft.com]

    HTH, HAND

    • Re: (Score:3, Informative)

      That's the routine for later-generation 8-bit cards. The card in the original IBM PC-XT, however, was a Xebec card. There are registers you need to poke values into, again using DEBUG. It kicks off some code in the 'ROM' but it runs completely blind to the PC, i.e. the code runs entirely in the controller on the Xebec card. You only know that it's done when the LED on the hard drive eventually goes out. You can apply a stethoscope or listen closely to hear the drive stepping, to know that it's still do

  • by w0mprat ( 1317953 ) on Friday May 28, 2010 @10:39PM (#32385746)
    You need to learn you lesson for patronizing vendors of cheap garbage technology.

    Why did you not pay a little more for your flash drives and get something more reliable? If you want to go to the trouble of resurrecting your half-dead flash drives you can spend the $10-20 on a new one from a major brand name.

    The problems you describe sound like shitty controller circuitry, that's either failing, poorly designed or quite likely both.

    The lower level operations of flash are abstracted away behind the controller, with the exception of some drives theres you can't do much about it.

    USB Flash drives and cards can be brought back to as-new performance by performing a write-erase pass over the entire drive. This was used to revive degraded used SSDs that would drop in performance, the TRIM feature now takes care of this on the fly. About all you can do for thumb drives and cards is to perform a single erase pass. If that doesn't work you're SOL.
  • by Sir Holo ( 531007 ) on Saturday May 29, 2010 @12:49AM (#32386488)
    If you want to use it, go buy a reliable piece of hardware.

    If you want to wipe it for disposal, just hit it with a hammer.

    Some things are not worth your time. Even if your time has no value.
  • by beachdog ( 690633 ) on Saturday May 29, 2010 @12:51AM (#32386502) Homepage Journal

    I am responding to your post on the chance that you are seeing a photo import bug because you use gthumb.

    The 16GB flash card you link to in your Ask Slashdot question looks like the 8GB flash card I use in my digital camera.

    If you are doing digital photography and using Ubuntu or a Linux, take note that the photo import utility in gthumb is broken in Ubuntu 9.10. The gthumb version is 2.10.11 and the specific thing broken is photo import of jpeg images. Photo import fails if there are .avi movie files on the flash card.

    I have had a series of flash card aggravations and here is my version of the preceding AskSlashdot comments:

    1. Digital cameras format flash memory cards with minor variations or they store image data with minor variations. I work around potential glitches by keeping the card in the camera and connecting the camera to the Ubuntu computer.

    2. Use gthumb (note bug above) or the graphical file tool Nautilus. The top level menu item "Places" in Ubuntu starts Nautilus. Copy the files from the camera to the computer.

    3. Speaking about USB flash memory, I feel they have devolved into a Windows quality file transfer device = WQFTD That means, they work using the supplied file system. The success of the same devices using Ext2 and Ext3 file systems is problematic.

    4. Measuring the read and write reliability of these WQFTDs at the bit level is a difficult problem. As I mention in my journal, I have a big name DVD drive that is a WQFTD. I know it fails when reading huge 8 bit data files. But, building a tool to prove when and where it fails is beyond my available time as an evening hacker.

    5. So one answer is "simplify and work around your WQFTD" without challenging it's limits.

    • Re: (Score:3, Informative)

      by John_Sauter ( 595980 )

      2. Use gthumb (note bug above) or the graphical file tool Nautilus. The top level menu item "Places" in Ubuntu starts Nautilus. Copy the files from the camera to the computer.

      Rather than gthumb or Nautilus, I use the command-line tool rsync, as follows: rsync -avc (source) (destination), with the source being the flash memory card. When the copy is complete I remove the card, re-insert it, and run the command again. The "c" in "-avc" means to checksum the corresponding files, and copy them again if the checksums don't match. When this triggers a re-copying of a file I know that the card is failing, and discard it.

      I bought a bunch of cheap cards when I first got my camera. Af

  • No. (Score:2, Redundant)

    by CAIMLAS ( 41445 )

    In short: you're screwed. Unless you've got important data on them (ie not recoverable from a different source), throw them out and pick up some more (preferably a different model, at least until this one improves.)

    What you've got on your hands there is defective flash (likely). There is no 'recovering' it as a storage medium. In essence, you paid for a 16GB, $40 floppy drive. Next time, unless you've got an overt need for 16GB all on one card, get several smaller ones. Sure, you're "throwing away" your car

  • From watching SuperFlyFlippingA's videos on YouTube, I would probably say you can't do any low level format unless you have a custom USB mass storage driver. The reason is due to the USB drivers being generic in nature and the only way you can send it the complete ATA command set (i.e.: secure erase) is to attach your device directly to the motherboard's ATA/SATA interface (maybe through some bridge?). MHDD won't help even if it knows how since the generic driver blocks the command(s).
  • http://linux.die.net/man/8/badblocks [die.net] Most modern hard drives don't need low level formatting anymore as they will rewrite the block headers when they write the block (the gap between the header and the data was a waste of space) Flash drives have always erased and written all the data in the 'superblocks'. But flash drives have a very simple filesystem on them to do the wear levelling the best way to reset this is to use the drive's "Secure erase" function. If you can't get at this feature or the drive is
  • by Hognoxious ( 631665 ) on Saturday May 29, 2010 @09:31AM (#32388366) Homepage Journal

    I unwittingly bought one of these terrible flash cards at Fry's and have managed to nuke two of them, successively

    You stole the second one?

I tell them to turn to the study of mathematics, for it is only there that they might escape the lusts of the flesh. -- Thomas Mann, "The Magic Mountain"

Working...