From: Jeff Shanab <jshanab@earthlink.net>
To: Rik van Riel <riel@redhat.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: Starting a grad project that may change kernel VFS. Early research Re: Starting a grad project that may change kernel VFS. Early research
Date: Tue, 25 Aug 2009 11:04:55 -0700 [thread overview]
Message-ID: <4A9427C7.8020009@earthlink.net> (raw)
In-Reply-To: <4A941F56.8060502@redhat.com>
Rik van Riel wrote:
> Jeff Shanab wrote:
>
>> Updates start at the file and only work upwards back to root. How does
>> the hardlink get traversed?
>
> A hard link is just a second directory entry linking to
> the same inode. There are no back links from inodes to
> the directory entries that point to them and they are
> essentially indistinguishable from files that are not
> hardlinked.
>
> Hard links have been done like this in pretty much every
> Unix filesystem since the 1970's.
>
Right :-( I need a workaround but I am not sure how the sementics should be.
In my example where we have a directory structure like so, where file is
the same.
test/foo/bar/file
test/bar/foo/file
My example would result in the size showing up in each directory at the
bar/file and foo/file level
Then the two numbers are passed up to test and the test directory size
would be wrong.
There is no real way to handle this becasue the two files look the same
to the filesystem.
I can even remove the initial file without effecting the other. Is there
a refcount I can take advantage of in the inode?
Even then, I can't decide what the semantic is.
For example I could add a pie chart that changed with navigation into my
gui file manager. This system would make that practical.
How would I display this information usefully to the user. I suppose if
they navigate into either subdir they see the file size, but somehow
when they navigate up to the directory that holds subdirs that
indirectly contain both of them, only 1 can be counted. The problem is
that the top level directory will not be able to see the inodes of the
individual files, it is lost in the aggregate.
Still thinking....
next prev parent reply other threads:[~2009-08-25 18:04 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-08-25 1:46 Starting a grad project that may change kernel VFS. Early research Re: Starting a grad project that may change kernel VFS. Early research Jeff Shanab
2009-08-25 17:28 ` Rik van Riel
2009-08-25 18:04 ` Jeff Shanab [this message]
2009-08-26 1:30 ` Theodore Tso
[not found] ` <4A94BF9E.2010101@earthlink.net>
[not found] ` <20090826130513.GM32712@mit.edu>
2009-08-26 14:42 ` Jeff Shanab
2009-08-26 15:09 ` Bryan Donlan
2009-08-26 12:18 ` Stefan Richter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4A9427C7.8020009@earthlink.net \
--to=jshanab@earthlink.net \
--cc=linux-kernel@vger.kernel.org \
--cc=riel@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox