[pbs-devel] [PATCH proxmox-backup] proxmox-tape: use correct api call for 'load-media-from-slot'
Dominik Csapak
d.csapak at proxmox.com
Mon May 23 11:41:16 CEST 2022
it's a 'post' api call, not 'put'
reported here:
https://forum.proxmox.com/threads/lto8.109946/
and here:
https://forum.proxmox.com/threads/cant-clear-tape.86454/
Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
it seems i did not get around to sending that patch a year ago, and i forgot...
src/bin/proxmox-tape.rs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/bin/proxmox-tape.rs b/src/bin/proxmox-tape.rs
index af39556e..94114a6e 100644
--- a/src/bin/proxmox-tape.rs
+++ b/src/bin/proxmox-tape.rs
@@ -292,7 +292,7 @@ async fn load_media_from_slot(mut param: Value) -> Result<(), Error> {
let client = connect_to_localhost()?;
let path = format!("api2/json/tape/drive/{}/load-slot", drive);
- client.put(&path, Some(param)).await?;
+ client.post(&path, Some(param)).await?;
Ok(())
}
--
2.30.2
More information about the pbs-devel
mailing list