Handling/Copying NTFS "Sparse Files"

Q & A for the old 2X Explorer file manager. For other topics, please use the corresponding forum.

Moderators: fgagnon, nikos, Site Mods

Post Reply
webservices
New Member
Posts: 2
Joined: 2005 Feb 27, 16:01

Handling/Copying NTFS "Sparse Files"

Post by webservices »

After using 2xExplorer (Product Build: 1.4.1.12) for a long time now, never ever had anything to moan about it, now I run into a thing I just want to notify down:

NTFS itself has a kind of "feature" named "sparse files" basically meaning only to allocate meanigful data inside  a file, therefore keeping redundant data from allocating useful storage of a file system.

When  copying those files using 2xExplorer, it seems NOT to keep those special file attribute, meaning e.g. a [b]sparse file[/b] with size of 1GB allocating 64kB (which probably is a file with only "null" data inside) will expand to allocating 1GB of file system storage after copy.
Windows 2000/XP will keep this sparse file attribute, speeding up copy and also keeping the file itself "original".

I wonder, wether X2Explorer will handle this "uncommon" file attribute or wether this is the first time, someone has noticed this behaviour ?

Kind regards,
Chris
User avatar
nikos
Site Admin
Site Admin
Posts: 15794
Joined: 2002 Feb 07, 15:57
Location: UK
Contact:

Post by nikos »

2xExplorer (and the new xplorer2) when you drag-drop use the standard windows copy routines. I can't say that i've experimented or used sparse files (i am aware of them of course) but I'd find the prospect of copy-"unsparsing" them weird to say the least -- e.g. what data will there be for the yet unallocated sections?

if i were you i'd try a simple experiment copying a small sparse file from NTFS->NTFS using drag-drop:

* with explorer
* with 2x
* with x2

and try to understand the results


why would you want to copy a sparse file in the first place?
webservices
New Member
Posts: 2
Joined: 2005 Feb 27, 16:01

Post by webservices »

Nikos,
you are right.
Sparse files are a kind of thing, we may or may not need them anyhow.
But as they do exist, I would not like to mangle with them.

I need to copy sparse files for the simple reason, that disc space exceeded by filling the sparse file with real data.
As there are many of those files, I need to "move" them to another file system (partition) without expanding the ones, which are simple "files" to be filled with data in future.

Microsoft claims "sparse data" to be repetitive data 8bit data with 00h, as far as I understand.

So the way "drag-and-drop" copying is handled is different to using "F5" and "Copy/Paste" copying inside 2x/X2 ?

I will go for this, as normally I use keyboard copy (F5) only.
Kind regards,
Chris
User avatar
nikos
Site Admin
Site Admin
Posts: 15794
Joined: 2002 Feb 07, 15:57
Location: UK
Contact:

Post by nikos »

in x2, F5 and drag drop definitely use different mechanisms, and the drag-drop is more explorer-friendly
Post Reply