Magic at ROUGOL and SASAUG
Pages: 1 2
David R. Lane (77) 766 posts |
Before a packed audience in a room at The Blue Eyed Maid, near London Bridge, at a meeting last night of RISC OS User Group Of London, I demonstrated “Now You See Them Now You Don’t” with a USB stick. Inserting the stick in an ordinary Raspberry-Pi, provided by a member of the audience, and mounting it with the SCSI filing system 15 objects were seen (5 directories and 10 files); but, next, mounting it with the FAT32 filing system only 10 of these 15 objects were seen (scroll bars fully extended). The audience were aghast and even ROUGOL’s most knowledgeable experts present (Keith Dunlop was absent) could not explain the phenomenon. A week earlier I had demonstrated the same ‘trick’ at a meeting of the Surrey And Sussex Acorn User Group with the same results, completely baffling the members present including several respected experts in the field. For the sceptics, I point out that the beer was off at the Blue Eyed Maid and SASAUG meet in a church hall and so all were sober at both meetings. |
Rick Murray (539) 13840 posts |
How “big” is the USB stick? Does it (and did it) contain any private info? I ask because those who develop such things might appreciate an image to see if they can replicate the issue. For instance, have you ever run doschk against the drive? Are both copies of the FAT identical and complete? Were the missing files created/opened/last modified in a way different to the others? To give an example of my own, I have some files on a FAT stick using FAT32FS. They have long file names, appear on RISC OS as such. Insert the thing into a Windows box, it shows me stuff like LONGFI~1.ext and MYFILE~1.ext – yet it appears as it should under RISC OS… Hmmm… |
Colin (478) 2433 posts |
Does anyone not have problems with fat formatted memory sticks/memory cards? |
Rick Murray (539) 13840 posts |
Given that XP’s GUI disc scanner can’t find its backside with both hands and a big pointy arrow, and given that half the time one of the DLLs underlying In other words – are you sure that’s a question you want to ask? ;-) On the other hand, by Xperia U phone only supports MTP file transfer, it cannot be a USB mass storage device. Because of this the internal format is possibly not FAT-anything. ext2? ext3? At any rate, I tend to find my storage depletes rather rapidly, and the LOST.DIR folder fills up with large files that appear to be random fragments. Nothing appears broken or corrupted, but it is a worry that a closed-loop filesystem completely free from outside interference is incapable of keeping itself in good order! 1 Small-sectored devices or overly large devices fail, the PVR only has 64Mb inside (30Mb for Linux and 34Mb for the DSP codecs (invisible to Linux)) and no swap, so it runs out of memory…but then it was designed to record video, not deal with Microsoft’s losingness. |
David R. Lane (77) 766 posts |
It’s a 1GB USB stick, but I can repeat the phenomenon with a 256MB USB stick. It does have some private information on it, but the filenames shown in an image wouldn’t give away anything to matter. I don’t know how to include images in a post to this forum, but, as I said above the experiment was witnessed by a large crowd at ROUGOL and a substantial gathering at SASAUG. If you are interested in the characters in the filenames as one spectator was, they are alphanumeric plus some underscores, spaces, hyphens, forward slashes, round brackets and + signs. Nobody at the demonstration thought these had any bearing on which files disappeared. For example, of the two objects that had a space in their filenames one disappeared and the other did not. |
Steve Pampling (1551) 8170 posts |
File Allocation Table |
Jeff Doggett (257) 234 posts |
Neither does Fat32fs!
I’m assuming that these files are in the root directory, so the FAT shouldn’t be an issue. Also if it’s reproduceable on a 256MB stick then that’ll be FAT16 which (iirc) has a fixed size root directory. Only FAT32 can have a root directory that is based on the FAT and hence can be extended. If you’re using FAT32fs then you can use the mount -v option to dump the sectors. If you do it after viewing the ‘missing’ files (ie use mount -v after it’s already mounted) then it should show the whole of the root directory. The first mount will only show as much of the root directory that FAT32fs needed to read to find the volume name. |
Chris Evans (457) 1614 posts |
The standard way round the problem is to only ever write to a FAT format device from either Windows or RISC OS. You should then be able to read from either OS. So one pen for writing with RISC OS and another Pen for Writing with Windows. |
David R. Lane (77) 766 posts |
Below is a screen dumpout (reduced) showing the two filer windows. The original larger, version is here. |
Bryan Hogan (339) 592 posts |
I think that when you Select click on the USB stick it is being opened by DOSFS and when you Adjust click it is opened by Fat32FS, and they are using different copies of the FAT. What happens if you RMKill DOSFS before inserting the stick? In fact, is there any reason to ever use DOSFS rather than Fat32FS? |
Martin Bazley (331) 379 posts |
While I don’t know how that screenshot was produced, its point is clearly that the two Filer windows are showing different contents.
Demonstrably. |
Chris Johnson (125) 825 posts |
The files which go AWOL under Fat32Fs are all typed as DOS. Is there a clue there? |
Bryan Hogan (339) 592 posts |
Forgot to say, I examined Dave’s USB stick under Linux and there is only a single FAT partition on there. I couldn’t persuade dosfsck to give me any more useful info :-( |
Michael Emerton (483) 136 posts |
I have found this many times It’s not just RISC OS. I have Windows Xp and 7, both view the same USB stick differently (32 GiB). More often than not, RISC OS is the one which shows the stick ‘correctly’ (all files I expect to see there). Watch out, files can be over-written! (Obviously) Eject your media people :@) always resolves it here! |
David R. Lane (77) 766 posts |
@Chris Evans @Chris Johnson
I have another USB stick, a 256MB one, for which some of the files typed DOS don’t disappear. Try again! :-) |
Ronald May (387) 407 posts |
I have ported disktype and added a function to return Filecore information in the case of a RISC OS drive. http://homepages.woosh.co.nz/ron.may/disktype.zip It is only an info display program, but might be helpful. |
William Harden (2174) 244 posts |
Is it that one obeys hidden files on FAT and one doesn’t? If that’s true – if something corrupts the flag of the file so that they become ‘hidden’ one filesystem would ‘see’ them and one would ‘not’. |
David R. Lane (77) 766 posts |
@Ronald May @Jeff Doggett |
Ronald May (387) 407 posts |
@David |
Jeff Doggett (257) 234 posts |
Fat32fs ignores the “hidden” flag.
You can send them to me if you wish. I’m expecting to see a NULL byte corrupting the root directory. Fat32fs obeys the FAT spec and stops searching the directory when it encounters a null byte as the first character of the filename. |
David R. Lane (77) 766 posts |
@Bryan Hogan
Answer: Get errrors when attempting to mount stick with SCSI FS, “Disc not understood – has it been formatted?” To be expected, surely? @Jeff Doggett |
Jeff Doggett (257) 234 posts |
I have it.
This shows that the longfilename is “pandaboot.zip”, but there is no short (8.3) format present, just junk bytes (20 00 1B 1F 06 00 1B 0F 2F 00 00), so FAT32fs has ignored that entry. |
Jeff Doggett (257) 234 posts |
Fat32fs has been updated to 1.44 |
WPB (1391) 352 posts |
Well done, Jeff. And a nice number for a filing system software to reach, if you remember floppies. ;) |
David R. Lane (77) 766 posts |
@Ronald May *disktype SCSI::0 SCSI::0 Regular file, size 0.988 GiB (1060356096 bytes) |
Pages: 1 2