Disable .zfs directory on 32-bit systems
authorBrian Behlendorf <behlendorf1@llnl.gov>
Thu, 19 Jul 2012 21:50:25 +0000 (14:50 -0700)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Fri, 20 Jul 2012 19:20:57 +0000 (12:20 -0700)
commitfc173c85892841c283aac4e5174d6d8762463062
treee6ebd29eb87d4b03804b8e8a1398ed3c4c1ceaa4
parent2a4a9dc2f09d7672268af4a4f70e1a26b481b5e9
Disable .zfs directory on 32-bit systems

The .zfs control directory implementation currently relies on
the fact that there is a direct 1:1 mapping from an object id
to its inode number.  This works well as long as the system
uses a 64-bit value to store the inode number.

Unfortunately, the Linux kernel defines the inode number as
an 'unsigned long' type.  This means that for 32-bit systems
will only have 32-bit inode numbers but we still have 64-bit
object ids.

This problem is particularly acute for the .zfs directories
which leverage those upper 32-bits.  This is done to avoid
conflicting with object ids which are allocated monotonically
starting from 0.  This is likely to also be a problem for
datasets on 32-bit systems with more than ~2 billion files.

The right long term fix must remove the simple 1:1 mapping.
Until that's done the only safe thing to do is to disable the
.zfs directory on 32-bit systems.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
module/zfs/zfs_ctldir.c