+++ This bug was initially created as a clone of Bug #719943 +++ Description of problem: $ dd if=/dev/null of=sparse-file bs=1 count=0 seek=1T $ ./mkfs.gfs2 -t foo:bar sparse-file ../../gfs2/libgfs2/libgfs2.h: sparse-file is not a block device --- Additional comment from anprice on 2011-07-11 10:26:52 EDT --- Created attachment 512229 [details] Patch to handle regular files --- Additional comment from anprice on 2011-07-11 12:22:20 EDT --- Created attachment 512257 [details] Patch to handle regular files, v2 --- Additional comment from anprice on 2011-07-11 12:54:36 EDT --- Patch v2 is now in gfs2-utils.git. Closing as UPSTREAM.
Created attachment 517618 [details] Backported patch
Above patch is now in the RHEL58 branch of cluster.git
Can you please post some unit test results to show that development has tried out the fix in the 5.8 package FMI see http://wiki.test.redhat.com/ClusterStorage/WhyNeedDevTestResults
Using the steps from the original bug: [root@exxon-01 ~]# rpm -q gfs2-utils gfs2-utils-0.1.62-33.el5 [root@exxon-01 ~]# dd if=/dev/null of=sparse-file bs=1 count=0 seek=1T 0+0 records in 0+0 records out 0 bytes (0 B) copied, 1.4e-05 seconds, 0.0 kB/s [root@exxon-01 ~]# mkfs.gfs2 -O -t foo:bar sparse-file Device: sparse-file Blocksize: 4096 Device Size 1024.00 GB (268435456 blocks) Filesystem Size: 1024.00 GB (268435454 blocks) Journals: 1 Resource Groups: 4096 Locking Protocol: "lock_dlm" Lock Table: "foo:bar" UUID: 0B8E5EE2-895C-5A71-5B33-EE604A160401 [root@exxon-01 ~]# fsck.gfs2 sparse-file Initializing fsck Validating Resource Group index. Level 1 RG check. (level 1 passed) Starting pass1 Pass1 complete Starting pass1b Pass1b complete Starting pass1c Pass1c complete Starting pass2 Pass2 complete Starting pass3 Pass3 complete Starting pass4 Pass4 complete Starting pass5 Pass5 complete gfs2_fsck complete
[root@localhost ~]# rpm -q gfs2-utils gfs2-utils-0.1.62-31.el5 [root@localhost ~]# dd if=/dev/null of=sparse-file bs=1 count=0 seek=256M 0+0 records in 0+0 records out 0 bytes (0 B) copied, 7e-06 seconds, 0.0 kB/s [root@localhost ~]# mkfs.gfs2 -O -t foo:bar sparse-file mkfs.gfs2: sparse-file is not a block device [root@localhost ~]# rpm -q gfs2-utils gfs2-utils-0.1.62-33.el5 [root@localhost ~]# dd if=/dev/null of=sparse-file bs=1 count=0 seek=256M 0+0 records in 0+0 records out 0 bytes (0 B) copied, 7e-06 seconds, 0.0 kB/s [root@localhost ~]# mkfs.gfs2 -O -t foo:bar sparse-file Device: sparse-file Blocksize: 4096 Device Size 0.25 GB (65536 blocks) Filesystem Size: 0.25 GB (65534 blocks) Journals: 1 Resource Groups: 1 Locking Protocol: "lock_dlm" Lock Table: "foo:bar" UUID: 602C068C-6D89-FA0A-847A-A9D9DCBE0390 [root@localhost ~]# fsck.gfs2 sparse-file Initializing fsck Validating Resource Group index. Level 1 RG check. (level 1 passed) Starting pass1 Pass1 complete Starting pass1b Pass1b complete Starting pass1c Pass1c complete Starting pass2 Pass2 complete Starting pass3 Pass3 complete Starting pass4 Pass4 complete Starting pass5 Pass5 complete gfs2_fsck complete Verified in gfs2-utils-0.1.62-33.el5
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. http://rhn.redhat.com/errata/RHBA-2012-0269.html