From owner-freebsd-fs@FreeBSD.ORG Wed Oct 1 23:01:34 2008 Return-Path: Delivered-To: freebsd-fs@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B2AAA1065686; Wed, 1 Oct 2008 23:01:34 +0000 (UTC) (envelope-from 000.fbsd@quip.cz) Received: from elsa.codelab.cz (elsa.codelab.cz [91.103.162.4]) by mx1.freebsd.org (Postfix) with ESMTP id 732718FC15; Wed, 1 Oct 2008 23:01:34 +0000 (UTC) (envelope-from 000.fbsd@quip.cz) Received: from localhost (localhost.codelab.cz [127.0.0.1]) by elsa.codelab.cz (Postfix) with ESMTP id CAF9119E023; Thu, 2 Oct 2008 01:01:32 +0200 (CEST) Received: from [192.168.1.2] (r5bb235.net.upc.cz [86.49.61.235]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by elsa.codelab.cz (Postfix) with ESMTPSA id 975AE19E019; Thu, 2 Oct 2008 01:01:30 +0200 (CEST) Message-ID: <48E4016C.5000909@quip.cz> Date: Thu, 02 Oct 2008 01:02:04 +0200 From: Miroslav Lachman <000.fbsd@quip.cz> User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.12) Gecko/20050915 X-Accept-Language: cz, cs, en, en-us MIME-Version: 1.0 To: freebsd-fs@FreeBSD.org Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Cc: pjd@FreeBSD.org Subject: ZFS inodes issue (0 reported by df -hi) X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 01 Oct 2008 23:01:34 -0000 I am stresstesting ZFS filesystem on my test machine and sometimes see wrong output of df in inodes columns - reporting zero used inodes when more than 53 milions are used. Bellow is df -hi reports taken in few seconds / minutes (there are running some heavy copying tasks in the background) [other partitions was stripped for clarity] root@cage ~/# df -hi Filesystem Size Used Avail Capacity iused ifree %iused Mounted tank 364G 362G 1.9G 99% 0 15915 0% /tank ^^^^^^ ^^^^^^ root@cage ~/# df -hi Filesystem Size Used Avail Capacity iused ifree %iused Mounted tank 364G 362G 1.9G 99% 53382659 15757 100% /tank root@cage ~/# df -hi Filesystem Size Used Avail Capacity iused ifree %iused Mounted tank 364G 362G 1.9G 99% 53391685 15503 100% /tank root@cage ~/# df -hi Filesystem Size Used Avail Capacity iused ifree %iused Mounted tank 364G 363G 1.3G 100% 0 10965 0% /tank ^^^^^^ ^^^^^^ root@cage ~/# df -hi Filesystem Size Used Avail Capacity iused ifree %iused Mounted tank 364G 363G 1.3G 100% 53591981 10817 100% /tank root@cage ~/# df -hi Filesystem Size Used Avail Capacity iused ifree %iused Mounted tank 364G 363G 1.0G 100% 0 8267 0% /tank ^^^^^^ ^^^^^^ root@cage ~/# df -hi Filesystem Size Used Avail Capacity iused ifree %iused Mounted tank 364G 363G 1.0G 100% 53672433 8245 100% /tank Next thing that I do not understand is how ZFS uses inodes? The total number of inodes (iused+ifree) grows by the time as filesystem is more and more filled. Version: FreeBSD 7.0-RELEASE-p2 #0: Wed Jun 18 06:48:16 UTC 2008 root@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64 Miroslav Lachman