Archive, catch-up and timeshift
Updated 07 Oct 2026Castreon can keep on disk everything a channel has broadcast over the last days. Your subscribers can then watch past programmes in their IPTV player (catch-up), restart the current programme from the beginning (start-over) or watch the channel with a chosen delay (timeshift).
Available from Castreon 1.0.8, on the Pro (up to 7 days per channel) and Enterprise (no day limit — the disk is the limit) plans.
How it works
The channel already writes its HLS output in segments of a few seconds. The archive keeps these segments on disk before they leave the live window — no extra transcoding and no new process. Each segment is kept by the time it was broadcast, so the archive carries on cleanly across channel or server restarts.
On the same disk the segment is not copied at all (a hard link); if live HLS is in memory (tmpfs), the segment is copied to disk.
Turning it on for a channel
- Open the channel → Edit.
- Under Archive (catch-up), tick Keep an archive and choose how many days.
- Save.
Recording starts within seconds. The channel needs:
- an HLS output — it can sit next to the other outputs; a channel with no output configured has it by default;
- TS segments — on the HLS output, the TS or automatic container (automatic picks fMP4 only when the profile encodes HEVC or AV1);
- unencrypted HLS — the archive does not keep AES-128 encrypted HLS;
- to run permanently, not On demand — an on-demand channel stops without viewers and the archive would have gaps.
The panel tells you before saving if something is missing.
If you turn the archive off for a channel or delete the channel, what was recorded for it is deleted from disk within a minute.
Disk space
The archive takes the channel's bitrate multiplied by the time kept:
| Channel bitrate | One day | 7 days |
|---|---|---|
| 2 Mbit/s | ≈ 22 GB | ≈ 151 GB |
| 5 Mbit/s | ≈ 54 GB | ≈ 378 GB |
| 8 Mbit/s | ≈ 86 GB | ≈ 605 GB |
For a channel with several qualities (ABR) all qualities are kept, so their bitrates add up.
In Settings → Archive you find:
- Archive folder — empty means
archivein the node's data folder. We recommend a separate, large disk (not tmpfs). A new folder is created and checked on save. What was already recorded is not moved: it stays in the old folder. - Minimum free space (%) — 10 % by default. When the disk drops below the threshold, the node deletes the oldest hours, from any channel, until there is room again. Recording never stops because the disk is full.
- the disk (free / total), the space used by the archive, your plan and, for each channel, the days, the space, since when it has an archive and whether it is recording now.
The archive is deleted in whole hours: by each channel's days and by the free-space threshold.
In IPTV players
Nothing needs to be set up in the player. Export M3U marks the channels that have an archive:
#EXTINF:-1 tvg-id="canal-1" catchup="default" catchup-days="7" catchup-source="http://…/live/canal-1/index-{utc}-{duration}.m3u8",Canal 1
TiviMate, OTT Navigator, Kodi (IPTV Simple), Televizo and the other players that support catch-up from the M3U list show the archive on the channel, and past programmes in the guide can be played. For the programmes the player uses the TV guide — for DVB channels it comes straight from the mux, see TV guide (EPG) from DVB. The list asks for the guide over the archive days on its own (at most 8). Channels that are not DVB need an XMLTV guide from another source, linked through the EPG ID.
Reload the M3U list in the player after turning the archive on: the catch-up attributes appear only in lists exported afterwards.
Archive addresses
They all live next to the channel's live address, http://<public-domain>/live/<channel>/, with the same access rules (token, IP allow-list). <start> is UNIX time (UTC, in seconds), <duration> is in seconds.
| Address | What you get |
|---|---|
index-<start>-<duration>.m3u8 |
one programme (catch-up) |
index-<start>-now.m3u8 |
from <start> to live (start-over) |
timeshift_abs-<start>.m3u8 |
the same |
timeshift_rel-<seconds>.m3u8 |
the channel that many seconds behind |
archive-<start>-<duration>.ts |
one programme as a single MPEG-TS stream (?download=1 downloads it as a file) |
timeshift_abs-<start>.ts |
MPEG-TS from <start>, continuing up to live |
Example — one hour starting 7 October 2026, 18:00 UTC:
http://tv.yourdomain.com:33400/live/canal-1/index-1791396000-3600.m3u8?token=…
- For a channel with several qualities, the playlist is a master with all qualities, as for live.
- The token in the address is added to every address in the playlist automatically.
- One request covers at most 24 hours; open playlists (start-over, timeshift) go back at most 6 hours.
In the panel
In the channel's Schedule tab, past programmes that are in the archive have a Play button, and the current programme has From the start. The panel player has a time bar, so you can jump anywhere in the programme.
Metrics
/metrics includes castreon_archive_bytes, castreon_archive_disk_free_bytes, castreon_archive_disk_total_bytes, castreon_archive_channels_recording and castreon_archive_pruned_hours_total — useful, for example, for a Grafana alert when the archive disk fills up. See Metrics and Grafana.
Common problems
- The channel is not recording (Settings → Archive): the channel must be running; if a message appears on its row, it gives the reason (for example encrypted HLS or fMP4 segments).
- "not in archive" (404): the requested interval is before the first recording or has already been deleted (channel days, minimum free space).
- The player does not show the archive: reload the M3U list and the TV guide in the player.
- "the Pro plan keeps the archive for at most 7 days": more days need the Enterprise plan.