All of lore.kernel.org
 help / color / mirror / Atom feed
From: Edward Shishkin <edward.shishkin@gmail.com>
To: Sascha Lucas <sascha_lucas@web.de>
Cc: reiserfs-devel@vger.kernel.org
Subject: Re: files as directorys
Date: Fri, 15 Aug 2008 01:18:37 +0400	[thread overview]
Message-ID: <48A4A12D.5030704@gmail.com> (raw)
In-Reply-To: <200808141747.48141.sascha_lucas@web.de>

Sascha Lucas wrote:
> Hi list,
>
> I like to try the "files as directorys" plugin.

It is not a plugin ;)
It is a set of concepts with similar semantics.

One of them is so-called "pseudo-files" (or "metas"), a reiser4
extension that allows to access attributes of any regular file
foo via the following construction : foo/..../bar (and, yes,
chdir to foo/.... is possible).
Unfortunately, this is deprecated because it allows to create
incorrect constructions using hard links functionality. AFAIK,
the problem is not yet resolved.

There is a patch for pseudo-files extension against ~2.6.14

>  Please tell me first if I 
> understand it right, what this can do:
>
> An often made example is /etc/passwd. If used with the "files as directorys"

This is another concept which allows to aggregate various
records in a handy manner as "subfiles" of a regular file.
I even know that Hans discussed with R.M. Stallman, which
found this possibility useful. Linus also likes this idea. There
is a special technical thread in lkml devoted to this functionality
opened by Al Viro:
http://readlist.com/lists/vger.kernel.org/linux-kernel/7/39039.html

> plugin then passwd is a directory and a file at the same time. You can chdir 
> into passwd and have i.e. each line in a separate file. Legacy apps can still 
> open passwd like a file as "normal"/before.
>   

Yes, but this concept has not been worked out in details.
I remember there were two approaches for the implementation:

1) as a directory, so that every record has a directory entry nature;
2) as a "symfile", so that every record has a symlink nature.

> And now the question, why I can't verify this myself:
>
> $ /sbin/mkfs.reiser4 -o create=dir40 reiser4.img
> /sbin/mkfs.reiser4 1.0.6
> Copyright (C) 2001-2005 by Hans Reiser, licensing governed by 
> reiser4progs/COPYING.
>
> Overriding the plugin profile by "create=dir40".
> Error: Can't override profile slot "create" by the found plugin "dir40": a 
> plugin of the same type but of another group is found.
>
> Any hints for me what I'm doing wrong?

"create" is a directory attribute (actually regular files also have it,
but it makes sense for directory only). So this attribute specifies a
plugin to manage _regular_ files created in the directory (the name
"create" was chosen in conformity with the system call creat (2)).

dir40 is a plugin, which manages directories, not a regular files.
This explains mkfs complaints.

Currently there are two plugins to manage regular files in reiser4:
1) unix-file plugin (reg40, default value)
2) cryptcompress plugin  (ccreg40) .

Edward.

>  Distro is gentoo with: 
>  - gentoo-sources-2.6.25 and reiser4-patch from kernel.org/edward
>  - reiser4progs-1.0.6-r1 from gentoo-portage
>
> TIA Sascha.
> --
> To unsubscribe from this list: send the line "unsubscribe reiserfs-devel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
>   


      reply	other threads:[~2008-08-14 21:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-14 15:47 files as directorys Sascha Lucas
2008-08-14 21:18 ` Edward Shishkin [this message]

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=48A4A12D.5030704@gmail.com \
    --to=edward.shishkin@gmail.com \
    --cc=reiserfs-devel@vger.kernel.org \
    --cc=sascha_lucas@web.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.