Delete a MinIO Tenant
Table of Contents
Prerequisites
MinIO Kubernetes Operator and Plugin
This procedures on this page requires a valid installation of the MinIO Kubernetes Operator and assumes the local host has a matching installation of the MinIO Kubernetes Operator. This procedure assumes the latest stable Operator and Plugin version 5.0.5.
See Deploy the MinIO Operator for complete documentation on deploying the MinIO Operator.
You can install the MinIO plugin using either the Kubernetes Krew plugin manager or manually by downloading and installing the plugin binary to your local host:
Krew is a kubectl
plugin manager developed by the Kubernetes SIG CLI group.
See the krew
installation documentation for specific instructions.
You can use the Krew plugin for Linux, MacOS, and Windows operating systems.
You can use Krew to install the MinIO kubectl
plugin using the following commands:
kubectl krew update
kubectl krew install minio
If you want to update the MinIO plugin with Krew, use the following command:
kubectl krew upgrade minio
You can validate the installation of the MinIO plugin using the following command:
kubectl minio version
The output should match 5.0.5.
You can download the MinIO kubectl
plugin to your local system path.
The kubectl
CLI automatically discovers and runs compatible plugins.
The following code downloads the latest stable version 5.0.5 of the MinIO Kubernetes plugin and installs it to the system path:
curl https://github.com/minio/operator/releases/download/v5.0.5/kubectl-minio_5.0.5_linux_amd64 -o kubectl-minio
chmod +x kubectl-minio
mv kubectl-minio /usr/local/bin/
The mv
command above may require sudo
escalation depending on the permissions of the authenticated user.
Run the following command to verify installation of the plugin:
kubectl minio version
The output should display the Operator version as 5.0.5.
You can download the MinIO kubectl
plugin to your local system path.
The kubectl
CLI automatically discovers and runs compatible plugins.
The following PowerShell command downloads the latest stable version 5.0.5 of the MinIO Kubernetes plugin and installs it to the system path:
Invoke-WebRequest -Uri "https://github.com/minio/operator/releases/download/v5.0.5/kubectl-minio_5.0.5_windows_amd64.exe" -OutFile "C:\kubectl-plugins\kubectl-minio.exe"
Ensure the path to the plugin folder is included in the Windows PATH.
Run the following command to verify installation of the plugin:
kubectl minio version
The output should display the Operator version as 5.0.5.
Procedure (CLI)
Use the kubectl minio tenant delete
command to delete a MinIO Tenant and its associated resources.
The delete behavior of each Persistent Volume Claims (PVC
) generated by the Tenant depends on the Reclaim Policy of its bound Persistent Volume (PV
):
For
recycle
ordelete
policies, the command deletes thePVC
.For
retain
, the command retains thePVC
.
Warning
Deletion of the underlying PV
, whether automatic or manual, results in the loss of any objects stored on the MinIO Tenant.
Perform all due diligence in ensuring the safety of stored data prior to deleting the Tenant.
kubectl minio tenant delete TENANT_NAME \
--namespace TENANT_NAMESPACE
Replace
TENANT_NAME
with the name of the Tenant.Replace
TENANT_NAMESPACE
with the namespace of the Tenant.
The command includes a confirmation prompt that requires explicit approval of the delete operation.