<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffcc" text="#000066">
<tt>Ok.. My bad here.. I mixed up outputs from mkfs and debugfs.. the
script just works as it appends the output of the mkfs, so it end up
finding the words... This patch can be ignored.<br>
<br>
</tt>
<pre class="moz-signature" cols="72">Regards,

Marcos Eduardo Matsunaga

Oracle USA
Linux Engineering

“The statements and opinions expressed here are my own and do not
necessarily represent those of Oracle Corporation.”
</pre>
<br>
<br>
Sunil Mushran wrote:
<blockquote cite="mid:4A20462C.7020205@oracle.com" type="cite">Marcos
Matsunaga wrote:
  <br>
  <blockquote type="cite">Debugfs.ocfs2 had some changes on the way it
displays the output.
    <br>
This change makes it compatible with the new output. Also, due to the
    <br>
change on the way it reports some information (it now reports the size
    <br>
and not the bits), the calculation of blocksize and clustersize is not
    <br>
necessary anymore.  The calculation was removed and the comparison is
    <br>
now made directly to the results obtained from debugfs.ocfs2.
    <br>
    <br>
Signed-off-by: Marcos Matsunaga <a class="moz-txt-link-rfc2396E" href="mailto:Marcos.Matsunaga@oracle.com">&lt;Marcos.Matsunaga@oracle.com&gt;</a>
    <br>
---
    <br>
 programs/mkfs-tests/mkfs-test.sh |   14 ++++++--------
    <br>
 1 files changed, 6 insertions(+), 8 deletions(-)
    <br>
    <br>
diff --git a/programs/mkfs-tests/mkfs-test.sh
b/programs/mkfs-tests/mkfs-test.sh
    <br>
index 51d61be..4db63d6 100755
    <br>
--- a/programs/mkfs-tests/mkfs-test.sh
    <br>
+++ b/programs/mkfs-tests/mkfs-test.sh
    <br>
@@ -24,9 +24,9 @@ verify_sizes() {
    <br>
 
    <br>
     ${DEBUGFS} -R "stats" ${device} &gt;&gt; ${O} 2&gt;/dev/null
    <br>
 
    <br>
-    num1=`${AWK} '/Block Size Bits/ {print $4;}' ${O}`
    <br>
-    num2=`${AWK} '/Cluster Size Bits/ {print $8;}' ${O}`
    <br>
-    num3=`${AWK} '/Clusters:/ {print $4;}' ${O}`
    <br>
+    num1=`${AWK} '/Block size=/ {print $2;}' ${O}|cut -f2 -d"="`
    <br>
+    num2=`${AWK} '/Cluster size=/ {print $2;}' ${O}|cut -f2 -d"="`
    <br>
+    num3=`${AWK} '/Volume size=/ {print $3;}' ${O}|cut -f2 -d"("`
    <br>
  </blockquote>
  <br>
Where do you see this? Are you running the current debugfs?
  <br>
  <br>
# debugfs.ocfs2 -V
  <br>
debugfs.ocfs2 1.4.2
  <br>
# debugfs.ocfs2 -R "stats" /dev/sda1
  <br>
   Revision: 0.90
  <br>
   Mount Count: 0   Max Mount Count: 20
  <br>
   State: 0   Errors: 0
  <br>
   Check Interval: 0   Last Check: Tue May 19 19:35:15 2009
  <br>
   Creator OS: 0
  <br>
   Feature Compat: 1 backup-super
  <br>
   Feature Incompat: 0
  <br>
   Tunefs Incomplete: 0
  <br>
   Feature RO compat: 0
  <br>
   Root Blknum: 5   System Dir Blknum: 6
  <br>
   First Cluster Group Blknum: 3
  <br>
   Block Size Bits: 12   Cluster Size Bits: 12
  <br>
   Max Node Slots: 8
  <br>
   Extended Attributes Inline Size: 0
  <br>
   Label: ocfs2vol
  <br>
   UUID: 84044D1EFFFD433092C63486CAB85C0F
  <br>
   UUID_hash: 0 (0x0)
  <br>
   Cluster stack: classic o2cb
  <br>
   Inode: 2   Mode: 00   Generation: 2873114974 (0xab40415e)
  <br>
   FS Generation: 2873114974 (0xab40415e)
  <br>
   CRC32: 00000000   ECC: 0000
  <br>
   Type: Unknown   Attr: 0x0   Flags: Valid System Superblock
  <br>
   Dynamic Features: (0x0)
  <br>
   User: 0 (root)   Group: 0 (root)   Size: 0
  <br>
   Links: 0   Clusters: 13107196
  <br>
   ctime: 0x48600673 -- Mon Jun 23 13:24:19 2008
  <br>
   atime: 0x0 -- Wed Dec 31 16:00:00 1969
  <br>
   mtime: 0x48600673 -- Mon Jun 23 13:24:19 2008
  <br>
   dtime: 0x0 -- Wed Dec 31 16:00:00 1969
  <br>
   ctime_nsec: 0x00000000 -- 0
  <br>
   atime_nsec: 0x00000000 -- 0
  <br>
   mtime_nsec: 0x00000000 -- 0
  <br>
   Last Extblk: 0
  <br>
   Sub Alloc Slot: Global   Sub Alloc Bit: 65535
  <br>
  <br>
  <blockquote type="cite"> 
    <br>
     if [ ${num1} -eq 0 ] || [ ${num2} -eq 0 ] || [ ${num3} -eq 0 ]
    <br>
     then
    <br>
@@ -34,17 +34,15 @@ verify_sizes() {
    <br>
         exit 1
    <br>
     fi
    <br>
 
    <br>
-    b=$[$[2**$[${num1} - 9]]*512]
    <br>
-    c=$[$[2**$[${num2} - 9]]*512]
    <br>
-    v=$[${num3} * ${c}/${b}]
    <br>
+    v=$[${num3} * ${num2}/${num1}]
    <br>
 
    <br>
      echo -n "verify ..... "  |tee -a ${LOGFILE}
    <br>
 
    <br>
-    if [ ${B} -ne ${b} ]; then
    <br>
+    if [ ${B} -ne ${num1} ]; then
    <br>
         echo "ERROR: Blocksize mismatch - found ${b}, expected ${B}"
&gt;&gt; ${O}
    <br>
         RET=1
    <br>
     fi
    <br>
-    if [ ${C} -ne ${c} ]; then
    <br>
+    if [ ${C} -ne ${num2} ]; then
    <br>
         echo "ERROR: Clustersize mismatch - found ${c}, expected ${C}"
&gt;&gt; ${O}
    <br>
         RET=1
    <br>
     fi
    <br>
  </blockquote>
  <br>
</blockquote>
</body>
</html>