Register to reply

Increasing File Size

by anahata
Tags: file size, file system
Share this thread:
anahata
#1
Jan19-10, 02:54 PM
P: 2
Anyone know how to increase the size of a file, without actually increasing the space occupied on disk. I knew a guy who did this.
Phys.Org News Partner Science news on Phys.org
Scientists develop 'electronic nose' for rapid detection of C. diff infection
Why plants in the office make us more productive
Tesla Motors dealing as states play factory poker
DaveC426913
#2
Jan19-10, 02:59 PM
DaveC426913's Avatar
P: 15,319
Quote Quote by anahata View Post
Anyone know how to increase the size of a file, without actually increasing the space occupied on disk. I knew a guy who did this.
Compression?

If you started with a 100K file, you could compress it (say, using zip) to, say, 1/10th its uncompressed size. This means you could increase the original file to 1M, then compress it so that it still took up only 100K on disk.
anahata
#3
Jan19-10, 03:06 PM
P: 2
What it comes to be like this,
say the file size is 200kb, he somehow made the file size attribute ,say 2MB without changing the space on disk, ie, it still costs just 200kb disk space, but for all other purposes it acts like a 2MB file.
For example, wen uploading the file etc, it the properties will be displayed as 2MB.

story645
#4
Jan19-10, 04:59 PM
P: 670
Increasing File Size

Quote Quote by anahata View Post
say the file size is 200kb, he somehow made the file size attribute ,say 2MB
Um, are you sure it wasn't a 2000kb file (which is a 2MB file?)

Google says the answer is to either create sparse files or do a compression trick.
dE_logics
#5
Jan20-10, 08:28 AM
P: 735
Quote Quote by anahata View Post
What it comes to be like this,
say the file size is 200kb, he somehow made the file size attribute ,say 2MB without changing the space on disk, ie, it still costs just 200kb disk space, but for all other purposes it acts like a 2MB file.
For example, wen uploading the file etc, it the properties will be displayed as 2MB.
It happens in NTFS file system (not sure if this feature is available a Linux file system...need to check that out). It has a feature to compress the files in real time demoting it's already demoted performance in some systems.

Cause of this the "size of file" and "size of file on disk" are different.

But your friend did something opposite. I think this might be possible by tampering the default MFT.
Borek
#6
Jan20-10, 09:09 AM
Admin
Borek's Avatar
P: 23,594
No idea about NTFS, but on FAT each file is described by an entry in directory table - one of the fields there is the file size. Modify just these four bytes and file will be reported as larger (or smaller) then it is in reality. It can't be done on the OS level, but any disk editing software able to deal with the disk on the sector level will do.


Register to reply

Related Discussions
Increasing the spot size General Physics 6
Increasing Row Size... Precalculus Mathematics Homework 2
What's the fastest way to increase file size? Programming & Computer Science 11
File Size Q... Forum Feedback & Announcements 12