Compare commits

..

8 Commits

Author SHA1 Message Date
6af7c7e720 vault backup: 2026-03-26 00:09:55
Affected files:
2 Personal/Lists/Business Ideas.md
2026-03-26 00:09:55 +01:00
e56528b7b3 vault backup: 2026-03-25 23:46:41
Affected files:
.obsidian/workspace.json
0 Journal/0 Daily/2026-03-20.md
2026-03-25 23:46:42 +01:00
1ed975513a vault backup: 2026-03-18 20:02:56
Affected files:
.obsidian/workspace.json
.obsidian_iphone/workspace-mobile.json
0 Journal/0 Daily/2026-03-18.md
2026-03-18 20:02:56 +01:00
5a426919d7 vault backup: 2026-03-17 16:15:43
Affected files:
.obsidian/workspace.json
2 Personal/Home Lab/Baerhalten/Home Assistant.md
Attachments/ESPSomfyRTS 2026-03-17T16_05_06.backup
2026-03-17 16:15:43 +01:00
232b4b9f32 vault backup: 2026-03-17 15:03:57
Affected files:
.obsidian/workspace.json
2 Personal/Home Lab/Baerhalten/Home Assistant -> InfluxDB -> Grafana setup and debugging notes.md
2 Personal/Home Lab/Baerhalten/Home Assistant.md
2026-03-17 15:03:57 +01:00
4482f6921e vault backup: 2026-03-17 13:29:38
Affected files:
2 Personal/Home Lab/Baerhalten/Home Assistant.md
2026-03-17 13:29:38 +01:00
34a3dc17b2 vault backup: 2026-03-17 12:50:12
Affected files:
.obsidian/workspace.json
2 Personal/Home Lab/Baerhalten/Home Assistant.md
2026-03-17 12:50:12 +01:00
dd8e2ff9d5 vault backup: 2026-03-17 12:37:47
Affected files:
.obsidian/workspace.json
.obsidian_iphone/plugins/obsidian-spaced-repetition/data.json
.obsidian_iphone/workspace-mobile.json
2026-03-17 12:37:47 +01:00
9 changed files with 526 additions and 30 deletions

View File

@@ -91,20 +91,6 @@
"title": "2026-01-07"
}
},
{
"id": "b948e87b03ca1ad1",
"type": "leaf",
"state": {
"type": "markdown",
"state": {
"file": "2 Personal/Home Lab/Baerhalten/Home Assistant.md",
"mode": "source",
"source": false
},
"icon": "lucide-file",
"title": "Home Assistant"
}
},
{
"id": "f33efed5601c1085",
"type": "leaf",
@@ -161,6 +147,20 @@
"title": "Business Ideas"
}
},
{
"id": "b948e87b03ca1ad1",
"type": "leaf",
"state": {
"type": "markdown",
"state": {
"file": "2 Personal/Home Lab/Baerhalten/Home Assistant.md",
"mode": "source",
"source": false
},
"icon": "lucide-file",
"title": "Home Assistant"
}
},
{
"id": "fac43a56fe618e9d",
"type": "leaf",
@@ -176,7 +176,7 @@
}
}
],
"currentTab": 10
"currentTab": 6
}
],
"direction": "vertical"
@@ -403,8 +403,7 @@
"vantage-obsidian:Vantage - Advanced search builder": false,
"templater-obsidian:Templater": false,
"obsidian-git:Open Git source control": false,
"markdown-importer:Open format converter": false,
"periodic-notes:Open today": false
"markdown-importer:Open format converter": false
}
},
"floating": {
@@ -481,7 +480,7 @@
],
"direction": "vertical",
"x": 0,
"y": 42,
"y": 57,
"width": 900,
"height": 777,
"maximize": false,
@@ -489,9 +488,14 @@
}
]
},
"active": "6914f148f736c4ac",
"active": "45138afa5cf89635",
"lastOpenFiles": [
"2 Personal/Home Lab/Homelab.md",
"2 Personal/Home Lab/NextiShareBot.md",
"0 Journal/0 Daily/2026-03-18.md",
"2 Personal/Home Lab/Baerhalten/Home Assistant.md",
"Attachments/ESPSomfyRTS 2026-03-17T16_05_06.backup",
"2 Personal/Home Lab/Baerhalten/Home Assistant -> InfluxDB -> Grafana setup and debugging notes.md",
"2 Personal/Lists/Business Ideas.md",
"0 Journal/0 Daily/2026-01-29.md",
"Temporary/Untitled 4.md",
@@ -514,12 +518,8 @@
"Temporary/Material Damping.md",
"Temporary/Friction Damping.md",
"Attachments/Pasted image 20260121121234.png",
"2 Personal/Home Lab/Homelab.md",
"2 Personal/Home Lab/Baerhalten/Home Assistant.md",
"2 Personal/Lists/Media/Bücher.md",
"Attachments/ESPSomfyRTS 2026-01-18T16_26_16.backup",
"Attachments/Pasted image 20260118150817.png",
"Temporary/Untitled 3.md",
"Attachments/Pasted image 20251202214228.png",
"2 Personal/1 Skills/AI",
"2 Personal/Home Lab/Baerhalten",
@@ -535,7 +535,6 @@
"99 Work/0 OneSec/OneSecNotes/10 Projects/TeensyFlightcontroller",
"Attachments/Pasted image 20250922115441.png",
"7 People/0_People.base",
"Attachments/Belts, Suspenders.mp3",
"Attachments/image 21.jpg",
"Dashboard Canvas.canvas",
"99 Work/0 OneSec/OneSecNotes/30 Engineering Skills/Computer Science/Untitled.canvas",

View File

@@ -47,7 +47,7 @@
"maxLinkFactor": 1,
"showDebugMessages": false
},
"buryDate": "2026-03-05",
"buryDate": "2026-03-16",
"buryList": [],
"historyDeck": null
}

View File

@@ -1848,8 +1848,18 @@
"state": {
"type": "review-queue-list-view",
"state": {},
"icon": "SpacedRepIcon",
"title": "Notes Review Queue"
"icon": "lucide-ghost",
"title": "review-queue-list-view"
}
},
{
"id": "c2f4ad24032ae4c0",
"type": "leaf",
"state": {
"type": "review-queue-list-view",
"state": {},
"icon": "lucide-ghost",
"title": "review-queue-list-view"
}
}
],
@@ -1867,11 +1877,10 @@
"table-editor-obsidian:Advanced Tables Toolbar": false,
"obsidian-spaced-repetition:Review flashcards": false,
"omnisearch:Omnisearch": false,
"templater-obsidian:Templater": false,
"periodic-notes:Open today": false
"templater-obsidian:Templater": false
}
},
"active": "992ba06a004d0d26",
"active": "c2f4ad24032ae4c0",
"lastOpenFiles": [
"0 Journal/0 Daily/2026-02-08.md",
"99 Work/Jobhunt/OneSec Experience on LinkedIn.md",

View File

@@ -0,0 +1,28 @@
---
aliases:
Tags:
- daily
day_grade:
Dehnen:
Sport:
Ernährung:
---
# 2026-03-18
[[2026-03-17]] <--> [[2026-03-19]]
> [!quote] Real success is finding your lifework in the work that you love.
> — David McCullough
---
## Planning
___
## Reflection
___
## Notes
-

View File

@@ -0,0 +1,27 @@
---
aliases:
Tags:
- daily
day_grade:
Dehnen:
Sport:
Ernährung:
---
# <%tp.file.title%>
[[<%tp.date.now("YYYY-MM-DD",-1)%>]] <--> [[<%tp.date.now("YYYY-MM-DD",+1)%>]]
<%tp.web.daily_quote()%>
---
## Planning
___
## Reflection
___
## Notes
-

View File

@@ -0,0 +1,400 @@
---
title: Home Assistant -> InfluxDB -> Grafana setup and debugging notes
created_date: 2026-03-17
updated_date: 2026-03-17
aliases:
tags:
---
# Home Assistant -> InfluxDB -> Grafana setup and debugging notes
## Architecture
This setup has **three layers**:
1. **Home Assistant** generates state changes and sensor values.
2. **InfluxDB 3 Core** stores that time-series data.
3. **Grafana** reads from InfluxDB and visualizes it.
### Network layout
- **Home Assistant** runs outside the Docker Compose network.
- **InfluxDB** and **Grafana** run together in the same Docker Compose stack.
- Therefore:
- **Home Assistant -> InfluxDB** must use the **Proxmox container IP** and exposed port.
- **Grafana -> InfluxDB** should use the **Docker service name**.
## Actual endpoints
### Home Assistant -> InfluxDB
Home Assistant should connect to InfluxDB using:
- Protocol: `http`
- Host / URL: `192.168.194.120`
- Port: `8181`
- SSL verification: off
Reason: Home Assistant is outside the Docker network, so it cannot resolve `influxdb3`.
### Grafana -> InfluxDB
Grafana should connect to InfluxDB using:
- URL: `http://influxdb3:8181`
Reason: Grafana and InfluxDB are on the same Docker Compose network, so Docker DNS resolves `influxdb3`.
## Docker Compose setup
The relevant Compose structure is:
```yaml
services:
influxdb3:
image: influxdb:3-core
ports:
- "8181:8181"
grafana:
image: grafana/grafana:latest
depends_on:
- influxdb3
ports:
- "3000:3000"
```
This means:
- InfluxDB is reachable from outside Docker at `http://<proxmox-container-ip>:8181`
- InfluxDB is reachable from Grafana internally at `http://influxdb3:8181`
## Home Assistant InfluxDB configuration
### Important migration detail
Home Assistant is removing YAML-based InfluxDB **connection settings**.
So these connection keys should **not** stay in YAML:
- `api_version`
- `host`
- `port`
- `ssl`
- `verify_ssl`
- `ssl_ca_cert`
- `username`
- `password`
- `database`
- `token`
- `organization`
- `bucket`
- `path`
Those should be configured through **Devices & Services** in the Home Assistant UI.
### What can still stay in YAML
Behavior/settings like these can still stay in YAML:
- `measurement_attr`
- `default_measurement`
- `override_measurement`
- `include`
- `exclude`
- `tags`
- `tags_attributes`
## Final Home Assistant behavior setting
To get **one table per entity/sensor**, the key YAML setting is:
```yaml
influxdb:
measurement_attr: entity_id
```
Reason:
- Default behavior grouped data into tables like `W`, `Wh`, `V`, `%`
- That made many sensors appear "missing", because they were grouped by unit
- `measurement_attr: entity_id` changes that back to one measurement/table per entity, which is easier to use in Grafana
## InfluxDB concepts in this setup
### Databases
We used databases such as:
- `home`
- `homeassistant`
- `ha_fresh`
These are databases, not tables.
### Tables / measurements
Inside a database, tables are created automatically when data is written.
Examples after using `measurement_attr: entity_id`:
- `sensor.solarnet_power_photovoltaics`
- `sensor.solarnet_power_grid_export`
- `sensor.solarnet_power_load_consumed`
Examples from the old grouped schema:
- `W`
- `Wh`
- `V`
- `A`
## Tokens and authentication
### What is used where
- **Home Assistant** uses an InfluxDB token to write data
- **Grafana** uses an InfluxDB token to query data
- **Admin token** is used for CLI/database management
### Important note
Tokens and secrets that were exposed should be rotated.
## How we debugged the setup
## 1. Verified InfluxDB is running
We checked Docker:
```bash
docker ps
docker logs --since 0.5m influxdb3
```
This confirmed:
- Grafana container is running
- InfluxDB container is running
- InfluxDB is actively flushing writes
## 2. Verified databases exist
```bash
docker exec -it influxdb3 influxdb3 show databases --token "$INFLUX_ADMIN_TOKEN"
```
This showed databases like:
- `_internal`
- `home`
- `homeassistant`
- later `ha_fresh`
## 3. Verified Home Assistant can reach InfluxDB over the network
From Home Assistant shell:
```bash
curl http://192.168.194.120:8181/health
```
Response:
```text
{"error": "the request was not authenticated"}
```
This was **good** because it proved:
- DNS/IP was correct
- network path worked
- InfluxDB was reachable
- only authentication remained
## 4. Reconfigured Home Assistant in the UI
Home Assistant InfluxDB integration was configured in **Devices & Services** using:
- HTTP
- host/IP of Proxmox container
- port `8181`
- no SSL verification
- organization `dummy`
- bucket/database `ha_fresh` or similar
- token
## 5. Enabled debug logs in Home Assistant
We confirmed HA was writing by seeing log lines like:
```text
Wrote 8 events.
Wrote 10 events.
```
That proved:
- Home Assistant -> InfluxDB write path works
## 6. Verified writes actually landed in InfluxDB
We queried InfluxDB directly:
```bash
docker exec -it influxdb3 influxdb3 query --database ha_fresh --token "$INFLUX_ADMIN_TOKEN" 'SELECT * FROM "W" ORDER BY time DESC LIMIT 20'
```
This showed fresh rows from Home Assistant sensors, including:
- `pv_power`
- `solarnet_power_photovoltaics`
- `solarnet_power_load_consumed`
- `solarnet_power_grid_export`
That proved:
- Home Assistant -> InfluxDB works fully
- the issue was not ingestion
- the issue was schema / Grafana config
## 7. Verified Grafana container can reach InfluxDB
From inside the Grafana container, we tested:
```bash
curl -i http://influxdb3:8181/api/v3/query_sql -H "Authorization: Token YOUR_GRAFANA_TOKEN" -H "Content-Type: application/json" --data '{"db":"home","q":"SHOW TABLES"}'
```
This working proved:
- Docker networking is fine
- `influxdb3` resolves correctly
- Grafana-side token auth works
- the remaining problem was purely Grafana datasource configuration
## 8. Fixed Grafana datasource setup
### Correct Grafana datasource basics
- Query language: **SQL** or the desired mode
- URL: `http://influxdb3:8181`
- Database: the actual InfluxDB database in use
- Token: Grafana token
### Important TLS issue
Grafana originally failed with an error like:
```text
tls: first record does not look like a TLS handshake
```
That happened because Grafana tried TLS/FlightSQL behavior against a plain HTTP endpoint.
Fix:
- use the correct datasource mode
- use the right endpoint
- keep the connection consistent with the actual InfluxDB setup
## 9. Realized the schema had changed
Old schema assumption:
- one table per sensor
New schema that appeared initially:
- one table per **unit**, like `W`, `Wh`, `V`
That is why old queries stopped working.
Example old query:
```sql
SELECT mean("value")
FROM "sensor.solarnet_power_photovoltaics"
WHERE $timeFilter
GROUP BY time(5m) fill(none)
```
Equivalent query in the grouped-by-unit schema:
```sql
SELECT mean("value")
FROM "W"
WHERE
"entity_id" = 'solarnet_power_photovoltaics'
AND $timeFilter
GROUP BY time(5m) fill(none)
```
Then we changed HA back to per-entity measurements using:
```yaml
influxdb:
measurement_attr: entity_id
```
## 10. Reset the fresh database to keep it clean
After confirming the new schema worked, the goal was to keep only actually-used tables in the fresh DB.
General approach:
- delete or recreate `ha_fresh`
- reconnect HA to it
- let HA repopulate it with only actively written entities
That leaves a clean database without old junk.
## Final recommended setup
## Home Assistant
- Configure InfluxDB connection in the UI
- Keep only behavior options in YAML
- Use:
```yaml
influxdb:
measurement_attr: entity_id
```
if per-entity tables are desired
## InfluxDB
- Keep one clean database for HA data
- Use separate tokens for:
- admin
- Home Assistant
- Grafana
## Grafana
- Use datasource URL:
```text
http://influxdb3:8181
```
- Point it to the correct InfluxDB database
- Use the Grafana token
- Rebuild old queries if schema changed
## Quick troubleshooting checklist for the future
### If HA is not writing
1. Check HA logs for InfluxDB errors
2. Test connectivity from HA:
```bash
curl http://<influx-ip>:8181/health
```
3. Verify token / database / organization / bucket in HA UI
4. Query InfluxDB directly to see whether data is arriving
### If Grafana shows nothing
1. Verify datasource URL is `http://influxdb3:8181`
2. Test token from inside Grafana container
3. Confirm the right database is selected
4. Check whether schema is per-entity or grouped-by-unit
5. Rewrite queries accordingly
### If sensors seem missing
1. Check `SHOW TABLES`
2. Query likely shared tables like `W`, `Wh`, `V`
3. Check whether HA is grouping by unit instead of entity
4. Set:
```yaml
influxdb:
measurement_attr: entity_id
```
if one table per sensor is preferred

View File

@@ -28,9 +28,14 @@ can this be good:
[GitHub - jomjol/AI-on-the-edge-device: Easy to use device for connecting "old" measuring units (water, power, gas, ...) to the digital world](https://github.com/jomjol/AI-on-the-edge-device?tab=readme-ov-file#setup-%EF%B8%8F)
## Somfy
I used this tutorial: [Somfy Smart DIY \| Make Shades Smart With ESPSomfy-RTS - YouTube](https://www.youtube.com/watch?v=1acVJ0xWJgs)
The open memory function doesn't work (the auto button). For groups I just used the prog button on the back of the remote after clicking the open memory button and waiting (which doesn't do anything).
![[Pasted image 20260118150817.png]]
Backup:
![[ESPSomfyRTS 2026-01-18T16_26_16.backup]]
![[ESPSomfyRTS 2026-03-17T16_05_06.backup]]
### Home Assitant Integration
Followed this Video: [ESPSomfy Integration with Home Assistant - YouTube](https://www.youtube.com/watch?v=ikrQwPYGyeg&t=14s)
@@ -53,5 +58,14 @@ DB: homeassistant
user: homeassistant
pw: VYWPQuR5UWkqMNU
I put the tokens into chat gpt so they might be compromised. all Influx tokens (admin, grafana and homeassistant), Oauth client secret and Id (grafana)
### Tutorials
[INSANE STATISTICS In Home Assistant With Grafana! - TUTORIAL - YouTube](https://www.youtube.com/watch?v=rXF-LycbjoA)
## Backup
Ich hab ein Back-up User kreiert und einen geteilten Ordner auf der Nase bei meinen Eltern zu Hause. Home Assistant macht jeden Tag ein automatisches Back-up und behält dabei fünf Back-ups in Rotation. Die Verschlüsselung Schlüssel sind in meinem Lastpass.

View File

@@ -60,6 +60,8 @@ Diese Liste kann auch mit `#idea/startup` oder mit `#business-idea` ergänzt wer
- course website (maybe like aihero.dev?) but for apprenticeships: woodworking, metalworking, etc. when AI replaces all pc jobs people need something to do. --> create marketplace for teaching. Yes people can watch everything on youtube, but lets say here in switzerland you have a local youtuber that can easily organize workshops and book private lessons. --> much more personal.
- gamification of sofware development through agents[[]]
- CV curator: have a layout, have many bullets as master. Depending on the role select whatever bullets you want.
- Scuba dive: risk analysis of your dives. get direct feedback of your previous dive (red, orange or green smiley). Better planning tool for DCS (talked with [[Lukas Glaus]], he has a physics friend who is an absolute killer). Immediate suggestions on how to improve dive profile to reduce risk. Simple app good UI
- Skitouring app with crowd intelligence: upload pictures of conditions with geo data. Feedback system: feedback risk level of past tours given the avalanche risk and the route chosen (reduktions-methode)
## Medtech
- use differential cameras to visualize airflow to teach deaf people how the airflow is when speaking to learn it properly

View File

@@ -0,0 +1,17 @@
24, 76, 29, 2, 276, 7, 200, 3, 77, 1, 98, 170, 74,2DD6D8
1,kueche , 1
2,wohnzimmer , 2
1,true , 1, 450761,top-links , 2, 0, 80, 58800, 57000, 2800, 46, 16597248, 82432, 0, 0, 0, 0, 0, 115, 0, 20.00000, 10.00000, 34.00000, 50.00000,false,false, 0, 1, 0, 0, 0, 0, 2
2,true , 1, 953570,top rechts , 2, 0, 80, 58200, 57000, 2800, 1, 16662784, 11904159, 0, 0, 0, 0, 0, 34, 0, -1.00000, -1.00000, 45.00000, 50.00000,false,false, 0, 2, 0, 0, 0, 0, 2
3,true , 1, 953571,unten links , 2, 0, 80, 58200, 57000, 2800, 1, 16728320, 82432, 0, 0, 0, 0, 0, 17, 0, -1.00000, -1.00000, 34.00000, 50.00000,false,false, 0, 3, 0, 0, 0, 0, 2
4,true , 1, 953572,unten rechts , 2, 0, 80, 58200, 57000, 2800, 1, 16896, 82432, 0, 0, 0, 0, 0, 55, 0, -1.00000, -1.00000, 34.00000, 50.00000,false,false, 0, 4, 0, 0, 0, 0, 2
5,true , 1, 953573,Tisch , 2, 0, 80, 59150, 58400, 1900, 43, 15373058, 15635202, 0, 0, 0, 0, 0, 9, 0, -1.00000, -1.00000, 42.00000, 50.00000,false,false, 0, 5, 0, 0, 0, 0, 1
6,true , 1, 953574,türe , 2, 0, 80, 58400, 58150, 1600, 42, 15438594, 15635202, 0, 0, 0, 0, 0, 8, 0, -1.00000, -1.00000, 42.00000, 50.00000,false,false, 0, 6, 0, 0, 0, 0, 1
7,true , 1, 953575,sitzplatz , 2, 0, 80, 59570, 58750, 1400, 45, 15504130, 15635202, 0, 0, 0, 0, 0, 10, 0, -1.00000, -1.00000, 35.00000, 50.00000,false,false, 0, 7, 0, 0, 0, 0, 1
1, 0, 953569,all-4 , 0, 80, 1, 2, 3, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2,false, 2, 7
2, 0, 953576,all-3 , 0, 80, 5, 6, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3,false, 1, 14
3, 0, 953577,all-7 , 0, 80, 7, 5, 6, 1, 2, 3, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4,false, 0, 16
0, 0, 0, 0, 0, 0, 0
"v2.4.7","storen-somfy","pool.ntp.org","CET-1CEST-2,M3.5.0/02:00:00,M10.5.0/03:00:00",true ,true
1,true ,"192.168.1.225","192.168.1.1","255.255.255.0","62.2.24.162","62.2.17.60","mqtt://","ESPSomfyRTS", 1883,false,"","homeassistant", 0, 0, 0, 0, -1, 23, 18
true , 0, 80, 18, 5, 23, 19, 13, 12, 433.420, 99.97, 47.60, 10