rublk

Crates.iorublk
lib.rsrublk
version0.2.11
created_at2023-08-22 01:42:26.58279+00
updated_at2025-09-25 14:41:11.871713+00
descriptionRust ublk generic targets
homepage
repositoryhttps://github.com/ublk-org/rublk
max_upload_size
id950632
size252,999
Ming Lei (ming1)

documentation

README

rublk

[License: GPL v2] (https://github.com/ming1/rublk/blob/master/COPYING)

Rust ublk generic target implementation, which depends on libublk1, which talks with linux ublk driver2 for building and exposing standard linux block device, meantime all target IO logic is moved to userspace.

Linux kernel 6.0 starts to support ublk covered by config option of CONFIG_BLK_DEV_UBLK.

Documentations

ublk doc links

ublk introduction

Quick Start

cargo install rublk

modprobe ublk_drv

rublk help

$ rublk help
Usage: rublk <COMMAND>

Commands:
  add       Adds ublk target
  del       Deletes ublk target
  list      Lists ublk targets
  recover   Recover ublk targets
  features  Get supported features from ublk driver, supported since v6.5
  vram      GPU VRAM target specific commands
  help      Print this message or the help of the given subcommand(s)

Options:
  -h, --help     Print help
  -V, --version  Print version

rublk add help

$ rublk add help
Adds ublk target

Usage: rublk add <COMMAND>

Commands:
  loop   Add loop target
  null   Add null target
  zoned  Add zoned target, supported since v6.6
  qcow2  Add qcow2 target
  compress  Add RocksDB based compression target
  vram   Add vram target (GPU memory block device)
  help   Print this message or the help of the given subcommand(s)

Options:
  -h, --help  Print help

License

This project is licensed under GPL-2.0.

Contributing

Any kinds of contributions are welcome!

Footnotes

  1. https://crates.io/crates/libublk

  2. https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/block/ublk_drv.c?h=v6.0

Commit count: 333

cargo fmt