怎样解决2T分区inode限制

yoky
怎样解决2T分区inode限制

solaris10  磁盘阵列   
如果分区为1T的话,用默认参数建立文件系统,
newfs  /dev/rdsk/c2t2d2s6
挂载分区:mount /dev/dsk/c2t2d2s6 /export/home3
查看inode数:df -F ufs -o i /export/home3,结果显示为
/dev/dsk/c2t2d2s6          4 127196156     0%   /export/home3

如果分区为2T,利用同样的默认参数建立文件系统,结果显示为
/dev/dsk/c2t2d2s6          4 2176828     0%   /export/home3
如果用newfs -i 16384 /dev/rdsk/c2t2d2s6
出来的结果还是那样,这就说明分区是2T的话,-i 后面的值非常大,怎么样才能提高2T分区的inode数呢?请教各位大虾了!

yoky
回复 #1 yoky 的帖子

这样有可能造成的结果就是如果我的文件数目非常大,而文件有非常小的话,2T分区可能只用几百G就报错说硬盘的inode已满,无法在往里面存入新的文件了。这样的话利用率还不如1T分区呢

solaris study
在大于1T的文件系统inode会少的可怜啊。这个好像没有办法提高。关注中、、、、 期待高人、、

yoky
是啊,郁闷中,难道就没有办法么?这样的话即使分了2T也没有意义了,Sun是怎么想的?

bencyber
[quote]原帖由 [i]yoky[/i] 于 2008-7-1 08:12 发表 [url=http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8707165&ptid=1184743][img]http://bbs.chinaunix.net/images/common/back.gif[/img][/url]
是啊,郁闷中,难道就没有办法么?这样的话即使分了2T也没有意义了,Sun是怎么想的? [/quote]
1、可以用zfs,
2、newfs 时加-T参数

whr25
估计你的系统有问题的,

yoky
1、应该不是系统的事情,系统是刚做好的。

2、newfs -T  我也查了一下,没看懂后面的参数是什么意思。
man newfs

     -T              Set the parameters of  the  file  system  to
                     allow  eventual growth to over a terabyte in
                     total file system  size.  This  option  sets
                     fragsize  to  be the same as bsize, and sets
                     nbpi to 1 Mbyte, unless  the  -i  option  is
                     used  to make it even larger. If you use the
                     -f or -i options to specify  a  fragsize  or
                     nbpi  that is incompatible with this option,
                     the user-supplied value of fragsize or  nbpi
                     is ignored.

whr25
从 Solaris 9 4/03开始Solaris支持大TB

我装过很多都是可以支持大于1TB的。

重新format试试看,


实在不行,,你就试试使用zfs来挂载硬盘

[[i] 本帖最后由 whr25 于 2008-7-1 15:38 编辑 [/i]]

fsclan_ren
# newfs -i (nbpi-old/2) /dev/rdsk/c#t#d#s#
将原来的inode大小变为一半不就行了,这样不就成为了双倍

solaris study
我在hds的阵列上试过。如果大于1T无论你怎么修改(nbpi-old/2) 这个参数都没有办法改变inode的数量

yoky
在ufs下面,我已经试过了,不管newfs -i 16084,还是 -i 32168  ,都没变化

bencyber
[quote]原帖由 [i]solaris study[/i] 于 2008-7-2 10:06 发表 [url=http://bbs.chinaunix.net/redirect.php?goto=findpost&pid=8716241&ptid=1184743][img]http://bbs.chinaunix.net/images/common/back.gif[/img][/url]
我在hds的阵列上试过。如果大于1T无论你怎么修改(nbpi-old/2) 这个参数都没有办法改变inode的数量 [/quote]
I-node的数量是有限制的,并不是无限大的,我猜主要与出错时的修复相关。

[url]http://www.sun.com/bigadmin/features/articles/solaris_express.html[/url] 中有一段话:

Multi-terabyte file systems, up to 16 Tbyte, are now supported under UFS, Solaris Volume Manager, and VERITAS's VxVM on machines running a 64-bit kernel. Solaris cannot boot from a file system greater than 1 Tbyte, and the fssnap command is not currently able to create a snapshot of a multi-terabyte file system. Individual files are limited to 1 Tbyte, and the maximum number of files per terabyte on a UFS file system is 1 million.

意思说最大的文件数是100万即inode数也是100万.

solaris study
是新安装的hds阵列,inode数100万左右 大概是这个数目。所以说,如果是大于1T以上,是用来存放大文件的。如果是很碎的文件,还不是不要创建这么大的文件系统
上一篇:ChinaUnix.net 下一篇:ChinaUnix.net