Re: Linking two files together

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thank you all for your quick replies,

Yes, it seems like a difficult thing to modify at the filesystem level.
Especially due to the earlier comment that the last block needs to 
be filled. I hadn't considered that.

Indeed, I have many apps that need to use these files, and it would
be difficult to modify them all to look at a sequence of files. I was
looking for an easier way.

Perhaps there is a utility or wrapper that could trick any regular app
into thinking that two files were actually one long file?

Like a multiple-file soft-link?

Dave Rector
*:^)



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


________________________________________
From: Rector, David
Sent: Wednesday, May 26, 2010 10:16 AM
To: users@xxxxxxxxxxxxxxxxxxxxxxx
Subject: Linking two files together

Hello,

I have studied various filesystems, and am fairly familiar with how they are structured. However, I am currently stuck on trying to do what seems like a simple thing.

I would like to join two files together without having to physically copy bytes (i.e. I have vary large files, so I don't want to use 'cat'). 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.

I have seen 'mmv' and 'lxsplit' and they all seem to do the same thing, namely they want to physically copy the bytes in order to join two files together.

Is there any such utility in linux to perform such a hard link to join or connect two files together without having to copy bytes?

Thanks for your help.

Dave Rector
*:^)
-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines

[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux