From: "H. Peter Anvin" <hpa@zytor.com>
To: linux-kernel@vger.kernel.org
Subject: Re: isofs hardlink bug (inode numbers different)
Date: 3 Feb 2003 19:48:06 -0800 [thread overview]
Message-ID: <b1nd5m$rhp$1@cesium.transmeta.com> (raw)
In-Reply-To: 20030126235556.GA5560@paradise.net.nz
Followup to: <20030126235556.GA5560@paradise.net.nz>
By author: Volker Kuhlmann <list0570@paradise.net.nz>
In newsgroup: linux.dev.kernel
>
> I am trying to back up directory trees on CD, preserving hard links.
> newer versions of mkisofs are supposedly able to do this, but although
> the data is written to the isofs only once, the resulting directory
> entries have differing inode numbers thus making restore operations
> impossible.
>
> When I sent a bug report to the author of mkisofs, Jörg Schilling, I
> got the reply
>
> >>mkisofs 2.01a01 (i686-pc-linux-gnu)
> >>mkisofs 2.0 (i686-pc-linux-gnu)
> >>mkisofs 1.15a27 (i686-suse-linux)
> >
> >>Google shows no reference to anything which tells me that this is not
> >>supposed to work, therefore I assume it's a bug.
> >
> >Nachdenken hilft wie in vielen Fällen auch hier:
> >
> >Der Bug auch hier ist da, wo es wegen schlechter SW Qualität wahrscheinlicher
> >ist: Im Linux Kernel.
>
> (Translation: thinking helps here too, like in many other cases: the bug
> is in the linux kernel, where it is more likely to be due to lower
> software quality.)
[FWIW, Jörg is well-known for thinking that anything that isn't
Solaris is complete crap. He's entitled to his opinions.]
> Insults aside, is it true that the kernel's isofs can't produce correct
> inode numbers for hardlinked files? If that is the case it would
> somewhat reduce the usefulness of isofs for backups.
It's sort of true.
There are inode numbers stored in RockRidge attributes, but using them
comes with some humongous caveats:
First: You have absolutely no guarantee that they are actually
unique. Broken software could easily have written them with all
zeroes.
Second: If there are files on the CD-ROM *without* RockRidge
attributes, you can get collisions with the synthesized inode numbers
for non-RR files.
Third: If you actually rely on inode numbers to be able to find your
files, like most versions of Unix including old (but not current)
versions of Linux, then they are completely meaningless.
The basic problem is that the RR attributes are arbitrary numbers,
instead of any kind of pointer saying "I'm a hard link to this other
file over here."
There is another way to generate consistent inodes for hard links,
which is to use the data block pointer as the "inode number." This,
however, has the problem that *ALL* zero-lenght files become "hard
links" to each other.
I have been trying to come up with a solution to this, and have pretty
much failed. Hopefully the UDF filesystem doesn't have this
problem...
-hpa
--
<hpa@transmeta.com> at work, <hpa@zytor.com> in private!
"Unix gives you enough rope to shoot yourself in the foot."
Architectures needed: cris ia64 m68k mips64 ppc ppc64 s390 s390x sh v850 x86-64
next prev parent reply other threads:[~2003-02-04 3:38 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-01-26 23:55 isofs hardlink bug (inode numbers different) Volker Kuhlmann
2003-02-04 3:48 ` H. Peter Anvin [this message]
2003-02-04 21:28 ` Frank van Maarseveen
2003-02-04 21:52 ` H. Peter Anvin
2003-02-05 11:30 ` Kasper Dupont
2003-02-05 19:41 ` H. Peter Anvin
-- strict thread matches above, loose matches on Subject: below --
2003-02-10 21:16 James Pearson
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='b1nd5m$rhp$1@cesium.transmeta.com' \
--to=hpa@zytor.com \
--cc=linux-kernel@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox