From: Toshiyuki Okajima <toshi.okajima@jp.fujitsu.com>
To: Zhang Xiliang <zhangxiliang@cn.fujitsu.com>
Cc: linux-ext4@vger.kernel.org
Subject: Re: Problems with the max value for create directory
Date: Tue, 23 Dec 2008 13:02:25 +0900 [thread overview]
Message-ID: <495062D1.6010805@jp.fujitsu.com> (raw)
In-Reply-To: <495054DE.9030405@cn.fujitsu.com>
Hi,
Zhang Xiliang wrote:
> Hi,
>
> I creat 65537 long directories and failed when the block size is 1024.
>
> # mkfs.ext4dev -b 1024 -I 256 /dev/hda3
> # tune2fs -E test_fs -O extents /dev/hda3
> # mount -t ext4dev /dev/hda3 /mnt
> # ./create_long_dirs 65537 /mnt
>
> The code of create_long_dirs.c:
ext4 filesystem cannot make over 65000 links toward a file.
(ext3 filesystem cannot make over 32000 links toward a file.)
This test makes over 65000 links toward /mnt-directory.
(Creating 65000 sub-directories makes 65000 links toward /mnt-directory.)
static int ext4_mkdir(struct inode *dir, struct dentry *dentry, int mode)
{
handle_t *handle;
struct inode *inode;
struct buffer_head *dir_block;
struct ext4_dir_entry_2 *de;
int err, retries = 0;
if (EXT4_DIR_LINK_MAX(dir))
^^^^^^^^^^^^^^^^^^^^^^^^^^^
return -EMLINK;
This limit is ext4's specification.
Regards,
Toshiyuki Okajima
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2008-12-23 4:02 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-23 3:02 Problems with the max value for create directory Zhang Xiliang
2008-12-23 4:02 ` Toshiyuki Okajima [this message]
2008-12-23 7:49 ` Andreas Dilger
2008-12-23 20:12 ` Theodore Tso
2008-12-24 1:18 ` Zhang Xiliang
2008-12-24 23:54 ` Theodore Tso
2008-12-29 13:47 ` Peng tao
2009-01-06 3:16 ` Andreas Dilger
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=495062D1.6010805@jp.fujitsu.com \
--to=toshi.okajima@jp.fujitsu.com \
--cc=linux-ext4@vger.kernel.org \
--cc=zhangxiliang@cn.fujitsu.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.