From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) by lore.proxmox.com (Postfix) with ESMTPS id 21E4D1FF136 for ; Mon, 23 Mar 2026 12:33:40 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 699D513B8F; Mon, 23 Mar 2026 12:33:59 +0100 (CET) From: Kefu Chai To: pve-devel@lists.proxmox.com Subject: [PATCH pve-cluster v3 00/13] Rewrite pmxcfs with Rust Date: Mon, 23 Mar 2026 19:32:15 +0800 Message-ID: <20260323113239.942866-1-k.chai@proxmox.com> X-Mailer: git-send-email 2.47.3 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1774265530311 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.289 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record URIBL_CSS_A 0.1 Contains URL's A record listed in the Spamhaus CSS blocklist [185.73.182.252] Message-ID-Hash: O2NBT5KM5XJPID6BLJIR5ZER6RJ6STC7 X-Message-ID-Hash: O2NBT5KM5XJPID6BLJIR5ZER6RJ6STC7 X-MailFrom: k.chai@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Kefu Chai X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox VE development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Hello, Thank you for the detailed code reviews. V3 incorporates your feedback, also includes clean ups in different perspectives. Changes are organized by crate below. pmxcfs-rs Changelog =================== Changes since v2 pmxcfs-api-types ---------------- - New `errno` module: convenience constructors (enoent, eexist, eacces, enotempty, os_err) for building io::Error with POSIX errno values. Replaces the repetitive io::Error::from_raw_os_error(libc::E*) pattern spread across the workspace. - Dead-code cleanup in PmxcfsError: removed 20 unused variants (Io, Database, Fuse, Cluster, Corosync, Ipc, PermissionDenied, NotFound, AlreadyExists, etc.). Only System and Configuration are retained, matching actual usage. Operational/FUSE errors use std::io::Error with the errno helpers above. - VmType::TryFrom: added explicit conversion; returns an error for unknown values, defensive against future wire deserialization paths. pmxcfs-memdb ------------ - Node-rejoin sync fix: the root entry was excluded from the encoded index snapshot, so a rejoining node could miss files written during its absence. Fixed by including the root __version__ row in the snapshot. - create() / create_replicated() split: the VMID uniqueness check in create() was incorrectly running in the DFSM callback path, blocking C-to-Rust migration because the destination config is created while the source (same VMID, different node) still exists. Added create_replicated() for the DFSM path that skips the check; create() (FUSE layer) retains it. The C implementation is equivalent: it checks cfs_status.vmlist, a lazy hash table that may not yet reflect remote state, effectively bypassing the check for incoming replication. - C parity -- VMID uniqueness on create and rename: create() rejects a VM config if the same VMID already exists on a different node (matching memdb_create() in C). rename() likewise rejects moves that would produce a VMID collision, and refuses to rename a non-empty directory (matching C's memdb_rename()). - MemDbOps returns io::Result: all operational methods (create, write, delete, rename, setmtime) switched from anyhow::Result to std::io::Result, so callers can read the raw OS errno directly. - sync.rs extracted: state-synchronization methods moved from database.rs into a dedicated sync.rs module. - Tests moved to tests/database_tests.rs: public-API integration tests relocated to the standard Rust integration test directory. pmxcfs-dfsm ----------- - Cluster log wire format fix: ClogEntryHeader was serialized with incorrect field offsets, breaking log propagation to/from C nodes. Fixed to match C's 44-byte layout with correct alignment and padding. - FuseMessage::Mtime carries the mtime value: the Mtime variant previously held only a path; the mtime itself was not transmitted. It now serializes the mtime into the offset field of CFuseMessage, matching dcdb.c:900. - FuseMessage::UnlockRequest / Unlock carry checksum: both variants now include the 32-byte lock checksum in their wire payload ([32B checksum][path\0]), matching C's unlock message format. - Callbacks::deliver_message returns io::Result: aligns the callback trait with the rest of the workspace error-handling convention. - Cluster log UID deduplication fix: the database DFSM and the status DFSM each had their own static AtomicU32 UID counter. When both emit log entries in the same second from the same node, the (time, nodeid, uid) tuple used by C's dedup table could collide, silently dropping one entry. Fixed by exposing next_uid() from pmxcfs-logger and sharing a single counter across all log producers. - resend_queued_messages_with: the is_empty() early-return checked whether the entire message queue was empty, not whether it contained any messages from this node. A queue holding only other nodes' messages would fall through to the send loop and send nothing, but now correctly exits early. Fixed by filtering to own messages before the emptiness check. - Pure-departure C interoperability fix: when a node leaves with no new members joining, the remaining nodes were already in sync so no re-synchronization is semantically needed. However, C nodes without this fix unconditionally enter START_SYNC on any membership change and wait for SYNC_START from the leader; skipping it caused those C peers to hang indefinitely. Fixed by having the Rust leader enter StartSync and send SYNC_START + own state on pure departures, matching C's expectation. In a pure-Rust cluster this results in a lightweight no-op sync round on each departure (the merge is a no-op since all nodes already agree). pmxcfs-status ------------- - Domain trait split: StatusOps refactored into five focused traits -- ClusterOps, VmOps, LoggingOps, MetricsOps, NodeStateOps -- each covering a distinct concern. StatusOps is now a supertrait of the five. - Tests moved to tests/status_tests.rs: public-API tests relocated out of src/. pmxcfs-logger ------------- - RingBuffer redesigned to store the C binary layout directly: the internal representation is now a single `Vec` byte slab matching `clog_base_t` (header 8 bytes + ring data), rather than a `VecDeque`. `serialize_binary()` is now a `Vec::clone()` — no entry iteration or struct reconstruction on every DFSM sync. `add_entry()` writes the entry body directly into the allocated slot via `write_body_to()`, mirroring C's `clog_copy` (`memcpy((char*)new + 8, (char*)entry + 8, size - 8)`). `iter()` walks the prev-chain and parses `LogEntry` values on the fly for read paths only. So the concerns on the performance might be a mood now, but if you still have concerns, I will prepare a proper benchmark test. - get_buffer was gated by #[cfg(test)], making it invisible to integration tests in the tests/ directory. Integration tests are compiled as separate crates that link against the library without cfg(test), so test-only items on library methods are not visible to them. Removed the attribute. pmxcfs (binary crate) --------------------- - memdb_callbacks.rs errno propagation: all handle_* methods previously returned -EACCES on any memdb error regardless of actual cause. They now extract the OS errno from the returned io::Error (e.g. EEXIST for duplicate creates, ENOTEMPTY for non-empty dir deletes). - handle_create / handle_mkdir / handle_write use create_replicated(): DFSM callback creates bypass the VMID uniqueness check (see pmxcfs-memdb above), enabling live migration between C and Rust nodes. - mkdir mode set to 0750: matches C's memdb_mkdir(); previously the mode was 0. - MTIME always broadcast via DFSM: setattr no longer skips the DFSM broadcast for mtime-only changes, matching C's cfs-plug-memdb.c:420-422. Fixes lock renewal timestamps not propagating to remote nodes. - FUSE startup race: send_fuse_message called .expect("called without checking dfsm") and would panic if a FUSE operation arrived before the DFSM finished initializing. Changed to log a warning and return EACCES, matching the behaviour of the quorum gate for write operations. integration-tests ----------------- - New test 14-vm-migration-sim.sh (mixed-cluster): simulates the pmxcfs file operations PVE performs during a live VM/CT migration. Two scenarios: Rust node1 -> C node3 (QEMU VM) and C node3 -> Rust node2 (LXC CT). Each verifies pre-migration visibility on all nodes, simultaneous destination-create / source-delete, and post-migration consistency on all three nodes. - Shared FUSE path helpers in test-config.sh: _mount_root_for, read/write/delete/assert_file_on_node abstract the Rust (/test/pve) vs C (/etc/pve) mount path difference, eliminating per-test duplication. - Container startup race fixes (docker/start-cluster-node.sh): * CNI network race: wait loop for the node IP to appear on the interface before starting corosync, preventing "One of your ip addresses are now bound to localhost" failures on fresh container starts. * Authkey race: only NODE_ID=1 generates the shared authkey; other nodes wait up to 15s, preventing simultaneous overwrites causing TOTEM authentication failures. - Cluster network config centralized (docker/network-config.sh, mixed.env, cluster.env): subnet and node IPs defined once; compose files and startup scripts source a single env file. - Various test correctness fixes: inflated sleep values reverted, .members format corrected for single-node mode, test assertions tightened. Debian stable build compatibility ---------------------------------- The workspace now builds cleanly against the Rust packages shipped in Debian stable (/usr/share/cargo/registry) without requiring network access to crates.io. - pmxcfs-rrd: the `rrd` crate (C FFI wrapper for librrd) is not packaged in Debian. Replaced with a minimal in-tree `librrd` module (src/librrd/) that covers the two operations used by the direct backend: `rrd_updatex_r` (update) and `rrd_create_r2` (create). The public API mirrors the `rrd` crate's module structure so no call-site changes were needed. A build.rs adds `-lrrd` for the linker; librrd-dev 1.7.2 is the system library. The unused `nom` dependency (parsers.rs had already been rewritten to plain string ops) was also removed. - pmxcfs (binary): the `users` crate is not packaged in Debian. Its sole use was `get_group_by_name("www-data")`, replaced with `nix::unistd::Group::from_name` which is already a workspace dependency. The unused `base64` workspace dependency was also removed. - pmxcfs-memdb: downgraded rusqlite from 0.30 to 0.29 to match Debian's package. Dropped the `bundled` feature (statically-linked SQLite) in favour of linking against the system libsqlite3. - workspace Cargo.toml: aligned remaining version requirements with Debian stable packages: thiserror "1.0"→"2.0", nix "0.27"→"0.29", num_enum "0.7"→"0.5". - vendor/rust-corosync: updated to bitflags 2 (Debian ships 2.x only). Fixed two bitflags 1.x struct-literal constructions (`Flags{bits: x}` → `from_bits_retain(x)`) and one field access (`.bits` → `.bits()`). - pmxcfs (binary) / nix 0.29 API change: `pipe()` now returns `(OwnedFd, OwnedFd)` instead of `(RawFd, RawFd)`. daemon.rs converts the pair to RawFd via `into_raw_fd()` immediately after the call so all downstream libc usage is unchanged. - pmxcfs-logger: restored `HashSet`-based cycle detection in `RingBufferIter`. A prior simplifier pass replaced it with a capacity-based counter, which broke wraparound: after the ring overwrites old entries, stale prev-chain pointers traverse garbage data that the C wrap-around guard does not catch, causing the iterator to exhaust the counter (853 entries from 70 added). The HashSet correctly terminates on any revisited offset. Kefu Chai (13): pmxcfs-rs: add pmxcfs-api-types crate pmxcfs-rs: add pmxcfs-config crate pmxcfs-rs: add pmxcfs-logger crate pmxcfs-rs: add pmxcfs-rrd crate pmxcfs-rs: add pmxcfs-memdb crate pmxcfs-rs: add pmxcfs-status and pmxcfs-test-utils crates pmxcfs-rs: add pmxcfs-services crate pmxcfs-rs: add pmxcfs-ipc crate pmxcfs-rs: add pmxcfs-dfsm crate pmxcfs-rs: vendor patched rust-corosync for CPG compatibility pmxcfs-rs: add pmxcfs main daemon binary pmxcfs-rs: add integration and workspace tests pmxcfs-rs: add project documentation src/pmxcfs-rs/.cargo/config.toml | 8 + src/pmxcfs-rs/.gitignore | 2 + src/pmxcfs-rs/ARCHITECTURE.txt | 350 ++ src/pmxcfs-rs/Cargo.toml | 101 + src/pmxcfs-rs/Makefile | 39 + src/pmxcfs-rs/README.md | 304 ++ src/pmxcfs-rs/integration-tests/.gitignore | 1 + src/pmxcfs-rs/integration-tests/README.md | 367 ++ .../integration-tests/docker/.dockerignore | 17 + .../integration-tests/docker/Dockerfile | 96 + .../integration-tests/docker/cluster.env | 5 + .../integration-tests/docker/debian.sources | 5 + .../docker/docker-compose.cluster.yml | 115 + .../docker/docker-compose.mixed.yml | 128 + .../docker/docker-compose.yml | 55 + .../integration-tests/docker/healthcheck.sh | 19 + .../docker/lib/corosync.conf.mixed.template | 52 + .../docker/lib/corosync.conf.template | 45 + .../docker/lib/setup-cluster.sh | 67 + .../integration-tests/docker/mixed.env | 5 + .../docker/network-config.sh | 52 + .../docker/proxmox-archive-keyring.gpg | Bin 0 -> 2372 bytes .../docker/pve-no-subscription.sources | 5 + .../docker/start-cluster-node.sh | 179 + src/pmxcfs-rs/integration-tests/run-tests.sh | 494 +++ src/pmxcfs-rs/integration-tests/test | 238 ++ src/pmxcfs-rs/integration-tests/test-local | 333 ++ .../tests/cluster/01-connectivity.sh | 59 + .../tests/cluster/02-file-sync.sh | 181 + .../tests/cluster/03-clusterlog-sync.sh | 283 ++ .../tests/cluster/04-binary-format-sync.sh | 341 ++ .../tests/core/01-test-paths.sh | 74 + .../tests/core/02-plugin-version.sh | 73 + .../integration-tests/tests/dfsm/01-sync.sh | 218 ++ .../tests/dfsm/02-multi-node.sh | 159 + .../tests/fuse/01-operations.sh | 100 + .../tests/fuse/02-quorum-permissions.sh | 320 ++ .../tests/fuse/03-write-operations.sh | 283 ++ .../tests/fuse/04-chmod-chown.sh | 142 + .../tests/fuse/05-posix-restrictions.sh | 125 + .../tests/fuse/06-access-rights.sh | 142 + .../tests/fuse/07-vmid-uniqueness.sh | 143 + .../tests/ipc/01-socket-api.sh | 104 + .../tests/ipc/02-flow-control.sh | 89 + .../tests/ipc/03-log-cluster-msg.sh | 231 ++ .../tests/ipc/04-get-cluster-log.sh | 344 ++ .../tests/ipc/05-get-rrd-dump.sh | 251 ++ .../tests/ipc/06-readonly-ops.sh | 311 ++ .../tests/ipc/07-write-ops.sh | 185 + .../tests/ipc/08-guest-config-ops.sh | 273 ++ .../tests/ipc/09-all-ipc-ops.sh | 136 + .../integration-tests/tests/ipc/README.md | 43 + .../tests/ipc/perl/IPCTestLib.pm | 102 + .../tests/ipc/perl/README.md | 45 + .../tests/ipc/perl/get-cluster-info.pl | 49 + .../tests/ipc/perl/get-cluster-log.pl | 52 + .../tests/ipc/perl/get-config.pl | 37 + .../tests/ipc/perl/get-fs-version.pl | 35 + .../ipc/perl/get-guest-config-properties.pl | 51 + .../ipc/perl/get-guest-config-property.pl | 42 + .../tests/ipc/perl/get-guest-list.pl | 38 + .../tests/ipc/perl/get-rrd-dump.pl | 28 + .../tests/ipc/perl/get-status.pl | 33 + .../tests/ipc/perl/log-cluster-msg.pl | 43 + .../tests/ipc/perl/set-status.pl | 30 + .../tests/ipc/perl/verify-token.pl | 29 + .../integration-tests/tests/ipc/test-lib.sh | 101 + .../tests/locks/01-lock-management.sh | 134 + .../tests/logger/01-clusterlog-basic.sh | 119 + .../integration-tests/tests/logger/README.md | 111 + .../tests/memdb/01-access.sh | 103 + .../tests/mixed-cluster/01-node-types.sh | 130 + .../tests/mixed-cluster/02-file-sync.sh | 219 ++ .../tests/mixed-cluster/03-quorum.sh | 229 ++ .../04-c-rust-binary-validation.sh | 359 ++ .../mixed-cluster/05-merge-correctness.sh | 298 ++ .../tests/mixed-cluster/06-stress-test.sh | 339 ++ .../tests/mixed-cluster/07-mtime-sync.sh | 370 ++ .../08-mixed-cluster-rrd-interop.sh | 369 ++ .../tests/mixed-cluster/09-quorum-gate.sh | 175 + .../tests/mixed-cluster/10-vm-config-sync.sh | 265 ++ .../mixed-cluster/11-cluster-log-interop.sh | 571 +++ .../mixed-cluster/12-status-consistency.sh | 296 ++ .../mixed-cluster/13-node-rejoin-sync.sh | 301 ++ .../mixed-cluster/14-vm-migration-sim.sh | 239 ++ .../tests/plugins/01-plugin-files.sh | 146 + .../tests/plugins/02-clusterlog-plugin.sh | 355 ++ .../tests/plugins/03-plugin-write.sh | 197 + .../integration-tests/tests/plugins/README.md | 52 + .../tests/rrd/01-rrd-basic.sh | 93 + .../tests/rrd/02-schema-validation.sh | 411 ++ .../tests/rrd/03-rrdcached-integration.sh | 367 ++ .../tests/rrd/05-column-skip-transform.sh | 391 ++ .../tests/rrd/README-MIXED-CLUSTER-RRD.md | 373 ++ .../integration-tests/tests/rrd/README.md | 164 + .../integration-tests/tests/run-c-tests.sh | 321 ++ .../tests/status/01-status-tracking.sh | 194 + .../tests/status/02-status-operations.sh | 202 + .../tests/status/03-multinode-sync.sh | 481 +++ .../integration-tests/tests/test-config.sh | 303 ++ src/pmxcfs-rs/pmxcfs-api-types/Cargo.toml | 19 + src/pmxcfs-rs/pmxcfs-api-types/README.md | 17 + src/pmxcfs-rs/pmxcfs-api-types/src/errno.rs | 75 + src/pmxcfs-rs/pmxcfs-api-types/src/error.rs | 15 + src/pmxcfs-rs/pmxcfs-api-types/src/lib.rs | 97 + src/pmxcfs-rs/pmxcfs-config/Cargo.toml | 15 + src/pmxcfs-rs/pmxcfs-config/README.md | 15 + src/pmxcfs-rs/pmxcfs-config/src/lib.rs | 365 ++ src/pmxcfs-rs/pmxcfs-dfsm/Cargo.toml | 47 + src/pmxcfs-rs/pmxcfs-dfsm/README.md | 340 ++ src/pmxcfs-rs/pmxcfs-dfsm/src/callbacks.rs | 80 + .../src/cluster_database_service.rs | 111 + src/pmxcfs-rs/pmxcfs-dfsm/src/cpg_service.rs | 256 ++ src/pmxcfs-rs/pmxcfs-dfsm/src/dfsm_message.rs | 725 ++++ src/pmxcfs-rs/pmxcfs-dfsm/src/fuse_message.rs | 233 ++ .../pmxcfs-dfsm/src/kv_store_message.rs | 560 +++ src/pmxcfs-rs/pmxcfs-dfsm/src/lib.rs | 32 + src/pmxcfs-rs/pmxcfs-dfsm/src/message.rs | 21 + .../pmxcfs-dfsm/src/state_machine.rs | 1815 +++++++++ .../pmxcfs-dfsm/src/status_sync_service.rs | 113 + src/pmxcfs-rs/pmxcfs-dfsm/src/types.rs | 107 + src/pmxcfs-rs/pmxcfs-dfsm/src/wire_format.rs | 283 ++ .../tests/multi_node_sync_tests.rs | 568 +++ src/pmxcfs-rs/pmxcfs-ipc/Cargo.toml | 44 + src/pmxcfs-rs/pmxcfs-ipc/README.md | 171 + .../pmxcfs-ipc/examples/test_server.rs | 92 + src/pmxcfs-rs/pmxcfs-ipc/src/connection.rs | 768 ++++ src/pmxcfs-rs/pmxcfs-ipc/src/handler.rs | 93 + src/pmxcfs-rs/pmxcfs-ipc/src/lib.rs | 41 + src/pmxcfs-rs/pmxcfs-ipc/src/protocol.rs | 332 ++ src/pmxcfs-rs/pmxcfs-ipc/src/ringbuffer.rs | 1362 +++++++ src/pmxcfs-rs/pmxcfs-ipc/src/server.rs | 269 ++ src/pmxcfs-rs/pmxcfs-ipc/src/socket.rs | 84 + src/pmxcfs-rs/pmxcfs-ipc/tests/auth_test.rs | 421 +++ .../pmxcfs-ipc/tests/edge_cases_test.rs | 331 ++ .../pmxcfs-ipc/tests/qb_wire_compat.rs | 395 ++ src/pmxcfs-rs/pmxcfs-logger/Cargo.toml | 15 + src/pmxcfs-rs/pmxcfs-logger/README.md | 58 + .../pmxcfs-logger/src/cluster_log.rs | 610 +++ src/pmxcfs-rs/pmxcfs-logger/src/entry.rs | 734 ++++ src/pmxcfs-rs/pmxcfs-logger/src/hash.rs | 129 + src/pmxcfs-rs/pmxcfs-logger/src/lib.rs | 29 + .../pmxcfs-logger/src/ring_buffer.rs | 542 +++ .../tests/binary_compatibility_tests.rs | 611 +++ .../tests/fixtures/gen_fixtures.c | 144 + .../tests/fixtures/multi_entry.bin | Bin 0 -> 131072 bytes .../pmxcfs-logger/tests/fixtures/nonascii.bin | Bin 0 -> 131072 bytes .../tests/fixtures/nonascii.json | 5 + .../pmxcfs-logger/tests/fixtures/overflow.bin | Bin 0 -> 40960 bytes .../tests/fixtures/single_entry.bin | Bin 0 -> 131072 bytes .../tests/fixtures/single_entry.json | 5 + .../pmxcfs-logger/tests/performance_tests.rs | 286 ++ src/pmxcfs-rs/pmxcfs-memdb/Cargo.toml | 42 + src/pmxcfs-rs/pmxcfs-memdb/README.md | 263 ++ src/pmxcfs-rs/pmxcfs-memdb/src/database.rs | 2008 ++++++++++ src/pmxcfs-rs/pmxcfs-memdb/src/index.rs | 579 +++ src/pmxcfs-rs/pmxcfs-memdb/src/lib.rs | 26 + src/pmxcfs-rs/pmxcfs-memdb/src/locks.rs | 315 ++ src/pmxcfs-rs/pmxcfs-memdb/src/sync.rs | 720 ++++ src/pmxcfs-rs/pmxcfs-memdb/src/traits.rs | 102 + src/pmxcfs-rs/pmxcfs-memdb/src/types.rs | 344 ++ src/pmxcfs-rs/pmxcfs-memdb/src/vmlist.rs | 239 ++ .../pmxcfs-memdb/tests/checksum_test.rs | 208 ++ .../pmxcfs-memdb/tests/database_tests.rs | 461 +++ .../tests/sync_integration_tests.rs | 390 ++ src/pmxcfs-rs/pmxcfs-rrd/Cargo.toml | 21 + src/pmxcfs-rs/pmxcfs-rrd/README.md | 119 + src/pmxcfs-rs/pmxcfs-rrd/build.rs | 3 + src/pmxcfs-rs/pmxcfs-rrd/src/backend.rs | 64 + .../pmxcfs-rrd/src/backend/backend_daemon.rs | 157 + .../pmxcfs-rrd/src/backend/backend_direct.rs | 563 +++ .../src/backend/backend_fallback.rs | 246 ++ src/pmxcfs-rs/pmxcfs-rrd/src/key_type.rs | 384 ++ src/pmxcfs-rs/pmxcfs-rrd/src/lib.rs | 25 + src/pmxcfs-rs/pmxcfs-rrd/src/librrd/ffi.rs | 51 + src/pmxcfs-rs/pmxcfs-rrd/src/librrd/mod.rs | 11 + .../pmxcfs-rrd/src/librrd/ops/create.rs | 184 + .../pmxcfs-rrd/src/librrd/ops/mod.rs | 2 + .../pmxcfs-rrd/src/librrd/ops/update.rs | 89 + src/pmxcfs-rs/pmxcfs-rrd/src/parse.rs | 232 ++ .../pmxcfs-rrd/src/rrdcached/LICENSE | 21 + .../pmxcfs-rrd/src/rrdcached/client.rs | 210 ++ .../src/rrdcached/consolidation_function.rs | 42 + .../pmxcfs-rrd/src/rrdcached/create.rs | 411 ++ .../pmxcfs-rrd/src/rrdcached/errors.rs | 29 + src/pmxcfs-rs/pmxcfs-rrd/src/rrdcached/mod.rs | 45 + src/pmxcfs-rs/pmxcfs-rrd/src/rrdcached/now.rs | 18 + .../pmxcfs-rrd/src/rrdcached/parsers.rs | 59 + .../pmxcfs-rrd/src/rrdcached/sanitisation.rs | 95 + src/pmxcfs-rs/pmxcfs-rrd/src/schema.rs | 577 +++ src/pmxcfs-rs/pmxcfs-rrd/src/writer.rs | 591 +++ src/pmxcfs-rs/pmxcfs-services/Cargo.toml | 23 + src/pmxcfs-rs/pmxcfs-services/README.md | 162 + src/pmxcfs-rs/pmxcfs-services/src/error.rs | 21 + src/pmxcfs-rs/pmxcfs-services/src/lib.rs | 15 + src/pmxcfs-rs/pmxcfs-services/src/manager.rs | 322 ++ src/pmxcfs-rs/pmxcfs-services/src/service.rs | 149 + .../pmxcfs-services/tests/service_tests.rs | 1124 ++++++ src/pmxcfs-rs/pmxcfs-status/Cargo.toml | 36 + src/pmxcfs-rs/pmxcfs-status/README.md | 142 + src/pmxcfs-rs/pmxcfs-status/src/lib.rs | 98 + src/pmxcfs-rs/pmxcfs-status/src/status.rs | 1563 ++++++++ src/pmxcfs-rs/pmxcfs-status/src/traits.rs | 475 +++ src/pmxcfs-rs/pmxcfs-status/src/types.rs | 75 + .../pmxcfs-status/tests/status_tests.rs | 426 +++ src/pmxcfs-rs/pmxcfs-test-utils/Cargo.toml | 34 + src/pmxcfs-rs/pmxcfs-test-utils/src/lib.rs | 568 +++ .../pmxcfs-test-utils/src/mock_memdb.rs | 769 ++++ src/pmxcfs-rs/pmxcfs/Cargo.toml | 82 + src/pmxcfs-rs/pmxcfs/README.md | 174 + .../pmxcfs/src/cluster_config_service.rs | 376 ++ src/pmxcfs-rs/pmxcfs/src/daemon.rs | 233 ++ src/pmxcfs-rs/pmxcfs/src/file_lock.rs | 105 + src/pmxcfs-rs/pmxcfs/src/fuse/README.md | 199 + src/pmxcfs-rs/pmxcfs/src/fuse/filesystem.rs | 1505 ++++++++ src/pmxcfs-rs/pmxcfs/src/fuse/mod.rs | 4 + src/pmxcfs-rs/pmxcfs/src/ipc/mod.rs | 16 + src/pmxcfs-rs/pmxcfs/src/ipc/request.rs | 281 ++ src/pmxcfs-rs/pmxcfs/src/ipc/service.rs | 920 +++++ src/pmxcfs-rs/pmxcfs/src/lib.rs | 15 + src/pmxcfs-rs/pmxcfs/src/logging.rs | 44 + src/pmxcfs-rs/pmxcfs/src/main.rs | 761 ++++ src/pmxcfs-rs/pmxcfs/src/memdb_callbacks.rs | 1222 ++++++ src/pmxcfs-rs/pmxcfs/src/path.rs | 45 + src/pmxcfs-rs/pmxcfs/src/plugins/README.md | 203 + .../pmxcfs/src/plugins/clusterlog.rs | 275 ++ src/pmxcfs-rs/pmxcfs/src/plugins/debug.rs | 131 + src/pmxcfs-rs/pmxcfs/src/plugins/members.rs | 146 + src/pmxcfs-rs/pmxcfs/src/plugins/mod.rs | 30 + src/pmxcfs-rs/pmxcfs/src/plugins/registry.rs | 328 ++ src/pmxcfs-rs/pmxcfs/src/plugins/rrd.rs | 97 + src/pmxcfs-rs/pmxcfs/src/plugins/types.rs | 117 + src/pmxcfs-rs/pmxcfs/src/plugins/version.rs | 140 + src/pmxcfs-rs/pmxcfs/src/plugins/vmlist.rs | 120 + src/pmxcfs-rs/pmxcfs/src/quorum_service.rs | 203 + src/pmxcfs-rs/pmxcfs/src/restart_flag.rs | 60 + src/pmxcfs-rs/pmxcfs/src/status_callbacks.rs | 420 +++ src/pmxcfs-rs/pmxcfs/src/status_messages.rs | 211 ++ src/pmxcfs-rs/pmxcfs/tests/fuse_basic_test.rs | 216 ++ .../pmxcfs/tests/fuse_cluster_test.rs | 217 ++ .../pmxcfs/tests/fuse_integration_test.rs | 405 ++ src/pmxcfs-rs/pmxcfs/tests/fuse_locks_test.rs | 375 ++ .../pmxcfs/tests/local_integration.rs | 438 +++ src/pmxcfs-rs/pmxcfs/tests/quorum_behavior.rs | 302 ++ .../pmxcfs/tests/single_node_functional.rs | 357 ++ .../pmxcfs/tests/symlink_quorum_test.rs | 145 + src/pmxcfs-rs/rustfmt.toml | 1 + src/pmxcfs-rs/tests/fuse_basic_test.rs | 229 ++ src/pmxcfs-rs/tests/fuse_cluster_test.rs | 445 +++ src/pmxcfs-rs/tests/fuse_integration_test.rs | 436 +++ src/pmxcfs-rs/tests/fuse_locks_test.rs | 370 ++ src/pmxcfs-rs/tests/local_integration.rs | 151 + src/pmxcfs-rs/tests/quorum_behavior_test.rs | 255 ++ src/pmxcfs-rs/tests/single_node_test.rs | 342 ++ src/pmxcfs-rs/tests/symlink_quorum_test.rs | 157 + src/pmxcfs-rs/tests/two_node_test.rs | 288 ++ src/pmxcfs-rs/vendor/rust-corosync/Cargo.toml | 33 + .../vendor/rust-corosync/Cargo.toml.orig | 19 + src/pmxcfs-rs/vendor/rust-corosync/LICENSE | 21 + .../vendor/rust-corosync/README.PATCH.md | 36 + src/pmxcfs-rs/vendor/rust-corosync/README.md | 13 + src/pmxcfs-rs/vendor/rust-corosync/build.rs | 64 + .../vendor/rust-corosync/regenerate-sys.sh | 15 + src/pmxcfs-rs/vendor/rust-corosync/src/cfg.rs | 391 ++ .../vendor/rust-corosync/src/cmap.rs | 812 ++++ src/pmxcfs-rs/vendor/rust-corosync/src/cpg.rs | 653 ++++ src/pmxcfs-rs/vendor/rust-corosync/src/lib.rs | 280 ++ .../vendor/rust-corosync/src/quorum.rs | 337 ++ .../vendor/rust-corosync/src/sys/cfg.rs | 1239 ++++++ .../vendor/rust-corosync/src/sys/cmap.rs | 3323 +++++++++++++++++ .../vendor/rust-corosync/src/sys/cpg.rs | 1310 +++++++ .../vendor/rust-corosync/src/sys/mod.rs | 8 + .../vendor/rust-corosync/src/sys/quorum.rs | 537 +++ .../rust-corosync/src/sys/votequorum.rs | 574 +++ .../vendor/rust-corosync/src/votequorum.rs | 556 +++ 275 files changed, 70325 insertions(+) create mode 100644 src/pmxcfs-rs/.cargo/config.toml create mode 100644 src/pmxcfs-rs/.gitignore create mode 100644 src/pmxcfs-rs/ARCHITECTURE.txt create mode 100644 src/pmxcfs-rs/Cargo.toml create mode 100644 src/pmxcfs-rs/Makefile create mode 100644 src/pmxcfs-rs/README.md create mode 100644 src/pmxcfs-rs/integration-tests/.gitignore create mode 100644 src/pmxcfs-rs/integration-tests/README.md create mode 100644 src/pmxcfs-rs/integration-tests/docker/.dockerignore create mode 100644 src/pmxcfs-rs/integration-tests/docker/Dockerfile create mode 100644 src/pmxcfs-rs/integration-tests/docker/cluster.env create mode 100644 src/pmxcfs-rs/integration-tests/docker/debian.sources create mode 100644 src/pmxcfs-rs/integration-tests/docker/docker-compose.cluster.yml create mode 100644 src/pmxcfs-rs/integration-tests/docker/docker-compose.mixed.yml create mode 100644 src/pmxcfs-rs/integration-tests/docker/docker-compose.yml create mode 100644 src/pmxcfs-rs/integration-tests/docker/healthcheck.sh create mode 100644 src/pmxcfs-rs/integration-tests/docker/lib/corosync.conf.mixed.template create mode 100644 src/pmxcfs-rs/integration-tests/docker/lib/corosync.conf.template create mode 100755 src/pmxcfs-rs/integration-tests/docker/lib/setup-cluster.sh create mode 100644 src/pmxcfs-rs/integration-tests/docker/mixed.env create mode 100644 src/pmxcfs-rs/integration-tests/docker/network-config.sh create mode 100644 src/pmxcfs-rs/integration-tests/docker/proxmox-archive-keyring.gpg create mode 100644 src/pmxcfs-rs/integration-tests/docker/pve-no-subscription.sources create mode 100755 src/pmxcfs-rs/integration-tests/docker/start-cluster-node.sh create mode 100755 src/pmxcfs-rs/integration-tests/run-tests.sh create mode 100755 src/pmxcfs-rs/integration-tests/test create mode 100755 src/pmxcfs-rs/integration-tests/test-local create mode 100755 src/pmxcfs-rs/integration-tests/tests/cluster/01-connectivity.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/cluster/02-file-sync.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/cluster/03-clusterlog-sync.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/cluster/04-binary-format-sync.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/core/01-test-paths.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/core/02-plugin-version.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/dfsm/01-sync.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/dfsm/02-multi-node.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/fuse/01-operations.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/fuse/02-quorum-permissions.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/fuse/03-write-operations.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/fuse/04-chmod-chown.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/fuse/05-posix-restrictions.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/fuse/06-access-rights.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/fuse/07-vmid-uniqueness.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/01-socket-api.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/02-flow-control.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/03-log-cluster-msg.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/04-get-cluster-log.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/05-get-rrd-dump.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/06-readonly-ops.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/07-write-ops.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/08-guest-config-ops.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/09-all-ipc-ops.sh create mode 100644 src/pmxcfs-rs/integration-tests/tests/ipc/README.md create mode 100644 src/pmxcfs-rs/integration-tests/tests/ipc/perl/IPCTestLib.pm create mode 100644 src/pmxcfs-rs/integration-tests/tests/ipc/perl/README.md create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/get-cluster-info.pl create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/get-cluster-log.pl create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/get-config.pl create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/get-fs-version.pl create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/get-guest-config-properties.pl create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/get-guest-config-property.pl create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/get-guest-list.pl create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/get-rrd-dump.pl create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/get-status.pl create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/log-cluster-msg.pl create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/set-status.pl create mode 100755 src/pmxcfs-rs/integration-tests/tests/ipc/perl/verify-token.pl create mode 100644 src/pmxcfs-rs/integration-tests/tests/ipc/test-lib.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/locks/01-lock-management.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/logger/01-clusterlog-basic.sh create mode 100644 src/pmxcfs-rs/integration-tests/tests/logger/README.md create mode 100755 src/pmxcfs-rs/integration-tests/tests/memdb/01-access.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/01-node-types.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/02-file-sync.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/03-quorum.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/04-c-rust-binary-validation.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/05-merge-correctness.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/06-stress-test.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/07-mtime-sync.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/08-mixed-cluster-rrd-interop.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/09-quorum-gate.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/10-vm-config-sync.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/11-cluster-log-interop.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/12-status-consistency.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/13-node-rejoin-sync.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/mixed-cluster/14-vm-migration-sim.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/plugins/01-plugin-files.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/plugins/02-clusterlog-plugin.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/plugins/03-plugin-write.sh create mode 100644 src/pmxcfs-rs/integration-tests/tests/plugins/README.md create mode 100755 src/pmxcfs-rs/integration-tests/tests/rrd/01-rrd-basic.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/rrd/02-schema-validation.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/rrd/03-rrdcached-integration.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/rrd/05-column-skip-transform.sh create mode 100644 src/pmxcfs-rs/integration-tests/tests/rrd/README-MIXED-CLUSTER-RRD.md create mode 100644 src/pmxcfs-rs/integration-tests/tests/rrd/README.md create mode 100755 src/pmxcfs-rs/integration-tests/tests/run-c-tests.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/status/01-status-tracking.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/status/02-status-operations.sh create mode 100755 src/pmxcfs-rs/integration-tests/tests/status/03-multinode-sync.sh create mode 100644 src/pmxcfs-rs/integration-tests/tests/test-config.sh create mode 100644 src/pmxcfs-rs/pmxcfs-api-types/Cargo.toml create mode 100644 src/pmxcfs-rs/pmxcfs-api-types/README.md create mode 100644 src/pmxcfs-rs/pmxcfs-api-types/src/errno.rs create mode 100644 src/pmxcfs-rs/pmxcfs-api-types/src/error.rs create mode 100644 src/pmxcfs-rs/pmxcfs-api-types/src/lib.rs create mode 100644 src/pmxcfs-rs/pmxcfs-config/Cargo.toml create mode 100644 src/pmxcfs-rs/pmxcfs-config/README.md create mode 100644 src/pmxcfs-rs/pmxcfs-config/src/lib.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/Cargo.toml create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/README.md create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/callbacks.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/cluster_database_service.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/cpg_service.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/dfsm_message.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/fuse_message.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/kv_store_message.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/lib.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/message.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/state_machine.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/status_sync_service.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/types.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/src/wire_format.rs create mode 100644 src/pmxcfs-rs/pmxcfs-dfsm/tests/multi_node_sync_tests.rs create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/Cargo.toml create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/README.md create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/examples/test_server.rs create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/src/connection.rs create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/src/handler.rs create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/src/lib.rs create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/src/protocol.rs create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/src/ringbuffer.rs create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/src/server.rs create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/src/socket.rs create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/tests/auth_test.rs create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/tests/edge_cases_test.rs create mode 100644 src/pmxcfs-rs/pmxcfs-ipc/tests/qb_wire_compat.rs create mode 100644 src/pmxcfs-rs/pmxcfs-logger/Cargo.toml create mode 100644 src/pmxcfs-rs/pmxcfs-logger/README.md create mode 100644 src/pmxcfs-rs/pmxcfs-logger/src/cluster_log.rs create mode 100644 src/pmxcfs-rs/pmxcfs-logger/src/entry.rs create mode 100644 src/pmxcfs-rs/pmxcfs-logger/src/hash.rs create mode 100644 src/pmxcfs-rs/pmxcfs-logger/src/lib.rs create mode 100644 src/pmxcfs-rs/pmxcfs-logger/src/ring_buffer.rs create mode 100644 src/pmxcfs-rs/pmxcfs-logger/tests/binary_compatibility_tests.rs create mode 100644 src/pmxcfs-rs/pmxcfs-logger/tests/fixtures/gen_fixtures.c create mode 100644 src/pmxcfs-rs/pmxcfs-logger/tests/fixtures/multi_entry.bin create mode 100644 src/pmxcfs-rs/pmxcfs-logger/tests/fixtures/nonascii.bin create mode 100644 src/pmxcfs-rs/pmxcfs-logger/tests/fixtures/nonascii.json create mode 100644 src/pmxcfs-rs/pmxcfs-logger/tests/fixtures/overflow.bin create mode 100644 src/pmxcfs-rs/pmxcfs-logger/tests/fixtures/single_entry.bin create mode 100644 src/pmxcfs-rs/pmxcfs-logger/tests/fixtures/single_entry.json create mode 100644 src/pmxcfs-rs/pmxcfs-logger/tests/performance_tests.rs create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/Cargo.toml create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/README.md create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/src/database.rs create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/src/index.rs create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/src/lib.rs create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/src/locks.rs create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/src/sync.rs create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/src/traits.rs create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/src/types.rs create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/src/vmlist.rs create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/tests/checksum_test.rs create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/tests/database_tests.rs create mode 100644 src/pmxcfs-rs/pmxcfs-memdb/tests/sync_integration_tests.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/Cargo.toml create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/README.md create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/build.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/backend.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/backend/backend_daemon.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/backend/backend_direct.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/backend/backend_fallback.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/key_type.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/lib.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/librrd/ffi.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/librrd/mod.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/librrd/ops/create.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/librrd/ops/mod.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/librrd/ops/update.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/parse.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/rrdcached/LICENSE create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/rrdcached/client.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/rrdcached/consolidation_function.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/rrdcached/create.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/rrdcached/errors.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/rrdcached/mod.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/rrdcached/now.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/rrdcached/parsers.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/rrdcached/sanitisation.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/schema.rs create mode 100644 src/pmxcfs-rs/pmxcfs-rrd/src/writer.rs create mode 100644 src/pmxcfs-rs/pmxcfs-services/Cargo.toml create mode 100644 src/pmxcfs-rs/pmxcfs-services/README.md create mode 100644 src/pmxcfs-rs/pmxcfs-services/src/error.rs create mode 100644 src/pmxcfs-rs/pmxcfs-services/src/lib.rs create mode 100644 src/pmxcfs-rs/pmxcfs-services/src/manager.rs create mode 100644 src/pmxcfs-rs/pmxcfs-services/src/service.rs create mode 100644 src/pmxcfs-rs/pmxcfs-services/tests/service_tests.rs create mode 100644 src/pmxcfs-rs/pmxcfs-status/Cargo.toml create mode 100644 src/pmxcfs-rs/pmxcfs-status/README.md create mode 100644 src/pmxcfs-rs/pmxcfs-status/src/lib.rs create mode 100644 src/pmxcfs-rs/pmxcfs-status/src/status.rs create mode 100644 src/pmxcfs-rs/pmxcfs-status/src/traits.rs create mode 100644 src/pmxcfs-rs/pmxcfs-status/src/types.rs create mode 100644 src/pmxcfs-rs/pmxcfs-status/tests/status_tests.rs create mode 100644 src/pmxcfs-rs/pmxcfs-test-utils/Cargo.toml create mode 100644 src/pmxcfs-rs/pmxcfs-test-utils/src/lib.rs create mode 100644 src/pmxcfs-rs/pmxcfs-test-utils/src/mock_memdb.rs create mode 100644 src/pmxcfs-rs/pmxcfs/Cargo.toml create mode 100644 src/pmxcfs-rs/pmxcfs/README.md create mode 100644 src/pmxcfs-rs/pmxcfs/src/cluster_config_service.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/daemon.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/file_lock.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/fuse/README.md create mode 100644 src/pmxcfs-rs/pmxcfs/src/fuse/filesystem.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/fuse/mod.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/ipc/mod.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/ipc/request.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/ipc/service.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/lib.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/logging.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/main.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/memdb_callbacks.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/path.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/plugins/README.md create mode 100644 src/pmxcfs-rs/pmxcfs/src/plugins/clusterlog.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/plugins/debug.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/plugins/members.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/plugins/mod.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/plugins/registry.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/plugins/rrd.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/plugins/types.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/plugins/version.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/plugins/vmlist.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/quorum_service.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/restart_flag.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/status_callbacks.rs create mode 100644 src/pmxcfs-rs/pmxcfs/src/status_messages.rs create mode 100644 src/pmxcfs-rs/pmxcfs/tests/fuse_basic_test.rs create mode 100644 src/pmxcfs-rs/pmxcfs/tests/fuse_cluster_test.rs create mode 100644 src/pmxcfs-rs/pmxcfs/tests/fuse_integration_test.rs create mode 100644 src/pmxcfs-rs/pmxcfs/tests/fuse_locks_test.rs create mode 100644 src/pmxcfs-rs/pmxcfs/tests/local_integration.rs create mode 100644 src/pmxcfs-rs/pmxcfs/tests/quorum_behavior.rs create mode 100644 src/pmxcfs-rs/pmxcfs/tests/single_node_functional.rs create mode 100644 src/pmxcfs-rs/pmxcfs/tests/symlink_quorum_test.rs create mode 100644 src/pmxcfs-rs/rustfmt.toml create mode 100644 src/pmxcfs-rs/tests/fuse_basic_test.rs create mode 100644 src/pmxcfs-rs/tests/fuse_cluster_test.rs create mode 100644 src/pmxcfs-rs/tests/fuse_integration_test.rs create mode 100644 src/pmxcfs-rs/tests/fuse_locks_test.rs create mode 100644 src/pmxcfs-rs/tests/local_integration.rs create mode 100644 src/pmxcfs-rs/tests/quorum_behavior_test.rs create mode 100644 src/pmxcfs-rs/tests/single_node_test.rs create mode 100644 src/pmxcfs-rs/tests/symlink_quorum_test.rs create mode 100644 src/pmxcfs-rs/tests/two_node_test.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/Cargo.toml create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/Cargo.toml.orig create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/LICENSE create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/README.PATCH.md create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/README.md create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/build.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/regenerate-sys.sh create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/cfg.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/cmap.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/cpg.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/lib.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/quorum.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/sys/cfg.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/sys/cmap.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/sys/cpg.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/sys/mod.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/sys/quorum.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/sys/votequorum.rs create mode 100644 src/pmxcfs-rs/vendor/rust-corosync/src/votequorum.rs -- 2.47.3