Home Assistant installieren
# Auf Proxmox LXC oder VM
# Home Assistant OS (empfohlen) oder Container
# Docker Compose
cat > docker-compose.yml << 'EOF'
services:
homeassistant:
image: homeassistant/home-assistant:stable
container_name: homeassistant
privileged: true
restart: unless-stopped
ports:
- "8123:8123"
volumes:
- ./config:/config
- /etc/localtime:/etc/localtime:ro
network_mode: host # Für lokale Geräte-Discovery
EOF
docker compose up -d
# Web-UI: http://server:8123
Serverraum-Sensoren integrieren
# /config/configuration.yaml
# Temperatur/Luftfeuchtigkeit (MQTT von Sensoren)
mqtt:
sensor:
- name: "Serverraum Temperatur"
state_topic: "serverraum/temperatur"
unit_of_measurement: "°C"
device_class: temperature
value_template: "{{ value_json.temp }}"
- name: "Serverraum Luftfeuchtigkeit"
state_topic: "serverraum/feuchte"
unit_of_measurement: "%"
device_class: humidity
# NUT USV (Network UPS Tools)
sensor:
- platform: nut
host: 192.168.1.200
port: 3493
name: "Serverraum USV"
resources:
- battery.charge
- ups.load
- ups.status
- battery.runtime
# Ping-Check (Server-Erreichbarkeit)
- platform: ping
host: 192.168.1.101
name: "Proxmox Erreichbar"
count: 2
Automatisierungen
# /config/automations.yaml
# Alert wenn Serverraum zu heiß
- alias: "Serverraum Temperatur-Alert"
trigger:
- platform: numeric_state
entity_id: sensor.serverraum_temperatur
above: 28
for:
minutes: 5
action:
- service: notify.mobile_app
data:
title: "Serverraum zu heiß!"
message: "Temperatur: {{ states('sensor.serverraum_temperatur') }}°C"
- service: notify.email
data:
target: [email protected]
title: "Alarm: Serverraum Temperatur"
message: "Aktuell {{ states('sensor.serverraum_temperatur') }}°C"
# USV Strom-Ausfall
- alias: "USV Strom-Ausfall"
trigger:
- platform: state
entity_id: sensor.serverraum_usv_status
to: "OB" # On Battery
action:
- service: notify.mobile_app
data:
title: "Strom-Ausfall!"
message: "Server läuft auf USV. Akku: {{ states('sensor.serverraum_usv_batterie') }}%"
# Nach 5 Minuten: sicheres Herunterfahren
- delay:
minutes: 5
- service: shell_command.shutdown_proxmox
Proxmox-Integration
# custom_components / HACS: proxmox_ve
# configuration.yaml
proxmox:
- host: 192.168.1.101
port: 8006
verify_ssl: false
username: ha@pam
password: hapasswort
realm: pam
nodes:
- node: pve
vms:
- 100 # VM IDs
- 101
- 102
containers:
- 200
- 201
Home Assistant Dashboard
Lovelace Dashboard für Serverraum:
Karten:
- Thermostat: Temperatur + Luftfeuchtigkeit Gauge
- USV: Akkustand, Last, Status, Restlaufzeit
- Server-Status: Ping + Proxmox VM-Status
- Netzwerk: Fritzbox Verbindung, WAN-IP
- Verlaufs-Graph: Temperatur letzte 24h
FAQ
Brauche ich Home Assistant für Serverraum-Monitoring?
Nein, aber es macht Sinn wenn bereits vorhanden. Zabbix/Prometheus sind professioneller. HA ideal wenn man auch Consumer-IoT (Klimaanlage, Heizung) integrieren will.
Fazit
Home Assistant im Serverraum überwacht Umgebungsdaten und USV und reagiert automatisch – Integration mit Smart-Home-Geräten (Klimaanlage) als Bonus.
Serverraum-Automation für KMU in Heidelberg, Mannheim und der Rhein-Neckar-Region. Anfragen.