PMS reports error "Error while decoding stream #0:1: No space left on device"

Server Version#: 1.41.7.9823
Player Version#: 4.146.0
<If providing server logs please do NOT turn on verbose logging, only debug logging should be enabled>

I know this symptom should have been fixed a couple years ago but I have encountered it.

This is what I know so far.

PMS has logged the following errors:

$ cat Plex Media Server.log
May 26, 2025 01:48:50.304 [128616471718712] INFO - Plex Media Server v1.41.7.9823-59f304c16 - Docker Docker Container x86_64 - build: linux-x86_64 debian - GMT 00:00
May 26, 2025 01:48:50.304 [128616471718712] INFO - Linux version: 6.8.0-60-generic, language: en-US
May 26, 2025 01:48:50.304 [128616471718712] INFO - Processor: 16-core 13th Gen Intel(R) Core(TM) i5-1340P
May 26, 2025 01:48:50.304 [128616471718712] INFO - Compiler is - Clang 11.0.1 (https://plex.tv 9b997da8e5b47bdb4a9425b3a3b290be393b4b1f)
May 26, 2025 01:48:50.304 [128616471718712] INFO - /usr/lib/plexmediaserver/Plex Media Server
May 26, 2025 01:48:50.303 [128616304622392] ERROR - [Req#931868/Transcode/60250b43-a367-4ef3-a0bb-ba5d990102db/fe8190be-1cd9-46ed-bdcc-097491f3cbd3] Error while decoding stream #0:1: No space left on device
May 26, 2025 01:48:50.303 [128616302512952] ERROR - [Req#931869/Transcode/60250b43-a367-4ef3-a0bb-ba5d990102db/fe8190be-1cd9-46ed-bdcc-097491f3cbd3] Error while decoding stream #0:1: No space left on device

...

May 26, 2025 01:49:01.315 [128616298294072] ERROR - [Req#93b626/Transcode/60250b43-a367-4ef3-a0bb-ba5d990102db/fe8190be-1cd9-46ed-bdcc-097491f3cbd3] Error while decoding stream #0:1: No space left on device
May 26, 2025 01:49:01.315 [128616300403512] ERROR - [Req#93b627/Transcode/60250b43-a367-4ef3-a0bb-ba5d990102db/fe8190be-1cd9-46ed-bdcc-097491f3cbd3] Error while decoding stream #0:1: No space left on device
May 26, 2025 01:49:01.317 [128616302512952] ERROR - [Req#93b628/Transcode/60250b43-a367-4ef3-a0bb-ba5d990102db/fe8190be-1cd9-46ed-bdcc-097491f3cbd3] [truehd_eae @ 0x7ce4801a9580] error reading output: -1313558101 (Unknown error occurred)
May 26, 2025 01:49:01.317 [128616304622392] ERROR - [Req#93b629/Transcode/60250b43-a367-4ef3-a0bb-ba5d990102db/fe8190be-1cd9-46ed-bdcc-097491f3cbd3] Error while decoding stream #0:1: Unknown error occurred
May 26, 2025 01:49:01.321 [128616296184632] ERROR - [Req#93b62a/Transcode/60250b43-a367-4ef3-a0bb-ba5d990102db/fe8190be-1cd9-46ed-bdcc-097491f3cbd3] [truehd_eae @ 0x7ce4801a9580] error reading output: -1313558101 (Unknown error occurred)
May 26, 2025 01:49:01.321 [128616356105016] ERROR - [Req#93b62b/Transcode/60250b43-a367-4ef3-a0bb-ba5d990102db/fe8190be-1cd9-46ed-bdcc-097491f3cbd3] Error while decoding stream #0:1: Unknown error occurred
May 26, 2025 01:49:01.331 [128616419965752] ERROR - Failed to transcode file (69): /mnt/media/TV_Shows/Anime/Doraemon (1973) (1973) {tvdb-75141}/Specials/Doraemon - S00E24.HDTV-1080p - Movie 24- Nobita and the Windmasters [x264.MLP.FBA[JA+Chinese].[Chinese+JA]].mkv
May 26, 2025 01:52:43.799 [128616356105016] INFO - [Req#93bcf3] AutoUpdate: no updates available

The compose.yaml:

$ cat compose.yaml
---
include:
  - ./volumes.yaml

services:
  plex:
    image: "plexinc/pms-docker:beta"

    container_name: plex
    deploy:
      resources:
        limits:
          memory: 4G
    hostname: NUC13
    devices:
      - "/dev/dri:/dev/dri"
      - /dev/bus/usb:/dev/bus/usb # to silence the error "Critical: libusb_init failed"
    environment:
      - PLEX_UID=2001
      - PLEX_GID=2001
      - TZ="Europe/London"
      - PLEX_CLAIM="[REDACTED]"
      - 'LANG=en_US.UTF-8'
      - ADVERTISE_IP=[REDACTED],http://10.27.0.50:32400
    tmpfs:
      - /transcode:mode=777,uid=2001,gid=2001
    volumes:
      - "./config:/config:rw"
      - "/home/janus/server_certs/ng.home:/certs:ro"
      - type: volume
        source: private
        target: /mnt/private
      - type: volume
        source: backup
        target: /mnt/backup
        volume:
          subpath: backup
      - type: volume
        source: media_Movies
        target: /mnt/media/Movies
      - type: volume
        source: media_Movies_4K
        target: /mnt/media/Movies_4K
      - type: volume
        source: media_Music
        target: /mnt/media/Music
      - type: volume
        source: media_Music_Videos
        target: /mnt/media/Music_Videos
      - type: volume
        source: media_TV_Shows
        target: /mnt/media/TV_Shows
      - type: volume
        source: media_Videos
        target: /mnt/media/Videos
    ports:
      - 32400:32400/tcp
      - 8324:8324/tcp
      - 32469:32469/tcp
      - 32410:32410/udp
      - 32412:32412/udp
      - 32413:32413/udp
      - 32414:32414/udp
    restart: unless-stopped
    labels:
      - "com.centurylinklabs.watchtower.enable=false"

The /transcode directory has ample space and PMS has full access to it:

$ sudo docker exec -it -u 2001:2001 plex bash
$ df -h /transcode/
Filesystem      Size  Used Avail Use% Mounted on
tmpfs            16G     0   16G   0% /transcode
$ ls -lhd /transcode/
drwxrwxrwx 3 plex plex 60 May 26 13:00 /transcode/

Hardware: Intel NUC13 Core i5 1340P
Memory: 32GB
OS:

$ lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 24.04.2 LTS
Release:	24.04
Codename:	noble

Transcoding TrueHD audio does not produce the error but the transcoded video skips 5 seconds after played every 3 seconds while playing on Chrome for Mac Version 136.0.7103.114 (Official Build) (arm64) The same file plays fine on Plex for Google TV with audio transcoding.

I read around here that under some circumstances, the transcode directory may need enough space to hold the entire original file. Is the file bigger than the space available?

Thanks for the pointer. That might explain it.

As shown above, the tmpfs is currently listed as 16GB available. There are a few media that are bigger than 16GB.

I have played a few videos with forced transcoding but the error No space left on device did not appear.

Let me do more research.