2021-08-10 11:41:27 +08:00
# Milvus offline installation
## Manually downloading Docker images
2021-09-24 12:07:54 +08:00
Your Milvus installation may fail when images are not properly loaded from public Docker registries. To pull all images and save them into a directory that can be moved to the target host and loaded manually, perform the following procedures:
2021-08-10 11:41:27 +08:00
2021-09-10 14:17:23 +08:00
### Step 1: Save Milvus manifest and Docker images
#### If you install your Milvus with the **docker-compose.yml** file, use these command:
1. Download Milvus standalone docker-compose.yml
```shell
wget https://raw.githubusercontent.com/milvus-io/milvus/master/deployments/docker/standalone/docker-compose.yml -O docker-compose.yml
```
or download Milvus cluster docker-compose.yml
```shell
wget https://raw.githubusercontent.com/milvus-io/milvus/master/deployments/docker/cluster/docker-compose.yml -O docker-compose.yml
```
2. Pull and save Docker images
```shell
pip3 install -r requirements.txt
python3 save_image.py --manifest docker-compose.yml
```
#### If you install your Milvus with **Helm**, use these command:
1. Update Helm repo
```shell
helm repo add milvus https://milvus-io.github.io/milvus-helm/
helm repo update
```
2. Get Kubernetes manifest of Milvus standalone
```shell
helm template my-release milvus/milvus > milvus_manifest.yaml
```
or get Kubernetes manifest of Milvus cluster
```shell
helm template --set cluster.enabled=true my-release milvus/milvus > milvus_manifest.yaml
```
3. Pull and save Docker images
```shell
pip3 install -r requirements.txt
python3 save_image.py --manifest milvus_manifest.yaml
```
2021-08-10 11:41:27 +08:00
The Docker images will be stored under **images** directory.
2021-09-24 18:59:55 +08:00
### Step 2: Load Docker images
2021-09-10 14:17:23 +08:00
Enter the following command to load the Docker images:
2021-08-10 11:41:27 +08:00
```shell
2021-08-10 13:57:27 +08:00
cd images/
for image in $(find . -type f -name "*.tar.gz") ; do gunzip -c $image | docker load; done
2021-08-10 11:41:27 +08:00
```
## Install Milvus
- Install Milvus with Docker Compose
```shell
2021-08-10 16:59:27 +08:00
docker-compose -f docker-compose.yml up -d
2021-08-10 11:41:27 +08:00
```
- Install Milvus on Kubernetes
```shell
kubectl apply -f milvus_manifest.yaml
2021-08-10 13:57:27 +08:00
```
## Uninstall Milvus
- Uninstall Milvus with Docker Compose
```shell
2021-08-10 16:59:27 +08:00
docker-compose -f docker-compose.yml down
2021-08-10 13:57:27 +08:00
```
- Uninstall Milvus on Kubernetes
```shell
kubectl delete -f milvus_manifest.yaml
2021-09-10 14:17:23 +08:00
```