Milvus Standalone Installation
In this article
Milvus standalone installation using Docker compose
Install docker compose using the below command:
curl -SL https://github.com/docker/compose/releases/download/v2.26.0/docker-compose-linux-x86_64 -o /usr/local/bin/docker-compose
sudo ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose
Download the YAML file
Download milvus-standalone-docker-compose.yml and save it as docker-compose.yml manually, or with the following command.
wget https://github.com/milvus-io/milvus/releases/download/v2.3.12/milvus-standalone-docker-compose.yml -O docker-compose.yml
Start Milvus
In the directory that holds docker-compose.yml, start Milvus by running the below command:
sudo docker compose up -d
Verify the Installation
Now check if the containers are up and running.
sudo docker compose ps
After Milvus standalone starts, there will be three docker containers running, including the Milvus standalone service and its two dependencies.
Connect to milvus cli using docker
docker run -it zilliz/milvus_cli:latest
Milvus standalone installation using RPM
Install Milvus with yum on RedHat9
sudo yum install -y https://github.com/milvus-io/milvus/releases/download/v2.3.12/milvus-2.3.12-1.el9.x86_64.rpm
sudo systemctl restart milvus
sudo systemctl status milvus
sudo systemctl enable milvus
Connect to milvus using python3
Install pymilvus package
pip3 install pymilvus==2.3.1
python3 connected:
from pymilvus import connections
connections.connect(
alias="default",
host='172.**.**.8',
port='19530'
)
Milvus standalone SSL installation using RPM
Install Milvus with yum on RedHat9.
sudo yum install -y https://github.com/milvus-io/milvus/releases/download/v2.3.12/milvus-2.3.12-1.el9.x86_64.rpm
vi /etc/milvus/configs/milvus.yaml
tls:
serverPemPath: /etc/ssl/certs/sa-certs/my_key_store.crt
serverKeyPath: /etc/ssl/certs/sa-certs/my_store.key
caPemPath: /etc/ssl/certs/sa-certs/gathr_impetus_com.pem
security:
tlsMode: 2
sudo systemctl restart milvus
sudo systemctl status milvus
sudo systemctl enable milvus
Connect to milvus using python3
pip3 install pymilvus==2.3.1
python3
from pymilvus import connections
_HOST = '10.80.**.***'
_PORT = '19530'
print(f"\nCreate connection...")
connections.connect(host=_HOST, port=_PORT, secure=True, client_pem_path="/etc/ssl/certs/sa-certs/my_key_store.crt",
client_key_path="/etc/ssl/certs/sa-certs/my_store.key",
ca_pem_path="/etc/ssl/certs/sa-certs/gathr_impetus_com.pem", server_name="10.80.**.***")
print(f"\nList connections:")
print(connections.list_connections())
If you have any feedback on Gathr documentation, please email us!