# Remove a specific table from Zookeeper
kubectl exec -it cometml-production-opik-zookeeper-0 -- \
  zkCli.sh -server localhost:2181 \
  deleteall /clickhouse/tables/0/opik/optimizations
```

## Prevention and Best Practices

To avoid Zookeeper metadata loss issues:

1. **Regular Backups**: Implement regular backups of ClickHouse data. See the [Advanced ClickHouse Backup](/docs/opik/self-host/backup) guide for details.

2. **Monitoring**: Set up monitoring for Zookeeper health and ClickHouse replica status. Alert on `zookeeper_exception` in `system.replicas`.

3. **Resource Allocation**: Ensure Zookeeper has adequate resources (CPU, memory, disk) to maintain metadata reliably.

4. **Persistent Storage**: Use persistent volumes for Zookeeper to prevent data loss during pod restarts.

5. **Replica Validation**: Regularly check replica status with the diagnostic queries above.

## Getting Help

If you continue to experience issues after following this guide:

1. Check the [Opik GitHub Issues](https://github.com/comet-ml/opik/issues) for similar problems
2. Review ClickHouse and Zookeeper logs for additional error details
3. Open a new issue on GitHub with:
   * **Opik versions**:
     * Backend version (opik-backend)
     * Frontend version (opik-frontend)
     * Helm chart version (if deployed via Helm)
   * ClickHouse version
   * Zookeeper version
   * Error logs from all services (ClickHouse, Zookeeper, opik-backend)
   * Steps taken to reproduce the issue