]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/commit
MFC of 269533:
authormckusick <mckusick@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Thu, 28 May 2015 00:11:36 +0000 (00:11 +0000)
committermckusick <mckusick@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Thu, 28 May 2015 00:11:36 +0000 (00:11 +0000)
commit2e60436ee5ff99830a184c6a6f055e80a12cd6ec
treeb4a35f5f10df4eaba01126a2ffe3ce3bacd636f7
parent2bd3a9413eaaf25a06a1641ba8a2aad438135ed0
MFC of 269533:

Limit the number of cylinder groups that will be searched when
trying to build a cluster. The limit is tunable using the sysctl
vfs.ffs.maxclustersearch. The current limit is 10 cylinder groups
per block allocation. It was previously limited to the number of
cylinder groups in the filesystem per block allocation. When there
were no clusters of the needed size left, it repeatedly searched
the whole filesystem for a non-existent cluster on every block
allocation. The result was very slow filesystem allocation with
100% CPU utilization. The old behavior can be had by setting
vfs.ffs.maxclustersearch to a huge number (1,000,000).

This change affects only the layout policy routines so is not able
to interfere with the integrity of the filesystem.

Reported by: Dmitry Sivachenko (demon@)
Tested by:   Dmitry Sivachenko (demon@)

git-svn-id: svn://svn.freebsd.org/base/stable/10@283640 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
sys/ufs/ffs/ffs_alloc.c
sys/ufs/ffs/ffs_vfsops.c
sys/ufs/ufs/inode.h