./autogen.sh
./configure
make
make install
rawstor-vhost \
--socket-path=/run/rawstor1.sock \
--object-uri=ost://${OST_HOST}:${OST_PORT}/${OBJECT_UUID}
./configure --without-liburing
This will replace liburing with poll.
rawstor-vhost is a userspace VirtIO block device backend that implements the vhost-user protocol. It allows virtual machines to access block storage via shared memory, bypassing the host kernel for improved performance.
rawstor-vhost \
--socket-path=/run/rawstor1.sock \
--object-uri=ost://${OST_HOST}:${OST_PORT}/${OBJECT_UUID}
qemu-system-x86_64 \
-enable-kvm \
-m 4G \
-machine accel=kvm,memory-backend=mem \
-drive file=image.qcow2,if=none,id=drive1 \
-device virtio-blk-pci,drive=drive1 \
-object memory-backend-memfd,id=mem,size=4G,share=on \
-chardev socket,id=rawstor1,reconnect=1,path=/run/rawstor1.sock \
-device vhost-user-blk-pci,chardev=rawstor1,num-queues=1,disable-legacy=on
make test
We love your contributions and want to make it as easy as possible to work together. Please follow these guidelines when contributing to this project.
For major features or significant changes, please open an issue first to discuss your proposed changes with the maintainers. This helps ensure your work aligns with the project direction and prevents duplicate effort. For small fixes (typos, minor bugs), feel free to open a pull request directly.
-
Fork the repository on GitHub
-
Clone your fork locally:
git clone https://github.com/<your-username>/librawstor.git
cd librawstor- Create a feature branch with a descriptive name:
# For new features:
git checkout -b add/feature-name
# For bug fixes:
git checkout -b fix/bug-description
# For refactoring:
git checkout -b ref/component-name-
Make your changes and commit them with clear, descriptive commit messages
-
Push your branch to your fork:
git push origin <your-branch-name>- Submit a Pull Request from your branch to the
mainbranch of therawstor/librawstorrepository
- Follow the existing code style and patterns in the project
- Write clear, descriptive commit messages
- Include comments for complex logic
- Update documentation when necessary
- Add tests for new functionality
- Provide a clear description of what the PR accomplishes
- Reference any related issues (e.g., "Fixes #123")
- Ensure all tests pass (by running
make test) and code meets quality standards - Keep PRs focused on a single purpose - avoid mixing multiple features
- Check existing issues and discussions
- Ask questions in the project's GitHub Discussions
- Reach out to maintainers by mentioning them in issues
Thank you for contributing!
io_uring_queue_init() failed: Operation not permitted
First check if io_uring is disabled or not in sysctl:
sysctl -a | grep io_uringAccording to the documentation for the sysctl files in /proc/sys/kernel/:
io_uring_disabled:Prevents all processes from creating new
io_uringinstances. Enabling this shrinks the kernel’s attack surface.
0- All processes can createio_uringinstances as normal. This is the default setting.
1-io_uringcreation is disabled (io_uring_setup()will fail with-EPERM) for unprivileged processes not in theio_uring_groupgroup. Existingio_uringinstances can still be used. See the documentation forio_uring_groupfor more information.
2-io_uringcreation is disabled for all processes.io_uring_setup()always fails with-EPERM. Existingio_uringinstances can still be used.
So you need to set it to 0:
sysctl kernel.io_uring_disabled=0