What is a holey file?

Posted on 1997-10-12
Last Modified: 2011-09-20
What is it? Why do they exist? Why I can't handle them as other files?
Question by:jlms
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2

Expert Comment

ID: 2007394
"holey" file ? are you sure you got that right ?


Author Comment

ID: 2007395
I think so...

Expert Comment

ID: 2007396
Where did you get that info ? what OS ? ....
What Is Transaction Monitoring and who needs it?

Synthetic Transaction Monitoring that you need for the day to day, which ensures your business website keeps running optimally, and that there is no downtime to impact your customer experience.


Accepted Solution

rembo earned 50 total points
ID: 2007397

When you talk about holey files, I'm assuming
that you're talking about files which were
creating with empty checks via lseek.  

These are stored in the filesystem using
only header info, not real disk blocks.  However,
if you try to put this on to a tape, especially
with dd or something like that, it will try to
write the actual blocks.  

For example, you could lseek forward 2GB in a file
and then write 1 character.  Your file size is then
huge, but it actually only takes up one disk block
(this is in UFS, not any old SVR4 system).  However,
older filesystems can figure this out.

Anyway, the deal is you need to be careful with things
that might try to map these headers to real data.

So, the deal is, try not to create holey files :)
but if you do, just know what you're doing with
them and how you move them.  Try to use tar and
modern, ufs or vxfs filesystems.  

If there's a specific application you're wondering
about, let me know.  I'd be happy to help.



Author Comment

ID: 2007398
I think I understand, and no, I don't have any application in particular in mind.

One last thing, how can I recognize one of this files?

Author Comment

ID: 2007399
I think I understand, and no, I don't have any application in particular in mind.

One last thing, how can I recognize one of this files?

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Installing FreeBSD… FreeBSD is a darling of an operating system. The stability and usability make it a clear choice for servers and desktops (for the cunning). Savvy?  The Ports collection makes available every popular FOSS application and packag…
I have been running these systems for a few years now and I am just very happy with them.   I just wanted to share the manual that I have created for upgrades and other things.  Oooh yes! FreeBSD makes me happy (as a server), no maintenance and I al…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question