Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-132202

gfs2_edit numerical inconsistencies

Linking RHIVOS CVEs to...Migration: Automation ...SWIFT: POC ConversionSync from "Extern...XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • rhel-9.8
    • gfs2-utils
    • None
    • None
    • None
    • rhel-fs-gfs2
    • None
    • False
    • False
    • Hide

      None

      Show
      None
    • None
    • None
    • None
    • None
    • Unspecified
    • Unspecified
    • Unspecified
    • All
    • None

      gfs2_edit behaves weird when changing flag values. It is inconsistent with respect to 0x prefixes:

      # gfs2_edit -x -p 18 field di_flags ./foo
      {{200

      1. gfs2_edit -p 18 field di_flags 200 ./foo
        GFS2_DIF_EA_INDIRECT/GFS2_DIF_APPENDONLY/GFS2_DIF_NOATIME}}

      Here, the value reported as 200 is actually 0x200 and when trying to set the field to 200, the number is interpreted as 200 decimal, which corresponds to 0xc8. Specifying the base explicitly works:

      {{# gfs2_edit -x -p 18 field di_flags 0x200 ./foo
      200}}

      Symbolic values don't really work, either:

      {{# gfs2_edit -p 18 field di_flags ./foo
      GFS2_DIF_SYSTEM

      1. gfs2_edit -p 18 field di_flags GFS2_DIF_SYSTEM ./foo
        Could not set 'di_flags' to 'GFS2_DIF_SYSTEM': Inappropriate ioctl for device}}

              anprice Andrew Price
              agruenba@redhat.com Andreas Gruenbacher
              GFS2 Maintainers Bot GFS2 Maintainers Bot
              Cluster QE Cluster QE
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated: