From unknown Mon Aug 18 18:03:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#15056: Please indicate the meaning of block sizes in filesystem information Resent-From: Filipus Klutiero Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Fri, 09 Aug 2013 04:36:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 15056 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: 15056@debbugs.gnu.org X-Debbugs-Original-To: bug-coreutils@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.13760229453998 (code B ref -1); Fri, 09 Aug 2013 04:36:02 +0000 Received: (at submit) by debbugs.gnu.org; 9 Aug 2013 04:35:45 +0000 Received: from localhost ([127.0.0.1]:48515 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1V7eQS-00012P-KV for submit@debbugs.gnu.org; Fri, 09 Aug 2013 00:35:45 -0400 Received: from eggs.gnu.org ([208.118.235.92]:41076) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1V7eQO-000126-77 for submit@debbugs.gnu.org; Fri, 09 Aug 2013 00:35:41 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V7eQD-0003Fi-Tv for submit@debbugs.gnu.org; Fri, 09 Aug 2013 00:35:34 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, HTML_MESSAGE,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:33763) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V7eQD-0003FZ-Rk for submit@debbugs.gnu.org; Fri, 09 Aug 2013 00:35:29 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42747) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V7eQ7-0005dD-Ld for bug-coreutils@gnu.org; Fri, 09 Aug 2013 00:35:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V7eQ1-0003AZ-Ik for bug-coreutils@gnu.org; Fri, 09 Aug 2013 00:35:23 -0400 Received: from mail-qe0-x22f.google.com ([2607:f8b0:400d:c02::22f]:51697) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V7eQ1-0003AO-Et for bug-coreutils@gnu.org; Fri, 09 Aug 2013 00:35:17 -0400 Received: by mail-qe0-f47.google.com with SMTP id b10so2140453qen.20 for ; Thu, 08 Aug 2013 21:35:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject :content-type; bh=z3ABiwJ4eT8QMkdyDTe93AuedLhFYoiujAvRYHJiLpc=; b=qqB4QG1uceDX1R7aJ5Euw22VfUfBnmH/Mz+mcByIN/U8/glkCq+tpv7smRXyJMQjHZ uyJh6neZCav1LnzQNwnnSl5TxpOwoOTutv++AX0hAlPdNcFyzLaBlwtjy3wHLacV8Bdt uU8iJmKPrfOR4vU0/BXwt3L89igTC9lgdF8LbBTFINQgQOmhTMwKLbh3DMtg8IFacMwR 4sTaK7ytl4TnCOzlTY+KgbRriPwGVHqD+e3f/YbvkN+Wa66UEedeh8XBcQFP3UqQZK/j HxN1/lp0lOQNoRhI8hGo25Vm1alxwaO12KzVkenMXw+vFFq2tkHd8B5cwRcHF008oyt5 guLQ== X-Received: by 10.224.46.202 with SMTP id k10mr9492075qaf.63.1376022916800; Thu, 08 Aug 2013 21:35:16 -0700 (PDT) Received: from [192.168.1.9] (modemcable156.191-56-74.mc.videotron.ca. [74.56.191.156]) by mx.google.com with ESMTPSA id t9sm8519637qap.8.2013.08.08.21.35.15 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 08 Aug 2013 21:35:16 -0700 (PDT) Message-ID: <5204717E.1090606@gmail.com> Date: Fri, 09 Aug 2013 00:35:10 -0400 From: Filipus Klutiero User-Agent: Mozilla/5.0 (X11; Linux i686 on x86_64; rv:10.0.12) Gecko/20130116 Icedove/10.0.12 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="------------010609090400020502060801" X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -2.7 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.7 (--) This is a multi-part message in MIME format. --------------010609090400020502060801 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Severity: wishlist stat -f provides information on the filesystem, including block sizes: > Block size: 4096 Fundamental block size: 4096 The unit used in unfortunately not specified. Considering the fdisk output I get... > Sector size (logical/physical): 512 bytes / 512 bytes > I/O size (minimum/optimal): 512 bytes / 512 bytes ... I guess bits are the unit. Note that the first measure ("Block size") is quite ambiguous. http://www.hitachi.co.jp/Prod/comp/soft1/manual/jp1en/d3R4900e/PCAU0135.HTM has some block size terminology which might help (if that's indeed the type of block we mean): > The basic block size (FFBS: Fundamental Filesystem Block Size) used in the field table of this record is the allocation unit used during file system creation. The number of blocks that corresponds to the basic block size is called the /basic block count/. The logical block size (PFBS: Preferred Filesystem Block Size) is the allocation unit used during input/output operations. The number of blocks that corresponds to the logical block size is called the /logical block count/. -- Filipus Klutiero http://www.philippecloutier.com --------------010609090400020502060801 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Severity: wishlist

stat -f provides information on the filesystem, including block sizes:
Block size: 4096       Fundamental block size: 4096
The unit used in unfortunately not specified. Considering the fdisk output I get...
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
... I guess bits are the unit.

Note that the first measure ("Block size") is quite ambiguous. http://www.hitachi.co.jp/Prod/comp/soft1/manual/jp1en/d3R4900e/PCAU0135.HTM has some block size terminology which might help (if that's indeed the type of block we mean):
The basic block size (FFBS: Fundamental Filesystem Block Size) used in the field table of this record is the allocation unit used during file system creation. The number of blocks that corresponds to the basic block size is called the basic block count. The logical block size (PFBS: Preferred Filesystem Block Size) is the allocation unit used during input/output operations. The number of blocks that corresponds to the logical block size is called the logical block count.
-- 
Filipus Klutiero
http://www.philippecloutier.com
--------------010609090400020502060801-- From unknown Mon Aug 18 18:03:34 2025 X-Loop: help-debbugs@gnu.org Subject: bug#15056: Please indicate the meaning of block sizes in filesystem information Resent-From: =?UTF-8?Q?P=C3=A1draig?= Brady Original-Sender: "Debbugs-submit" Resent-CC: bug-coreutils@gnu.org Resent-Date: Fri, 09 Aug 2013 04:54:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15056 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: Filipus Klutiero Cc: 15056@debbugs.gnu.org Received: via spool by 15056-submit@debbugs.gnu.org id=B15056.13760240216203 (code B ref 15056); Fri, 09 Aug 2013 04:54:01 +0000 Received: (at 15056) by debbugs.gnu.org; 9 Aug 2013 04:53:41 +0000 Received: from localhost ([127.0.0.1]:48539 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1V7eho-0001by-OB for submit@debbugs.gnu.org; Fri, 09 Aug 2013 00:53:41 -0400 Received: from mail2.vodafone.ie ([213.233.128.44]:30443) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1V7ehn-0001bl-1P for 15056@debbugs.gnu.org; Fri, 09 Aug 2013 00:53:39 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApMBANN0BFJtTdNT/2dsb2JhbAANTr9mgnWBL4MYAQEBBDIBRhALDQEKCRYPCQMCAQIBRQYNAQcBAa51khiQGweEDgOeKoNpiHyBOg Received: from unknown (HELO [192.168.1.79]) ([109.77.211.83]) by mail2.vodafone.ie with ESMTP; 09 Aug 2013 05:53:33 +0100 Message-ID: <520475CC.2050505@draigBrady.com> Date: Fri, 09 Aug 2013 05:53:32 +0100 From: =?UTF-8?Q?P=C3=A1draig?= Brady User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130110 Thunderbird/17.0.2 MIME-Version: 1.0 References: <5204717E.1090606@gmail.com> In-Reply-To: <5204717E.1090606@gmail.com> X-Enigmail-Version: 1.5.2 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Spam-Score: 0.0 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.0 (/) On 08/09/2013 05:35 AM, Filipus Klutiero wrote: > Severity: wishlist > > stat -f provides information on the filesystem, including block sizes: >> Block size: 4096 Fundamental block size: 4096 > The unit used in unfortunately not specified. Considering the fdisk output I get... >> Sector size (logical/physical): 512 bytes / 512 bytes >> I/O size (minimum/optimal): 512 bytes / 512 bytes > ... I guess bits are the unit. always bytes There are generally 3 layers of block sizes between the file system and device: 1. physical defined by the hardware device 2. logical the smallest addressable unit used for the device 3. file system ditto for the file system So your numbers above are not the same item being represented. They're all in bytes and represent different values 1,2,3 above thanks, Pádraig.