Skip to content

Instantly share code, notes, and snippets.

View mosolovsa's full-sized avatar
🐈

Mosolov Sergey mosolovsa

🐈
View GitHub Profile
@mosolovsa
mosolovsa / main.cpp
Created August 10, 2023 14:05
Virtual table for predefined set of custom protocol request handlers to make possible store request structures as POD and dispatching to handler via request type
#include <iostream>
#include <cassert>
using RequestHandler = void (*)(void);
struct RequestHandlers {
static constexpr size_t MAX_REQ_TYPE_CNT = 255;
enum EFlags {
IsExisting = 0x01,
};
@mosolovsa
mosolovsa / mount_qcow2.md
Created May 3, 2024 06:35 — forked from shamil/mount_qcow2.md
How to mount a qcow2 disk image

How to mount a qcow2 disk image

This is a quick guide to mounting a qcow2 disk images on your host server. This is useful to reset passwords, edit files, or recover something without the virtual machine running.

Step 1 - Enable NBD on the Host

modprobe nbd max_part=8