From: Oystein Viggen <oysteivi@tihlde.org>
To: linux-btrfs@vger.kernel.org
Subject: Re: btrfs: unlinked 34 orphans
Date: Tue, 09 Nov 2010 09:36:23 +0100 [thread overview]
Message-ID: <03iq063nco.fsf@msgid.viggen.net> (raw)
In-Reply-To: 4CD8DB2E.1090600@prnet.org
* [David Arendt]=20
> I received the message: btrfs: unlinked 34 orphans
>
> Just out of couriosity: what does it mean ?
Ooh, ooh! I think I know this one :)
When a file is unlinked/deleted while an application has it open, it is
kept around allocated on disk so that the app has access to the data in
the file. When the file is closed or the app exits, it is deallocated
(disk space is freed). This is a quite normal way of handling temporar=
y
files.
Now, if there is an unclean shutdown while a file is in this "deleted,
but not freed" state, you get an orphaned file or inode -- that is,
allocated data with no directory entry pointing to it. When btrfs
unlinks these orphans during mount, it's just completing what would hav=
e
happened once the unlinked files were closed. If this happened after a=
n
unclean shutdown (crash or power loss), the message is just btrfs
bragging about working properly.
None of this is actually specific to btrfs. I believe posix filesystem=
s
are more or less required (or at least expected) to behave like this.
(interestingly, Microsoft Windows has a different take on this issue by
simply not letting you delete open files).
=D8ystein
--=20
This message was generated by a horde of attack elephants armed with PR=
NGs.
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" =
in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
prev parent reply other threads:[~2010-11-09 8:36 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-09 5:25 btrfs: unlinked 34 orphans David Arendt
2010-11-09 8:36 ` Oystein Viggen [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=03iq063nco.fsf@msgid.viggen.net \
--to=oysteivi@tihlde.org \
--cc=linux-btrfs@vger.kernel.org \
/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.