842e66996f
Samba, Proxmox-Config, Host-NFS-Exports; pve1-Gäste komplett. Co-authored-by: Cursor <cursoragent@cursor.com>
150 lines
4.3 KiB
Markdown
150 lines
4.3 KiB
Markdown
# CT 100 — files (Storage / Samba)
|
|
|
|
| | |
|
|
|---|---|
|
|
| **Proxmox** | pve1, CTID 100 |
|
|
| **Hostname** | `files` |
|
|
| **IP** | 192.168.20.10/24 (VLAN 20 Privat) |
|
|
| **Gateway/DNS** | 192.168.20.1 (OPNsense) |
|
|
| **Typ** | LXC — **kein Docker** |
|
|
|
|
Zentraler Dateizugriff auf den **mergerfs-Pool** `/mnt/storage` (~99 TB, via Bind-Mount vom pve1-Host).
|
|
|
|
---
|
|
|
|
## Rolle im Gesamtsystem
|
|
|
|
```
|
|
pve1 Host (192.168.10.5)
|
|
├── /mnt/storage ← mergerfs-Pool (Physisch auf Host)
|
|
├── /etc/exports ← NFS-Server (für VM 101, pve2)
|
|
└── mp0 → CT 100 ← gleicher Pfad im Container
|
|
|
|
CT 100 (192.168.20.10)
|
|
├── /mnt/storage ← Bind von Host
|
|
├── Samba [storage] ← SMB-Zugriff auf ganzen Pool
|
|
└── Cockpit ← Web-UI (file-sharing Modul)
|
|
|
|
VM 101 (192.168.10.10)
|
|
└── NFS von 192.168.10.5 ← Nextcloud-Daten, Media, Audio
|
|
(nicht von CT 100!)
|
|
```
|
|
|
|
**Wichtig:** NFS-Exports laufen auf dem **Proxmox-Host** (`192.168.10.5`), nicht im CT. Der CT dient vor allem **Samba/Cockpit** auf VLAN 20.
|
|
|
|
---
|
|
|
|
## Proxmox-Konfiguration
|
|
|
|
→ [proxmox.conf](proxmox.conf)
|
|
|
|
| Parameter | Wert |
|
|
|-----------|------|
|
|
| RAM | 1024 MB |
|
|
| Cores | 4 |
|
|
| rootfs | 2 GB (`local-lvm`) |
|
|
| mp0 | `/mnt/storage` → `/mnt/storage` |
|
|
| Netz | `vmbr0`, VLAN tag **20** |
|
|
| Features | `nesting=1` |
|
|
|
|
---
|
|
|
|
## Dienste im CT
|
|
|
|
| Dienst | Zweck |
|
|
|--------|-------|
|
|
| **smbd/nmbd** | Samba — Share `[storage]` → `/mnt/storage` |
|
|
| **Cockpit** | Web-Admin inkl. `cockpit-file-sharing` |
|
|
| **SSH** | Remote-Admin |
|
|
| **NFS-Server-Pakete** | installiert; aktive Exports liegen auf dem **Host** |
|
|
|
|
---
|
|
|
|
## Konfiguration im Repo
|
|
|
|
| Datei | Beschreibung |
|
|
|-------|--------------|
|
|
| [proxmox.conf](proxmox.conf) | `pct config 100` |
|
|
| [smb.conf](smb.conf) | Samba (Share `[storage]`, Cockpit-Registry-Include) |
|
|
| [cockpit.conf](cockpit.conf) | Cockpit WebService |
|
|
| [host-exports.reference](host-exports.reference) | NFS `/etc/exports` auf **pve1** (Referenz) |
|
|
|
|
Keine User-Daten, keine Passwörter (`/etc/samba/private/` nicht im Repo).
|
|
|
|
---
|
|
|
|
## NFS-Exports (Host pve1)
|
|
|
|
Referenz: [host-exports.reference](host-exports.reference)
|
|
|
|
| Export | Client | Zugriff | Nutzung |
|
|
|--------|--------|---------|---------|
|
|
| `/mnt/storage/service_data/cloud/data` | 192.168.10.10 (VM 101) | rw | Nextcloud-Daten |
|
|
| `/mnt/storage/media` | 192.168.10.10 | rw | Media-Stacks (Audio, Sabnzbd, …) |
|
|
| `/mnt/storage/service_data/audio` | 192.168.10.10 | rw | Audiobookshelf/Airsonic-Config |
|
|
| `/mnt/nvme1/backup` | 192.168.10.10 | ro | Backup-Mount |
|
|
| `/mnt/storage/media/movies` | 192.168.10.4 (pve2) | rw | Jellyfin o. ä. |
|
|
| `/mnt/storage/media/tvshows` | 192.168.10.4 (pve2) | rw | Jellyfin o. ä. |
|
|
|
|
VM 101 `fstab`-Beispiel:
|
|
|
|
```
|
|
192.168.10.5:/mnt/storage/service_data/cloud/data /mnt/nextcloud-data nfs defaults,nofail,_netdev 0 0
|
|
192.168.10.5:/mnt/storage/media /mnt/storage/media nfs defaults,nofail,_netdev 0 0
|
|
192.168.10.5:/mnt/storage/service_data/audio /mnt/service_data/audio nfs defaults,nofail,_netdev 0 0
|
|
```
|
|
|
|
---
|
|
|
|
## Storage-Layout (Top-Level `/mnt/storage`)
|
|
|
|
| Pfad | Inhalt (Kurz) |
|
|
|------|----------------|
|
|
| `backup/` | Backups |
|
|
| `media/` | Filme, Serien, Musik (NFS an VM 101 / pve2) |
|
|
| `service_data/cloud/data/` | Nextcloud User-Daten (~93 TB belegt) |
|
|
| `service_data/audio/` | Audio-Stack-Daten |
|
|
| `projects/` | Projekte |
|
|
| `public/` | Öffentliche Shares |
|
|
| `homes/` | User-Homes |
|
|
|
|
**Auslastung (Stand Doku):** ~95 % — siehe [06_ubuntu-vm-nextcloud.md](../../06_ubuntu-vm-nextcloud.md)
|
|
|
|
---
|
|
|
|
## Samba Share `[storage]`
|
|
|
|
Aus [smb.conf](smb.conf) (via Cockpit file-sharing):
|
|
|
|
- **Pfad:** `/mnt/storage`
|
|
- **read only:** No
|
|
- Zugriff: über Samba-Authentifizierung (Details in CT, nicht im Repo)
|
|
|
|
---
|
|
|
|
## Wartung / Zugriff
|
|
|
|
```bash
|
|
# Proxmox
|
|
pct enter 100
|
|
pct exec 100 -- systemctl status smbd
|
|
|
|
# Samba testen
|
|
pct exec 100 -- testparm -s
|
|
|
|
# NFS auf Host prüfen (nicht im CT!)
|
|
exportfs -v
|
|
systemctl status nfs-server
|
|
```
|
|
|
|
---
|
|
|
|
## Referenzen
|
|
|
|
| Dokument | Inhalt |
|
|
|----------|--------|
|
|
| [../vm101-ubuntu/](vm101-ubuntu/) | Docker-Stacks, NFS-Consumer |
|
|
| [../../06_ubuntu-vm-nextcloud.md](../../06_ubuntu-vm-nextcloud.md) | Nextcloud, Pool-Auslastung |
|
|
| [../../infrastructure-host.md](../../infrastructure-host.md) | pve1 CT/VM-Übersicht |
|
|
| [../../04_fallback_aktivierung.md](../../04_fallback_aktivierung.md) | VLAN 20 / Privat-Netz |
|