All of lore.kernel.org
 help / color / mirror / Atom feed
From: Oleg Drokin <green@namesys.com>
To: Matt Stegman <matts@ksu.edu>
Cc: reiserfs-list@namesys.com, marvin@synapse.net
Subject: Re: bug report: attributes ( chattr +a ) not respected by reiserfs 3.6, but this isn't listed in man mkreiserfs
Date: Fri, 18 Jul 2003 20:06:54 +0400	[thread overview]
Message-ID: <20030718160654.GI2268@namesys.com> (raw)
In-Reply-To: <200307162129.h6GLTcR3027410@elijah.imse.ksu.edu>

Hello!

On Wed, Jul 16, 2003 at 04:29:38PM -0500, Matt Stegman wrote:

> I get the same behaviour, but it appears that *only* the append-only
> attribute is ignored. Other attributes are respected fine.  However,
> there are still some wierd things with reiserfs and attributes.  This is
> a pretty long email detailing what I found.

Thanks a lot for a lot of details.

> # mkreiserfs /dev/hdc1
> <-------------mkreiserfs, 2003------------->
> reiserfsprogs 3.6.8
> mkreiserfs: Guessing about desired format.. 
> mkreiserfs: Kernel 2.4.20-xfs-r3 is running.
> Format 3.6 with standard journal
> ...<snip>...
> # mount -t reiserfs -o attrs /dev/hdc1 /mnt/reiser
> # cd /mnt/reiser
> # echo hello > file
> -bash: file: Permission denied
> Huh?  I'm root, this is a new filesystem, why would permission be
> denied?  Wait a minute...
> # lsattr -d /mnt/reiser
> suS-iadAcjIt- /mnt/reiser

Yes, this is a problem in mkreiserfs.
Surprisingly 2.6.4 works ok.
This of course will be fixed.

> # chattr +i file
> # echo line2 > file
> -bash: file: Permission denied
> Append only (a) is not respected.
> 
> # chattr -i +a file
> # lsattr file
> s-S--adAc--t- file
> # echo test > file
> # ls -l file
> -rw-r--r--    1 root     root            5 Jul 16 16:09 file

Hm... Indeed. Sigh. 

>   a : file can only be opened in append mode
>       Ignored by reiserfs.

Yes, this is a bug.

>   d : tell "dump" to ignore this file
>       Does dump even work on reiserfs?

We use this for marking the file as not needing tail packing.

>   t : do not merge tails on this file
>       I don't know if this is supported or not.

Hm, my "chattr" documentation does not have this flag.

> Finally, 'reiserfsck --clean-attributes' will produce the following:
> # umount /mnt/reiser
> # reiserfsck --clean-attributes /dev/hdc1
> ...<snip>...
> # mount -t reiserfs -o attrs /dev/hdc1 /mnt/reiser
> # lsattr -d /mnt/reiser
> ------------- /mnt/reiser
> # lsattr /mnt/reiser/file
> ------------- /mnt/reiser/file

Yes, this is expected.
Older kernels, that are unaware of reiserfs attributes (pre 2.4.17 ones)
write various garbage in sd_attrs field in stat data. So this needs to be cleaned.
And we even invented a superblock flag to indicate that such a cleaning was performed already.
Now we also see that new mkreiserfs also writes garbage there.

Bye,
    Oleg

  reply	other threads:[~2003-07-18 16:06 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-07-12 14:10 bug report: attributes ( chattr +a ) not respected by reiserfs 3,6, but this isn't listed in man mkreiserfs D.A.M. Revok
2003-07-13 13:10 ` Oleg Drokin
2003-07-15 19:10   ` D.A.M. Revok
2003-07-16 10:30     ` Oleg Drokin
2003-07-16 14:57       ` bug report: attributes ( chattr +a ) not respected by reiserfs 3.6, " D.A.M. Revok
2003-07-16 21:29         ` Matt Stegman
2003-07-18 16:06           ` Oleg Drokin [this message]
2003-07-18 18:03             ` Matt Stegman

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=20030718160654.GI2268@namesys.com \
    --to=green@namesys.com \
    --cc=marvin@synapse.net \
    --cc=matts@ksu.edu \
    --cc=reiserfs-list@namesys.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 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.