TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

The case of the missing WAV audio files on the FAT32 SD Card

156 点作者 shanselman大约 5 年前

12 条评论

amluto大约 5 年前
&gt; I didn&#x27;t want to take any chances to I picked up a 5 pack of 32GIG high quality SD Cards. [link to Amazon]<p>The lesson: never ever buy SD cards or USB sticks from Amazon. Buy them from a reputable company.
评论 #22590031 未加载
评论 #22590586 未加载
评论 #22590282 未加载
solstice大约 5 年前
Wow, what a ride. 7-zip is awesome. For anything involving (suspected) data loss or &quot;data disappearance&quot;, I usually try Testdisk&#x2F;photorec from <a href="https:&#x2F;&#x2F;www.cgsecurity.org&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.cgsecurity.org&#x2F;</a>
评论 #22590845 未加载
Fr0styMatt88大约 5 年前
That was an awesome article! The kind of rabbit hole I’d gladly go down :)<p>SD cards and USB sticks are just.... weird. I haven’t delved too deeply but maybe someone here knows.... why is this? At this point I almost think of them as ‘not disks’. The particular weirdness I’m thinking of is I’ve seen more than one drive just seem to die, just because you try and repartition them in Windows. Not even filling the drives up.<p>Is it the case that USB drive and SD card firmware is just crap? Like it makes assumptions about the device other than ‘this is just a set of blocks on flash memory’ and actually needs things on the disk at a file system level to be a certain way for it to work properly? I’m really curious.
评论 #22589997 未加载
评论 #22589634 未加载
评论 #22592043 未加载
评论 #22589982 未加载
评论 #22590685 未加载
rahimnathwani大约 5 年前
This advice should go without saying:<p>&quot;Re-format the random SD cards you get from Amazon specifically on the device you&#x27;re gonna use them.&quot;<p>Do this also for portable hard drives.
评论 #22589038 未加载
评论 #22589955 未加载
sbradford26大约 5 年前
7-Zip is pretty awesome. At one point I had a file that simply wouldn&#x27;t delete in Windows. Came across a random thing online that said to try and delete it from 7-Zip. Simple as that 7-Zip was able to delete the file while everything else couldn&#x27;t.
评论 #22592262 未加载
评论 #22592160 未加载
hag大约 5 年前
I&#x27;m wondering if `binwalk`&#x27;ing the initial dd-image would have worked. That&#x27;s the first thing I would try.
评论 #22592777 未加载
评论 #22592088 未加载
userbinator大约 5 年前
Among one of the reasons the FAT family of filesystems is in widespread use is its simplicity, which makes data recovery easier. Writing a FAT driver&#x2F;reader is a common assignment for systems programming courses, and I&#x27;ve done it myself too.<p>I took a quick look at the truncated image he provided, and it looks like the fields in the MBR and boot sector are OK; but things start getting weird after that.<p>The root is at cluster 2 where it normally should be (byte offset C00000 in the image), but its second entry is that all-spaces directory which claims to start in cluster 4, and furthermore its creation date is recent (2020-03-12).<p>Cluster 3 (C08000) is a directory which points to ZOOM0002.hprj, ZOOM0002_Tr1.WAV, and ZOOM0002_Tr2.WAV, its &quot;.&quot; is correctly pointing to itself, but its parent according to &quot;..&quot; is at cluster 4. It is directory &quot;ZOOM0002&quot;.<p>Cluster 4 (C10000) is a directory which contains 3 directories ZOOM0001 through 3, its &quot;.&quot; is correctly pointing to itself, and its parent is pointing to the root (indicated with a cluster of 0). This is, according to the root, the &quot;all spaces&quot; directory.<p>Cluster 5 (C18000) is ZOOM0001 directory, and its &quot;.&quot; and &quot;..&quot; are correct.<p>Cluster 6 (C20000) is a file, ZOOM0001.hprj<p>Cluster 7 (C28000) is a file, ZOOM0001_LR.WAV<p>In other words, everything looks OK except for that all-spaces directory in the root. According to page 25 of <a href="https:&#x2F;&#x2F;www.zoom-na.com&#x2F;sites&#x2F;default&#x2F;files&#x2F;products&#x2F;downloads&#x2F;pdfs&#x2F;H6-Manual_0_1.pdf" rel="nofollow">https:&#x2F;&#x2F;www.zoom-na.com&#x2F;sites&#x2F;default&#x2F;files&#x2F;products&#x2F;downloa...</a> that should have been named something like FOLDER01 through FOLDER10, so fixing that should make it valid again.<p>It&#x27;s hard to say what happened here without knowing the state of the filesystem before the Zoom started writing to it, but the fact that the creation date&#x2F;time of that nameless directory (2020-03-12 12:29) matches <i>exactly</i> with that of the first file it wrote (ZOOM0001.hprj&#x2F;ZOOM0001_LR.WAV) strongly suggests that the card did not already have a corrupted filesystem beforehand, and the Zoom somehow wrote a blank name directory where it should&#x27;ve written FOLDER01. A search for &quot;FOLDER&quot; in the image yields no results either, so it&#x27;s not like it wrote them somewhere else (unless it did so beyond the first 500MB of the card.)<p>I&#x27;ve seen embedded devices become confused and write corrupted filesystems a few times before, but they were far more egregious than this; e.g. ignoring&#x2F;assuming certain fields&#x27; values would result in filesystem structures being wholesale shifted by some offset, etc. This is an unusual case because nothing about the filesystem stood out as being &quot;obviously suspicious&#x2F;non-standard&quot;, and everything except for the name was fine --- hence why 7-zip could still operate on it; it didn&#x27;t care about the name.<p>The value of 1458 reserved sectors (729KB!) initially stood out, but upon further thought, that may simply be to align the first cluster with the eraseblocks of the flash, as if the Zoom really was to ignore it, the filesystem structures would&#x27;ve been far more mangled.
评论 #22594475 未加载
评论 #22593809 未加载
mercora大约 5 年前
its a really nice read but i am somewhat sad they neither know what actually happened nor why it happened at all. I hope this gets some attention from someone here that is skilled enough with this kind of things and willing to figure this out as it kinda bugs me now...
Neil44大约 5 年前
Why not try a ready rolled file recovery utility first? Why grind out this reinventing of the wheel?
评论 #22592193 未加载
heywire大约 5 年前
Great read! I agree, 7-zip is amazing. You can open all kinds of files for exploration using it.
lostmsu大约 5 年前
He did not try chkdsk, the default tool to fix file systems on Windows?
rdp36大约 5 年前
lesson: use linux end to end (unless you work for Microsoft). :)
评论 #22590560 未加载
评论 #22590041 未加载