NextNVR/README.md

111 lines
3.5 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# NextNVR
A lightweight, self-hosted video recorder for IP cameras. Records 8 RTSP streams into 5-minute MP4 clips with near-zero CPU usage. Built for the **Casa Alba Mindelo** guesthouse.
---
## Quick Install
Copy and paste this single line into your terminal:
```bash
curl -sSL https://git.lohmar.co.uk/cclohmar/NextNVR/raw/branch/main/setup.sh | bash
```
That's it. The script installs everything needed and starts NextNVR automatically.
Once done, open **[http://192.168.1.10:8080](http://192.168.1.10:8080)** in your browser.
---
## What It Does
| Feature | Detail |
|---|---|
| 📹 **Recording** | 8 cameras simultaneously, 5-minute MP4 clips |
| 💾 **Storage** | Saves to `/mnt/recordings/` — keeps 18 days, auto-deletes older |
| 🖥️ **Live Wall** | 4×2 grid showing all cameras at once. Click one to enlarge. |
| 🔍 **Playback** | Browse recordings by camera and date with presets (Today, Yesterday, Last 7 Days) |
| ⚙️ **Setup Wizard** | Scans your network for cameras and helps you name them |
| 🔒 **Local Only** | Everything runs on your own hardware. No cloud, no subscriptions. |
---
## Server
| What | Detail |
|---|---|
| Address | `http://192.168.1.10:8080` |
| Config file | `/opt/nextnvr/config.yaml` |
| Recordings | `/mnt/recordings/` |
| Logs | `sudo journalctl -u nextnvr -f` |
### Useful Commands
```bash
sudo systemctl status nextnvr # is it running?
sudo systemctl restart nextnvr # restart after changing config
sudo systemctl stop nextnvr # stop recording
sudo journalctl -u nextnvr -f # watch live logs
```
---
## How It Works
```
IP Cameras NextNVR Your Browser
─────────── ────────── ─────────────
192.168.1.201 ─┐
192.168.1.202 ─┤ RTSP FFmpeg -c copy .mp4 http://192.168.1.10:8080
192.168.1.203 ─┼──────────► (no re-encoding) ────────► Live Wall + Playback
... ┤ 5 min segments Settings + Setup
192.168.1.209 ─┘ auto-delete >18d
```
- **Zero transcoding** — FFmpeg copies the video stream directly. CPU stays under 5%.
- **Crash-proof** — if a camera disconnects, it auto-reconnects after 5 seconds.
- **Atomic files** — recording in progress uses `.part.mp4`. Only renamed to `.mp4` when complete. No corrupted files.
---
## Adding or Changing Cameras
1. Open **http://192.168.1.10:8080**
2. Click the **Settings** tab
3. Click **🔍 Scan Network** to find your cameras
4. Give each camera a name and description
5. Click **💾 Save Configuration**
6. Restart: `sudo systemctl restart nextnvr`
Or edit the config file directly:
```bash
sudo nano /opt/nextnvr/config.yaml
sudo systemctl restart nextnvr
```
---
## Updating
```bash
curl -sSL https://git.lohmar.co.uk/cclohmar/NextNVR/raw/branch/main/setup.sh | bash
```
The script pulls the latest version and restarts the service automatically.
---
## Troubleshooting
| Problem | Check |
|---|---|
| Can't open the web page | Is NextNVR running? `sudo systemctl status nextnvr` |
| No cameras showing | Check `config.yaml` — are camera IPs and passwords correct? |
| Recordings not saving | Does `/mnt/recordings/` exist? Is the disk mounted? (`df -h`) |
| Disk full | Recordings older than 18 days are auto-deleted. Check `df -h /mnt/recordings` |
---
Built with ❤️ in Mindelo, Portugal. 🇵🇹