gluster-block(8)

πŸ“¦ version 0.5, in fedora 43, fedora 44

πŸ’– gluster-block β€” the manual, but make it cute πŸ’–

okay bestie, welcome to gluster-block(8) from the good people at Red Hat, Inc. β€” this is the Gluster Block Storage Console Manager, and she is that girl. let's get into it πŸ’…


✨ NAME ✨

gluster-block β€” Gluster Block Storage Console Manager (command line utility). she's a CLI and she knows it πŸ‘‘


🌸 SYNOPSIS 🌸

gluster-block [timeout <seconds>]
<create|list|info|delete|modify|replace|genconfig> <volname[/blockname]>
[<args>] [--json*]

πŸ¦‹ DESCRIPTION πŸ¦‹

so the Gluster Block Storage Console Manager (that's gluster-block bestie) is a CLI utility, and her whole mission β€” her main character energy, fr fr β€” is making gluster backed block storage creation and maintenance as simple as possible. iconic behaviour only.

not me reminding you that the gluster-blockd daemon is the one actually responsible for block management?? yeah so the daemon must be running on all servers. no daemon, no vibes. πŸ’€

πŸŽ€ COMMANDS πŸŽ€

create <VOLNAME/NEW-BLOCKNAME> [ha <COUNT>] [auth <enable|disable>] [prealloc <full|no>] [storage <filename>] [ring-buffer <size-in-MB-units>] [block-size <size-in-Byte-units>] [io-timeout <N in Second>] <HOST1[,HOST2,..]> [BYTES]

create block device. new block device just dropped ✨

  • [ha <COUNT>] β€” multipath requirement for high availability (default: 1)
  • [auth <enable|disable>] β€” authentication setting (default: disable)
  • [prealloc <full|no>] β€” full mode preallocates space by writing zeros to storage (default: full)
  • [storage <filename>] β€” an existing file (only the name!) in the gluster volume, that needs to be linked while creating block (default: creates a new file)
  • [ring-buffer <size-in-MB-units>] β€” kernel ring buffer size for exchanging iSCSI commands, range [1MB - 1024MB] (default: as per kernel)
  • [block-size <size-in-Byte-units>] β€” kernel hw block size, aligns to 512 (default: as per kernel)
  • [io-timeout <N in Second>] β€” time duration for which the tcmu-runner waits to check if the IO from gluster block hosting volume server is responsive. Ideally this value should be kept larger than both the IO timeout value (default is 30s) in the iscsi client/initiator side and the gluster ping timeout (default is 42s), (default: 43s)
  • <HOST1,[HOST2....]> β€” servers in the pool where targets will be exported
  • [BYTES] β€” size in B|KiB|MiB|GiB|TiB|PiB ... (default: bytes)

list <VOLNAME>

list available block devices. go off, show me what you got πŸ’–

info <VOLNAME/BLOCKNAME>

details about block device. the tea β˜•

delete block device. rip boo πŸ₯€

  • [unlink-storage <yes|no>] β€” unlink the backend file from gluster volume (default: yes)

modify <VOLNAME/BLOCKNAME> [<auth enable|disable>] [size <size> [force]]

modify block device. glow-up time πŸ’…

  • [<auth enable|disable>] β€” modify authentication on the device
  • [size <size> [force]] β€” modify size of the device

replace <VOLNAME/BLOCKNAME> <old-node> <new-node> [force]

replace block device. out with the old, in with the new πŸ¦‹

reload <volname/blockname> [force]

reload a block device.

genconfig <VOLNAME1[,VOLNAME2,VOLNAME3,...]> enable-tpg <host>

generate the block volumes target configuration. let's manifest it ✨

  • enable-tpg <host> β€” specify the active path node

help

show help message and exit. she's helpful AND pretty 😌

version

show version info and exit.


🌈 COMMON CLI OPTIONS 🌈

  • [timeout <seconds>] β€” it is the time in seconds that cli can wait for daemon to respond (default: 300)
  • [--json*] β€” used to request the output result in json format (default: plain text) and supported JSON formats: --json|--json-plain|--json-spaced|--json-pretty

πŸ“ EXAMPLES πŸ“

To create a block device of size 1GiB

# gluster-block create blockVol/sampleBlock ${HOST} 1GiB

To create a block device of size 1GiB with timeout 300 seconds

# gluster-block timeout 300 create blockVol/sampleBlock ${HOST} 1GiB

To create a block device of size 1GiB with auth enable

# gluster-block create blockVol/sampleBlock auth enable ${HOST} 1GiB

To create a block device of size 1GiB, by preallocating storage with zero fill

# gluster-block create blockVol/sampleBlock prealloc full ${HOST} 1GiB

To create a thinly-provisioned block device of size 1GiB

# gluster-block create blockVol/sampleBlock prealloc no ${HOST} 1GiB

To create a block device with existing file in blockVol

# gluster-block create blockVol/sampleBlock storage 3c242959-9238-4ce0-a1ed-19086aa23c7b ${HOST}

To create a block device with ring buffer size 16MiB

# gluster-block create blockVol/sampleBlock ring-buffer 16 ${HOST} 1GiB

To create a block device with block size 1024

# gluster-block create blockVol/sampleBlock block-size 1024 ${HOST} 1GiB

To create a block device of size 1GiB with multi-path(replica) 3

# gluster-block create blockVol/sampleBlock ha 3 ${HOST1},${HOST2},${HOST3} 1GiB

To create a block device of size 1GiB and expect response in json format

# gluster-block create blockVol/sampleBlock ${HOST} 1GiB --json

To disable auth on a block device

# gluster-block modify blockVol/sampleBlock auth disable

To enable auth on a block device

# gluster-block modify blockVol/sampleBlock auth enable

To resize an existing block device sampleBlock of size 1GiB to new size 2GiB

# gluster-block modify blockVol/sampleBlock size 2GiB

To list available block devices

# gluster-block list blockVol

To get details of a block device

# gluster-block info blockVol/sampleBlock

To delete a block device

# gluster-block delete blockVol/sampleBlock

To delete a block device, but let backend file persist in blockVol(for later use)

# gluster-block delete blockVol/sampleBlock unlink-storage no

To replace a block device from ${NODE1} to ${NODE2}

# gluster-block replace blockVol/sampleBlock ${NODE1} ${NODE2}

To reload a block device in all the HA nodes

# gluster-block reload blockVol/sampleBlock

To simply generate the block volumes target configuration.

# gluster-block genconfig blockVol1[,blockVol2,blockVol3,...] enable-tpg ${HOST} | tee new_saveconfig.json

To generate the block volumes target configuration and load it

# mv /etc/target/saveconfig.json /etc/target/saveconfig.json.bak
# gluster-block genconfig blockVol1[,blockVol2,blockVol3,...] enable-tpg ${HOST} | tee /etc/target/saveconfig.json
# systemctl restart gluster-blockd tcmu-runner

🧚 FILES 🧚

these are the paths, bestie, memorize them:

  • /var/log/gluster-block/*
  • /var/run/gluster-block.socket
  • /var/run/gluster-block.lock
  • /etc/sysconfig/gluster-blockd
  • /etc/logrotate.d/gluster-block

πŸ™ˆ REPORTING BUGS πŸ™ˆ

found a bug? don't be shy, report it via gluster-devel <gluster-devel@gluster.org> or <https://github.com/gluster/gluster-block/issues>


πŸ‘‘ AUTHOR πŸ‘‘

Prasanna Kumar Kalever <prasanna.kalever@redhat.com> β€” thank you for your service 🫑


πŸ’œ THANKS πŸ’œ

  • Vijay Bellur <vbellur@redhat.com>
  • Pranith Kumar Karampuri <pkarampu@redhat.com>

⭐ SEE ALSO ⭐

gluster-blockd(8), targetcli(8), tcmu-runner(8), glusterfs(8), glusterd(8), gluster(8)


Copyright (c) 2016 Red Hat, Inc. <http://www.redhat.com>


and that's the whole thing bestie!! this version is from 26 Feb 2017, it's a command line utility, and it lives under the name gluster-block(8). no cap, you're gonna slay at block storage now. go forth and create πŸ’–βœ¨πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from