Launch multiple instances of Ollama Engines

Configure and start first instance on default port

export OLLAMA_HOST="0.0.0.0:11434"

export OLLAMA_KEEP_ALIVE="18h"

export OLLAMA_NUM_PARALLEL="4"

export OLLAMA_CONTEXT_LENGTH="8192" 

ollama serve

Configure and start second instance on another port

export OLLAMA_HOST="0.0.0.0:11435"

export OLLAMA_MODELS="$HOME/.ollama/models-instance-2" 

export OLLAMA_KEEP_ALIVE="10m"

export OLLAMA_NUM_PARALLEL="2"

export OLLAMA_CONTEXT_LENGTH="8192" 

ollama serve

Configure Ollama client pointing to first instance

export OLLAMA_HOST="0.0.0.0:11434"

ollama list 

Configure Ollama client pointing to second instance

export OLLAMA_HOST="0.0.0.0:11435"

ollama list 

 


Comments

Popular posts from this blog

Export/Backup Ollama Model

Download and run Hugging Face AI models in Ollama

Ubuntu (Linux) Desktop using RDP GUI with Windows WSL