# Quick Fixes für Crumbforest Native Deployment ## Fix 1: Network Error - NGINX Timeouts erhöhen ```bash # Auf dem Server sudo nano /etc/nginx/sites-available/crumbforest-locations.conf # Ändere in der location / Block: proxy_read_timeout 180s; # War: 60s proxy_send_timeout 180s; # War: 60s proxy_connect_timeout 120s; # War: 60s # Speichern und NGINX neu laden sudo nginx -t sudo systemctl reload nginx ``` ## Fix 2: MD Reader - Docs Re-Indexieren ```bash # Auf dem Server - als crumbforest User sudo -u crumbforest /opt/crumbforest/venv/bin/python /opt/crumbforest/app/trigger_reindex.py # Oder manuell Indexing-Service neu starten sudo systemctl restart crumbforest-indexing # Logs checken sudo journalctl -u crumbforest-indexing -f ``` ## Fix 3: Docs Pfad prüfen ```bash # Ist DOCS_PATH richtig gesetzt? sudo grep DOCS_PATH /opt/crumbforest/.env # Existieren die Dateien? ls -la /opt/crumbforest/docs/ # Sind Permissions OK? sudo chown -R crumbforest:crumbforest /opt/crumbforest/docs sudo chmod -R 755 /opt/crumbforest/docs ``` ## Fix 4: Rate Limiting prüfen (falls im Hauptcode) ```bash # Im Hauptcode suchen (nicht in native_crumbcore_v1) grep -r "slowapi\|rate_limit" /opt/crumbforest/app/ # Wenn gefunden, könnte das der Grund sein # Logs zeigen: "Rate limit exceeded" sudo journalctl -u crumbforest -f | grep -i "rate" ``` ## Fix 5: Qdrant Check (falls Embeddings nicht funktionieren) ```bash # Ist Qdrant erreichbar? curl http://localhost:6333/collections # Zeigt alle Collections # Sollte u.a. "docs_crumbforest" enthalten ``` ## Debugging: Live Logs verfolgen ```bash # Terminal 1: FastAPI Logs sudo journalctl -u crumbforest -f # Terminal 2: NGINX Error Logs sudo tail -f /var/log/nginx/crumbforest.error.log # Terminal 3: Indexing Service sudo journalctl -u crumbforest-indexing -f ``` ## Test nach Fixes ```bash # Health Check curl http://localhost:8000/health # Qdrant Collections curl http://localhost:6333/collections # NGINX Status sudo systemctl status nginx # Crumbforest Status sudo systemctl status crumbforest ``` ## Wenn alles fehlschlägt: Full Restart ```bash # Alles neu starten sudo systemctl restart crumbforest-indexing sudo systemctl restart crumbforest sudo systemctl reload nginx # 10 Sekunden warten, dann testen sleep 10 curl http://localhost:8000/health ```