From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id 26C9199E6D for ; Thu, 4 May 2023 10:24:53 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 129FA1B54A for ; Thu, 4 May 2023 10:24:53 +0200 (CEST) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS for ; Thu, 4 May 2023 10:24:52 +0200 (CEST) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 115B547285 for ; Thu, 4 May 2023 10:24:52 +0200 (CEST) Date: Thu, 04 May 2023 10:24:45 +0200 From: Fabian =?iso-8859-1?q?Gr=FCnbichler?= To: Proxmox VE development discussion References: <20230425102136.85334-1-m.frank@proxmox.com> In-Reply-To: <20230425102136.85334-1-m.frank@proxmox.com> MIME-Version: 1.0 User-Agent: astroid/0.16.0 (https://github.com/astroidmail/astroid) Message-Id: <1683186259.i7tt6b4fva.astroid@yuna.none> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-SPAM-LEVEL: Spam detection results: 0 AWL 0.075 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 T_SCC_BODY_TEXT_LINE -0.01 - Subject: Re: [pve-devel] [PATCH docs v4 0/6] feature #1027 virtio-9p/virtio-fs X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 May 2023 08:24:53 -0000 thanks for working on this! it's a long-standing feature request and implementing it will make quite a few people happy. also sorry for not getting back at you in v2/3 already. there's some high level stuff that I'll reply with here, and then some more concrete feedback on individual patches. there is some overlap (well, not so much atm, but I think there should be more ;)) with Dominik's hardware map, so it might make sense to coordinate.=20 On April 25, 2023 12:21 pm, Markus Frank wrote: > pve-docs: >=20 > Markus Frank (1): > added shared filesystem doc for virtio-fs & virtio-9p >=20 > qm.adoc | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ > 1 file changed, 61 insertions(+) >=20 >=20 > pve-access-control: >=20 > v3: > * replaced /dirs with /map/dirs/ >=20 > v2: > * admin gives access via an ACL (/dirs/) >=20 > Markus Frank (1): > added acls for Shared Files Directories >=20 > src/PVE/API2/Directory.pm | 68 +++++++++++++++++++++++++++++++++++++++ > src/PVE/AccessControl.pm | 16 +++++++++ > src/PVE/RPCEnvironment.pm | 12 ++++++- > 3 files changed, 95 insertions(+), 1 deletion(-) > create mode 100644 src/PVE/API2/Directory.pm >=20 >=20 > pve-manager: >=20 > v4: > * moved extract_dir_path from qemu-server to DirConfig in pve-manager >=20 > v2: > * admins define dirs on the host that are eligibly for mounting into=20 > guests (: /path/tp/share) I think pve-manager is the wrong place for this. the module hierarchy is pve-manager - qemu-server/pve-container - pve-guest-common - pve-storage - = pve-access-control - pve-common (things to the right can use things to the left, but not the other way roun= d) there are only two places where we have intentional cycles: pve-firewall <-> qemu-server/pve-container ha-manager <-> qemu-server/pve-container (and the doc generator, but that can be worked around and is not at runtime ;)) so something like this, which needs to be used by both qemu-server and, in the future, pve-container needs to go into one of the following: - pve-guest-common - pve-storage - pve-common common is out, as that sits below pve-cluster and pve-access-control. that leaves either pve-guest-common or pve-storage. you must not introduce code in pve-manager (like PVE::DirConfig) that is needed in qemu-server. besides this question of moving, in my mind, the following would be much nicer: - define dir entities cluster-wide (like storages) -- id -- optional default host path -- ? - allow limiting and overriding per node (so that dir "foo" can be backed by a path "/X" on one node, path "/Y" on another, and not be available at all on a third node) - the only downside is editing requires a cluster-wide lock, but that is something that is not done frequently so it doesn't really hurt. ideally this would follow the same scheme as the hardware map, since it has quite similar semantics. I am not sure if we want to put it into the hardware map, but it might be an option as well (it is kinda of passing through a host dir, like passing through an USB or PCI device after all). having it in the hardware map would possibly allow a common set of helpers (like for finding out whether a given dir is available on a node, and getting the correct config, or for ACL checks). > Markus Frank (3): > added Config for Shared Filesystem Directories > added Shared Files tab in Node Settings > added options to add virtio-9p & virtio-fs Shared Filesystems to qemu > config >=20 > PVE/API2/DirConfig.pm | 129 +++++++++++++++++++ > PVE/API2/Makefile | 1 + > PVE/API2/Nodes.pm | 6 + > PVE/DirConfig.pm | 155 +++++++++++++++++++++++ > PVE/Makefile | 1 + > www/manager6/Makefile | 2 + > www/manager6/Utils.js | 1 + > www/manager6/data/PermPathStore.js | 3 + > www/manager6/node/Config.js | 12 ++ > www/manager6/node/SharedFiles.js | 177 +++++++++++++++++++++++++++ > www/manager6/qemu/HardwareView.js | 19 +++ > www/manager6/qemu/SharedFilesEdit.js | 101 +++++++++++++++ > 12 files changed, 607 insertions(+) > create mode 100644 PVE/API2/DirConfig.pm > create mode 100644 PVE/DirConfig.pm > create mode 100644 www/manager6/node/SharedFiles.js > create mode 100644 www/manager6/qemu/SharedFilesEdit.js >=20 >=20 > qemu-server: >=20 > v4: > * moved extract_dir_path from qemu-server to DirConfig >=20 > v3: > * created own socket and get file descriptor for virtiofsd > so there is no race between starting virtiofsd & qemu > * added TODO to replace virtiofsd with rust implementation in bookworm > (I packaged the rust implementation for bookworm & the C implementation > in qemu will be removed in qemu 8.0) >=20 > v2: > * replaced sharedfiles_fmt path in qemu-server with dirid: > * user can use the dirid to specify the directory without requiring root= access >=20 > Markus Frank (1): > feature #1027: virtio-9p & virtio-fs support >=20 > PVE/API2/Qemu.pm | 19 +++++++ > PVE/QemuServer.pm | 141 ++++++++++++++++++++++++++++++++++++++++++++++ > 2 files changed, 160 insertions(+) >=20 > --=20 > 2.30.2 >=20 >=20 >=20 > _______________________________________________ > pve-devel mailing list > pve-devel@lists.proxmox.com > https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel >=20 >=20 >=20