# LogDirOfflineException: One or more log directories are offline.

- **ID:** `kafka/log-dir-offline`
- **Domain:** kafka
- **Category:** system_error
- **Verification:** ai_generated
- **Fix Rate:** 70%

## Root Cause

A disk failure or filesystem issue has caused one or more Kafka data directories to become inaccessible, leading to broker unavailability for those partitions.

## Workarounds

1. **Identify the offline directory from broker logs: `grep 'offline' /var/log/kafka/server.log`. Then unmount and check the disk with `fsck`, or replace it. After repair, restart the broker. Example: `sudo umount /data/kafka && sudo fsck -y /dev/sdb1 && sudo mount /data/kafka && kafka-server-start.sh config/server.properties`.** (70% success)
   ```
   Identify the offline directory from broker logs: `grep 'offline' /var/log/kafka/server.log`. Then unmount and check the disk with `fsck`, or replace it. After repair, restart the broker. Example: `sudo umount /data/kafka && sudo fsck -y /dev/sdb1 && sudo mount /data/kafka && kafka-server-start.sh config/server.properties`.
   ```

## Dead Ends

- **** — Simply restarting the broker without addressing the disk failure will cause the same error; the broker will detect the offline directory again. (90% fail)
- **** — Increasing log retention or cleanup policies doesn't fix a hardware failure; the underlying disk must be repaired or replaced. (95% fail)
