Linking two files together

Patrick O'Callaghan pocallaghan at gmail.com
Wed May 26 17:28:42 UTC 2010


On Wed, 2010-05-26 at 10:16 -0700, Rector, David wrote:
> It seems to me that it should be possible to simply modify the file
> entry in the filesystem such that the last inode of the first file
> points to the first inode of the second file. I guess this is similar
> to a "hard link", but used to join files rather than simply have
> another pointer to one file.

A file has one and only one inode, so that's not feasible. However the
idea of "editing" the inode contents (and the inode's blocklist or
bitmap) to make this work could be done in principle. In practice it
looks really hairy, and highly dependant on specific implementation
details of each type of filesystem. I've never heard of this being done,
but who knows?

Why do you need this? If it's for some special data-processing
application, would it not be easier to modify the app so it could
process a sequence of files?

poc



More information about the users mailing list