A sparse file is a file where only the non-zero data are stored in data blocks and all zero-data are generated by the filesystem when the file is read. As such, the sparse file uses disk space efficiently by storing only metadata about the zeros, rather than storing the zeros physically on storage. When the sparse file is later read, the filesystem generates the zeros dynamically.
Questions tagged [sparse-file]
62 questions
0
votes
0 answers
Easiest way to programmatically copy a sparse file?
I'm trying to copy a sparse file in C++. Unfortunately, std::experimental::copy_file ignores the sparsity (at least in GCC 7.5.0) and turns my 16M file into a 52G copy.
What's the easiest way to copy a sparse file while preserving the sparsity?

Thomas Johnson
- 10,776
- 18
- 60
- 98
0
votes
1 answer
Is there any other sparse matrix data in matlab built-in file?
I want to do some numerical examples solving large sparse linear system Ax=b. And I want to use some data from Maltab itself because this experiments are easily reproduced any time using Matlab. For example,
load west0479.mat
A = west0479;
b =…

Happy
- 129
- 4
0
votes
1 answer
Why dd can't handle sparse files in shell scripts?
I have the following sparse file that I want to flash to an SD card:
647M -rw------- 1 root root 4.2G Sep 21 16:53 make_sd_card.sh.xNws4e
As you can see, it takes ~647M on disk for an apparent size of 4.2G.
If I flash it directly with dd,…

ncarrier
- 433
- 3
- 14
0
votes
0 answers
Why the physical size of folder containing the sparse file is not displaying correct size in Info
I have one folder "test" which contains only one sparse file. The logical size of file is 5.24 GB but physical size is zero bytes, which is correctly displayed in file properties, but the physical size of parent folder is not zero bytes. I want to…

Ankita Shrivastava
- 75
- 8
0
votes
0 answers
Sparse File Compression Zones vs Sparse Ranges
I am new to sparse files and wondering if compression zones and sparse ranges are the same thing.
I recently learned the term compression units from here:
http://www.flexhex.com/docs/articles/sparse-files.phtml
When it comes to a compressed or a…

GPGVM
- 5,515
- 10
- 56
- 97
0
votes
0 answers
azure vhd storage pool space usage
I have 4 1TB VHD disks attached to a single VM.
In the VM, I have created a simple fixed storage pool from the 4 = 4TB.
In disk manager I created a single 4TB volume/partition.
The volume is only 30% full.
VHD is sparse so I would expect the…

mosheb
- 686
- 6
- 12
0
votes
1 answer
Python hashlib and sparse files
I wanted to know how does python hashlib library treat sparse files. If the file has a lot of zero blocks then instead of wasting CPU and memory on reading zero blocks does it do any optimization like scanning the inode block map and reading only…

CodeWithPride
- 123
- 3
- 14
0
votes
1 answer
Vdbench 50404rc2 beta code - sparse file creation
Can anyone please let me know any pointers to create Sparse files(holey files) in latest vdbench 50404rc2. It seems that this is the latest supported feature.
Link for more info:
https://community.oracle.com/thread/3759500?start=0&tstart=0

SugaryRohit
- 64
- 5
0
votes
1 answer
What should be the extention of video to save to ParseFile on Parse
According to the docs ParseFile requires an extension so to know what type of content it is handling. In my case user captures a video with her mobile device, then from the Uri of the video, I get the byte[] and pass it to ParseFile. What should the…

learner
- 11,490
- 26
- 97
- 169
0
votes
0 answers
Reduce time for automating the installation and configuration of ubuntu vm
Could anyone please let me know how to reduce the time to create a vm with installation and configuration of around 1000 packages.
I am using shell scripts to automate and basic version of ubuntu server edition . Is there any techniques to increase…

Sasikiran Vaddi
- 2,199
- 4
- 23
- 29
0
votes
1 answer
C - Linux: list sparse files and print 0-filled disk blocks
I am trying to implement the following task for hours now. But it is still not working and I don't really know any further.
The Task:
A c program which list all sparse files in the current directory if you pass the parameter -s in the command line…
user2965601
0
votes
1 answer
Finding length of data block in sparse file
How can I find length of non-zero data block in sparse file starting from some offset?
Do I have to make some file read or OS can read that information from some metadata which can be cached?
I'm using Windows OS and Visual Studio C++.

Marka
- 377
- 1
- 4
- 17
-1
votes
1 answer
Running BLAST in Python with Biopython for SARS Virus. My output is simply not showing up! Someone check my code?
Here is my code:
from Bio.Blast import NCBIWWW
result = NCBIWWW.qblast("blastn","nt",r"C:\Users\video\Documents\sars.fasta")
save_file = open("blast4.xml", "w")
save_file.write(result.read())
save_file.close()
result.close()
result =…

Johnn-1231
- 85
- 1
- 1
- 5
-1
votes
2 answers
Machine learning algorithm for few samples and features
I am intended to do a yes/no classifier. The problem is that the data does not come from me, so I have to work with what I have been given. I have around 150 samples, each sample contains 3 features, these features are continuous numeric variables.…

Kailegh
- 199
- 1
- 13
-1
votes
1 answer
How can I use "cp --sparse=always" in Mac?
I just follow this page to build custom oracle linux machine image.
I want to use cp cp --sparse=always like Converting the VM Disk to a Machine Image of that page in my Mac. But, my Mac cannot recognize this option. How can I follow this step in my…

Binary_tree
- 23
- 4