[pbs-devel] [PATCH proxmox-backup 05/23] api2: admin: add (un)mount endpoint for removable datastores
Lukas Wagner
l.wagner at proxmox.com
Tue Sep 19 15:38:03 CEST 2023
On 9/15/23 08:54, Hannes Laimer wrote:
> +pub fn do_mount_device(
> + datastore.set_maintenance_mode(None);
I think this overrides existing maintenance modes... e.g. if a datastore
is 'read-only', unmounted and mounted again, then the 'read-only' mode
will be gone.
> + config.set_data(&datastore.name, "datastore", &datastore)?;
> + pbs_config::datastore::save_config(&config)?;
> +
> + Ok(())
> + } else {
> + Err(format_err!(
> + "Datastore '{}' can't be mounted because it is not removable.",
> + &datastore.name
> + ))
> + }
> +}
> +
--
- Lukas
More information about the pbs-devel
mailing list