Page 1 of 1

System Crash when using Handbrake

Posted: Thu Nov 21, 2019 10:27 pm
by Ryaniskira
Description of problem or question:

I am having an issue where my system will hard crash (as in power down and reboot rather than just freezing) when using Handbrake. After a lot of troubleshooting I have found the issue only occurs when using Handbrake. Sometimes I can retry the transcode and it will work fine other times no matter what it will crash on a particular video file. This happens no matter how I transcode whether via Intel Quicksync, software, H.264, HEVC, etc etc.

Here are my temps at the time of the crash:

Code: Select all

Core 0:        +65.0°C  (high = +82.0°C, crit = +100.0°C)
Core 1:        +67.0°C  (high = +82.0°C, crit = +100.0°C)
Core 2:        +64.0°C  (high = +82.0°C, crit = +100.0°C)
Core 3:        +64.0°C  (high = +82.0°C, crit = +100.0°C)
Core 4:        +61.0°C  (high = +82.0°C, crit = +100.0°C)
Core 5:        +62.0°C  (high = +82.0°C, crit = +100.0°C)
Output of journalctl -k:

Code: Select all

Nov 21 16:59:15 freyja sshd[218582]: pam_unix(sshd:session): session opened for user kira by (uid=0)
Nov 21 16:59:15 freyja systemd[1]: Started Session 8 of user kira.
Nov 21 16:59:15 freyja systemd-logind[651]: New session 8 of user kira.
Nov 21 16:59:15 freyja audit[218611]: CRED_ACQ pid=218611 uid=0 auid=1000 ses=8 msg='op=PAM:setcred grantors=pam_tally2,pam_shells,pam_unix,pam_permit,pam_env acct="kira" exe="/usr/bin/sshd" hostname=192.168.1.4 addr=192.168.1.4 terminal=ssh res=success'
Nov 21 16:59:15 freyja kernel: audit: type=1103 audit(1574373555.727:353): pid=218611 uid=0 auid=1000 ses=8 msg='op=PAM:setcred grantors=pam_tally2,pam_shells,pam_unix,pam_permit,pam_env acct="kira" exe="/usr/bin/sshd" hostname=192.168.1.4 addr=192.168.1.4 terminal=ssh res=success'
Nov 21 16:59:17 freyja polkitd[5776]: Registered Authentication Agent for unix-process:218679:2553028 (system bus name :1.151 [flatpak list], object path /org/freedesktop/PolicyKit1/AuthenticationAgent, locale C)
Nov 21 16:59:17 freyja polkitd[5776]: Unregistered Authentication Agent for unix-process:218679:2553028 (system bus name :1.151, object path /org/freedesktop/PolicyKit1/AuthenticationAgent, locale C)
Nov 21 16:59:29 freyja systemd[1]: run-docker-runtime\x2drunc-moby-6c3e720acd904f95d077c07f101d5547b4f53f6322a16d17e5a631ca2ebc06a3-runc.GP1eZ4.mount: Succeeded.
Nov 21 16:59:29 freyja systemd[760]: run-docker-runtime\x2drunc-moby-6c3e720acd904f95d077c07f101d5547b4f53f6322a16d17e5a631ca2ebc06a3-runc.GP1eZ4.mount: Succeeded.
Nov 21 17:00:01 freyja CROND[219418]: (root) CMD (timeshift --check --scripted)
Nov 21 17:00:01 freyja CROND[219417]: (root) CMDOUT ((process:219418): GLib-GIO-CRITICAL **: 17:00:01.096: g_file_get_path: assertion 'G_IS_FILE (file)' failed)
Nov 21 17:00:01 freyja CROND[219417]: (root) CMDOUT ()
Nov 21 17:00:01 freyja CROND[219417]: (root) CMDOUT (** (process:219418): CRITICAL **: 17:00:01.096: tee_jee_file_system_path_combine: assertion 'path1 != NULL' failed)
Nov 21 17:00:01 freyja CROND[219417]: (root) CMDOUT ()
Nov 21 17:00:01 freyja CROND[219417]: (root) CMDOUT (** (process:219418): CRITICAL **: 17:00:01.096: tee_jee_file_system_dir_exists: assertion 'dir_path != NULL' failed)
Nov 21 17:00:01 freyja CROND[219417]: (root) CMDOUT (Weekly snapshots are enabled)
Nov 21 17:00:01 freyja CROND[219417]: (root) CMDOUT (Last weekly snapshot is 5 days old)
Nov 21 17:00:01 freyja CROND[219417]: (root) CMDOUT (------------------------------------------------------------------------------)
Nov 21 17:00:01 freyja crontab[219455]: (root) LIST (root)
Nov 21 17:00:01 freyja crontab[219456]: (root) LIST (root)
Nov 21 17:00:06 freyja kernel: perf: interrupt took too long (3955 > 3946), lowering kernel.perf_event_max_sample_rate to 50000
Nov 21 17:01:01 freyja CROND[220328]: (root) CMD (run-parts /etc/cron.hourly)
Steps to reproduce the problem (If Applicable):

I don't know what to put here.


HandBrake version (e.g., 1.0.0):

20191116125448-cd4106c-master (Flatpak) & 1.3.0 (Flatpak)

(I originally had 1.3.0 but I installed the nightly in hopes that if this was an issue with Handbrake that it had been patched)


Operating system and version (e.g., Ubuntu 16.04 LTS, macOS 10.13 High Sierra, Windows 10 Creators Update):

Arch Linux (Rolling)


HandBrake Activity Log ***required*** (see How-to get an activity log)

In concerns to forum rule 2c: The film White Zombie (1932) is public domain so there should be no legal issues nor legal grey areas with it.

Code: Select all

Handbrake Version: 20191116125448-cd4106c-master (2019111601)
[16:56:26] gtkgui: Custom Preset: /My Presets/Plex TV + Movies Interlaced+Film | HEVC
[16:56:26] Starting work at: Thu Nov 21 16:56:26 2019

[16:56:26] 1 job(s) to process
[16:56:26] json job:
{
    "Audio": {
        "AudioList": [
            {
                "Bitrate": 160,
                "CompressionLevel": -1.0,
                "DRC": 0.0,
                "DitherMethod": "auto",
                "Encoder": "ac3",
                "Gain": 0.0,
                "Mixdown": "stereo",
                "Name": "FLAC Audio / 2.0 / 48 kHz / 355 kbps / 16-bit",
                "NormalizeMixLevel": false,
                "PresetEncoder": "copy:dts",
                "Quality": -3.0,
                "Samplerate": 0,
                "Track": 0
            }
        ],
        "CopyMask": [
            "copy:aac"
        ],
        "FallbackEncoder": "ac3"
    },
    "Destination": {
        "AlignAVStart": false,
        "ChapterList": [
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 4,
                    "Seconds": 19,
                    "Ticks": 23295780
                },
                "Name": "Chapter 1"
            },
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 7,
                    "Seconds": 0,
                    "Ticks": 37822770
                },
                "Name": "Chapter 2"
            },
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 7,
                    "Seconds": 54,
                    "Ticks": 42638850
                },
                "Name": "Chapter 3"
            },
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 8,
                    "Seconds": 26,
                    "Ticks": 45521730
                },
                "Name": "Chapter 4"
            },
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 4,
                    "Seconds": 51,
                    "Ticks": 26216190
                },
                "Name": "Chapter 5"
            },
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 5,
                    "Seconds": 8,
                    "Ticks": 27747720
                },
                "Name": "Chapter 6"
            },
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 7,
                    "Seconds": 35,
                    "Ticks": 40990950
                },
                "Name": "Chapter 7"
            },
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 3,
                    "Seconds": 36,
                    "Ticks": 19459440
                },
                "Name": "Chapter 8"
            },
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 4,
                    "Seconds": 27,
                    "Ticks": 24054030
                },
                "Name": "Chapter 9"
            },
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 4,
                    "Seconds": 32,
                    "Ticks": 24504480
                },
                "Name": "Chapter 10"
            },
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 4,
                    "Seconds": 45,
                    "Ticks": 25675650
                },
                "Name": "Chapter 11"
            },
            {
                "Duration": {
                    "Hours": 0,
                    "Minutes": 4,
                    "Seconds": 13,
                    "Ticks": 22734810
                },
                "Name": "Chapter 12"
            }
        ],
        "ChapterMarkers": true,
        "File": "/mnt/Media/Ingest/Transcoding/output/White Zombie.HEVC.mkv",
        "InlineParameterSets": false,
        "Mp4Options": {
            "IpodAtom": false,
            "Mp4Optimize": false
        },
        "Mux": "mkv"
    },
    "Filters": {
        "FilterList": [
            {
                "ID": 3,
                "Settings": {
                    "block-height": "16",
                    "block-thresh": "40",
                    "block-width": "16",
                    "filter-mode": "2",
                    "mode": "3",
                    "motion-thresh": "1",
                    "spatial-metric": "2",
                    "spatial-thresh": "1"
                }
            },
            {
                "ID": 4,
                "Settings": {
                    "mode": "7"
                }
            },
            {
                "ID": 6,
                "Settings": {
                    "mode": 0
                }
            },
            {
                "ID": 9,
                "Settings": {
                    "cb-frame-count": 2,
                    "cb-origin-tune": 0.59999999999999998,
                    "cb-patch-size": 7,
                    "cb-prefilter": 0,
                    "cb-range": 3,
                    "cb-strength": 10.0,
                    "y-frame-count": 2,
                    "y-origin-tune": 0.59999999999999998,
                    "y-patch-size": 7,
                    "y-prefilter": 0,
                    "y-range": 3,
                    "y-strength": 8.0
                }
            },
            {
                "ID": 12,
                "Settings": {
                    "crop-bottom": 0,
                    "crop-left": 0,
                    "crop-right": 0,
                    "crop-top": 0,
                    "height": 1080,
                    "width": 1920
                }
            }
        ]
    },
    "Metadata": {
        "Name": "White Zombie (1932)"
    },
    "PAR": {
        "Den": 1,
        "Num": 1
    },
    "SequenceID": 0,
    "Source": {
        "Angle": 0,
        "Path": "/mnt/Media/Ingest/Transcoding/input/MakeMKV Dump/White Zombie_t04.mkv",
        "Range": {
            "End": 12,
            "Start": 1,
            "Type": "chapter"
        },
        "Title": 1
    },
    "Subtitle": {
        "Search": {
            "Burn": true,
            "Default": false,
            "Enable": false,
            "Forced": false
        },
        "SubtitleList": []
    },
    "Video": {
        "ColorFormat": 0,
        "ColorMatrix": 1,
        "ColorPrimaries": 1,
        "ColorRange": 1,
        "ColorTransfer": 1,
        "Encoder": "qsv_h265",
        "Level": "auto",
        "Options": "",
        "Preset": "quality",
        "Profile": "auto",
        "QSV": {
            "AsyncDepth": 4,
            "Decode": false
        },
        "Quality": 24.0,
        "Tune": "",
        "Turbo": false,
        "TwoPass": false
    }
}
[16:56:26] CPU: Intel(R) Core(TM) i7-8700K CPU @ 3.70GHz
[16:56:26]  - Intel microarchitecture Kaby Lake
[16:56:26]  - logical processor count: 12
[16:56:26] Intel Quick Sync Video support: yes
[16:56:26]  - Intel Media SDK hardware: API 1.30 (minimum: 1.3)
[16:56:26]  - H.264 encoder: yes
[16:56:26]     - preferred implementation: hardware (any) via ANY
[16:56:26]     - capabilities (hardware):  breftype icq+la+i+downs vsinfo opt1 opt2+mbbrc+extbrc+trellis+ib_adapt+nmpslice
[16:56:26]  - H.265 encoder: yes (8bit: yes, 10bit: yes)
[16:56:26]     - preferred implementation: hardware (any) via ANY
[16:56:26]     - capabilities (hardware):  bpyramid icq vsinfo opt1
[16:56:26] hb_scan: path=/mnt/Media/Ingest/Transcoding/input/MakeMKV Dump/White Zombie_t04.mkv, title_index=1
udfread ERROR: ECMA 167 Volume Recognition failed
disc.c:323: failed opening UDF image /mnt/Media/Ingest/Transcoding/input/MakeMKV Dump/White Zombie_t04.mkv
disc.c:424: error opening file BDMV/index.bdmv
disc.c:424: error opening file BDMV/BACKUP/index.bdmv
bluray.c:2585: nav_get_title_list(/mnt/Media/Ingest/Transcoding/input/MakeMKV Dump/White Zombie_t04.mkv/) failed
[16:56:26] bd: not a bd - trying as a stream/file instead
libdvdread: Encrypted DVD support unavailable.
libdvdread:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.IFO failed
libdvdread:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.BUP failed
libdvdread: Can't open file VIDEO_TS.BUP.
[16:56:26] dvd: not a dvd - trying as a stream/file instead
[mpeg2video @ 0x7f8090024400] ignoring pic cod ext after 0
Input #0, matroska,webm, from '/mnt/Media/Ingest/Transcoding/input/MakeMKV Dump/White Zombie_t04.mkv':
  Metadata:
    title           : White Zombie (1932)
    encoder         : libebml v1.3.6 + libmatroska v1.4.9
    creation_time   : 2018-07-22T12:51:37.000000Z
  Duration: 01:06:47.36, start: 0.000000, bitrate: 35503 kb/s
    Chapter #0:0: start 0.000000, end 258.842000
    Metadata:
      title           : Chapter 1
    Chapter #0:1: start 258.842000, end 679.095000
    Metadata:
      title           : Chapter 2
    Chapter #0:2: start 679.095000, end 1152.860000
    Metadata:
      title           : Chapter 3
    Chapter #0:3: start 1152.860000, end 1658.657000
    Metadata:
      title           : Chapter 4
    Chapter #0:4: start 1658.657000, end 1949.948000
    Metadata:
      title           : Chapter 5
    Chapter #0:5: start 1949.948000, end 2258.256000
    Metadata:
      title           : Chapter 6
    Chapter #0:6: start 2258.256000, end 2713.711000
    Metadata:
      title           : Chapter 7
    Chapter #0:7: start 2713.711000, end 2929.927000
    Metadata:
      title           : Chapter 8
    Chapter #0:8: start 2929.927000, end 3197.194000
    Metadata:
      title           : Chapter 9
    Chapter #0:9: start 3197.194000, end 3469.466000
    Metadata:
      title           : Chapter 10
    Chapter #0:10: start 3469.466000, end 3754.751000
    Metadata:
      title           : Chapter 11
    Chapter #0:11: start 3754.751000, end 4007.360000
    Metadata:
      title           : Chapter 12
    Stream #0:0(eng): Video: mpeg2video (Main), yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
    Metadata:
      title           : MPEG-2 Video / 34906 kbps / 1080p / 23.976 fps / 16:9
      BPS-eng         : 34906262
      DURATION-eng    : 01:06:47.295000000
      NUMBER_OF_FRAMES-eng: 96079
      NUMBER_OF_BYTES-eng: 17484961165
      _STATISTICS_WRITING_APP-eng: mkvmerge v25.0.0 ('Prog Noir') 64-bit
      _STATISTICS_WRITING_DATE_UTC-eng: 2018-07-22 12:51:37
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
    Stream #0:1(eng): Audio: flac, 48000 Hz, stereo, s16 (default)
    Metadata:
      title           : FLAC Audio / 2.0 / 48 kHz / 355 kbps / 16-bit
      BPS-eng         : 354879
      DURATION-eng    : 01:06:47.340000000
      NUMBER_OF_FRAMES-eng: 46962
      NUMBER_OF_BYTES-eng: 177765417
      _STATISTICS_WRITING_APP-eng: mkvmerge v25.0.0 ('Prog Noir') 64-bit
      _STATISTICS_WRITING_DATE_UTC-eng: 2018-07-22 12:51:37
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
    Stream #0:2(eng): Audio: ac3, 48000 Hz, stereo, fltp, 224 kb/s
    Metadata:
      title           : Commentary by Film Historian Gary D. Rhodes
      BPS-eng         : 224000
      DURATION-eng    : 01:06:47.360000000
      NUMBER_OF_FRAMES-eng: 125230
      NUMBER_OF_BYTES-eng: 112206080
      _STATISTICS_WRITING_APP-eng: mkvmerge v25.0.0 ('Prog Noir') 64-bit
      _STATISTICS_WRITING_DATE_UTC-eng: 2018-07-22 12:51:37
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
    Stream #0:3(eng): Subtitle: hdmv_pgs_subtitle
    Metadata:
      title           : SDH
      BPS-eng         : 16418
      DURATION-eng    : 01:04:34.454000000
      NUMBER_OF_FRAMES-eng: 774
      NUMBER_OF_BYTES-eng: 7951597
      _STATISTICS_WRITING_APP-eng: mkvmerge v25.0.0 ('Prog Noir') 64-bit
      _STATISTICS_WRITING_DATE_UTC-eng: 2018-07-22 12:51:37
      _STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
[16:56:26] scan: decoding previews for title 1
[mpeg2video @ 0x7f8090010280] ignoring pic cod ext after 0
[16:56:26] scan: audio 0x1: flac, rate=48000Hz, bitrate=1 English (FLAC) (2.0 ch)
[16:56:26] scan: audio 0x2: ac3, rate=48000Hz, bitrate=224000 English (AC3) (2.0 ch) (224 kbps)
[16:56:26] scan: 10 previews, 1920x1080, 23.976 fps, autocrop = 0/0/250/250, aspect 16:9, PAR 1:1
[16:56:26] libhb: scan thread found 1 valid title(s)
[16:56:26] Starting Task: Encoding Pass
[16:56:26] Skipping vfr filter
[16:56:26] Skipping crop/scale filter
[16:56:26] NLMeans using SSE2 optimizations
[16:56:26] NLMeans using 12 threads
[16:56:26] job configuration:
[16:56:26]  * source
[16:56:26]    + /mnt/Media/Ingest/Transcoding/input/MakeMKV Dump/White Zombie_t04.mkv
[16:56:26]    + title 1, chapter(s) 1 to 12
[16:56:26]    + container: matroska,webm
[16:56:26]    + data rate: 35503 kbps
[16:56:26]  * destination
[16:56:26]    + /mnt/Media/Ingest/Transcoding/output/White Zombie.HEVC.mkv
[16:56:26]    + container: Matroska (libavformat)
[16:56:26]      + chapter markers
[16:56:26]  * video track
[16:56:26]    + decoder: mpeg2video
[16:56:26]    + filters
[16:56:26]      + Comb Detect (mode=3:spatial-metric=2:motion-thresh=1:spatial-thresh=1:filter-mode=2:block-thresh=40:block-width=16:block-height=16)
[16:56:26]      + Decomb (mode=39)
[16:56:26]      + Denoise (nlmeans) (y-strength=8:y-origin-tune=0.6:y-patch-size=7:y-range=3:y-frame-count=2:y-prefilter=0:cb-strength=10:cb-origin-tune=0.6:cb-patch-size=7:cb-range=3:cb-frame-count=2:cb-prefilter=0)
[16:56:26]    + Output geometry
[16:56:26]      + storage dimensions: 1920 x 1080
[16:56:26]      + pixel aspect ratio: 1 : 1
[16:56:26]      + display dimensions: 1920 x 1080
[16:56:26]    + encoder: H.265 (Intel Media SDK)
[16:56:26]      + preset:  quality
[16:56:26]      + profile: auto
[16:56:26]      + level:   auto
[16:56:26]      + quality: 24.00 (ICQ)
[16:56:26]      + color profile: 1-1-1
[16:56:26]  * audio track 1
[16:56:26]    + name: FLAC Audio / 2.0 / 48 kHz / 355 kbps / 16-bit
[16:56:26]    + decoder: English (FLAC) (2.0 ch) (track 1, id 0x1)
[16:56:26]      + samplerate: 48000 Hz
[16:56:26]    + mixdown: Stereo
[16:56:26]    + dither: triangular
[16:56:26]    + encoder: AC3 (libavcodec)
[16:56:26]      + bitrate: 160 kbps, samplerate: 48000 Hz
[mpeg2video @ 0x7f809c032d00] ignoring pic cod ext after 0
[16:56:26] sync: expecting 96080 video frames
[16:56:26] hb_display_init: using VA driver 'iHD'
libva info: VA-API version 1.5.0
libva info: va_getDriverName() returns 0
libva info: User requested driver 'iHD'
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/iHD_drv_video.so
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/intel-vaapi-driver/iHD_drv_video.so
libva info: Found init function __vaDriverInit_1_5
libva info: va_openDriver() returns 0
[16:56:26] encqsvInit: using encode-only path
[16:56:26] encqsvInit: H.265/HEVC Main profile @ level 5.0
[16:56:26] encqsvInit: TargetUsage 1 AsyncDepth 4
[16:56:26] encqsvInit: GopRefDist 3 GopPicSize 24 NumRefFrame 6
[16:56:26] encqsvInit: BFramesMax 2 BRefType off
[16:56:26] encqsvInit: RateControlMethod ICQ ICQQuality 24
[16:56:26] sync: first pts video is 0
[16:56:26] sync: "Chapter 1" (1) at frame 1 time 0
[16:56:26] sync: first pts audio 0x1 is 0
[16:56:27] qsv_enc_init: using 'hardware (1) via VAAPI' implementation, API: 1.30

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 12:55 am
by BradleyS
That's definitely odd and usually points to thermals, but obviously yours seem to be well within spec. HandBrake really can't crash the kernel especially with Flatpak sandboxing so I'm wondering if there's some instability in the underlying Flatpak subsystem.

If you can trim (edit: use MKVToolNix or similar) the public domain source to a small sample, maybe 5-10 mins max, and provide it somewhere we can access it, I'll try to reproduce the problem here.

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 12:58 am
by BradleyS
Another thing you might try if you have time is building HandBrake from source (non-Flatpak) and see if that resolves the issue, which would point to something with the Flatpak specifically. We provide documentation for Arch here: https://handbrake.fr/docs/en/latest/dev ... -arch.html

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 1:12 am
by Ryaniskira
Cloudflare willing. I apologize for the file size but this is straight from the Blu-Ray.

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 1:20 am
by Ryaniskira
I also did provide 20 minutes as I was not at my desk when the crash occurred so I do not know at what point in the video the crash took place, I just know it was no more than 20 minutes. I can cut out a 10 minute clip but honestly the file size is not that much smaller.

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 2:42 am
by BradleyS
No problem, I'll take a look.

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 4:08 am
by BradleyS
Source encodes fine on macOS.

I booted up my Arch VM and performed:

Code: Select all

flatpak install runtime/org.gnome.Platform/x86_64/3.34
flatpak --user install HandBrake-1.3.0-x86_64.flatpak  # Direct download from handbrake.fr
Installed apps and runtimes:

Code: Select all

[arch@localhost ~]$ flatpak list
Name             Application ID         Version Branch Origin      Installation
HandBrake        fr.handbrake.ghb       1.3.0   stable ghb1-origin user
default          …p.Platform.GL.default         19.08  flathub     system
GNOME Applicati… org.gnome.Platform             3.34   flathub     system
Run:

Code: Select all

flatpak run fr.handbrake.ghb
Encoded the sample multiple times with various settings including NLMeans+x265 with no issues. I'm still not sure why you're having trouble on your end, but here are a few more ideas to investigate.

1) Make sure you have the correct org.gnome.Platform Flatpak runtime installed. I'm not sure how you could not, since Flatpak shouldn't install the app without it, but worth checking.

2) Try removing the QSV plugin Flatpak in case there's a currently unknown issue with it causing instability.

3) Try using Cpulimit to throttle HandBrake's CPU usage, say to 25% and be sure to use a software video encoder. If it crashes without cpulimit but is stable with cpulimit, then it's likely there is a system issue other than thermals, perhaps the CPU becoming unstable due to voltage or something else under high load. Check your EFI/BIOS and undo any customizations, if you have made any. It's also possible the manufacturer's settings could be not completely stable with max CPU load (unlikely but it's happened before).

4) Try FFmpeg or another video software with settings that generate 100% load and see if you experience similar issues. Games/shell scripts may use 100% CPU but HD video encoding is going to stress the CPU cache, SIMD registers, memory bus (especially with NLMeans), etc. much more and for longer.

Perhaps @JohnAStebbins will have additional suggestions re: possible Flatpak/Linux issues.

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 4:21 am
by BradleyS
5) As silly as it may sound, if this a notebook PC with a brick-type power adapter, it might be failing under load (voltage sag or inability to provide sufficient current). Has happened to me more than once with all sorts of equipment. Tough to measure without the right equipment, though.

Aside, my intention isn't to point at your hardware. That said, software-related crashes are usually reproducible in some way; things predictably fail at the same point with the same source and/or settings, often across multiple machines, which doesn't seem to be the case here. Hopefully it isn't hardware but the aforementioned testing should help isolate it from or as the problem.

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 1:13 pm
by Ryaniskira
I did actually think about that last night during some downtime. My CPU is an 8700k and I do have it overclocked and overvolted so I went into my bios settings and bumped up the voltages a little more, and one one of the videos that was giving me issues it completed just fine. I will continue to test and see if I experience crashes with any of the other videos causing issues (It it does I will take your suggestion and undo any overclocking and overvolting I've applied and re-test), I didn't even think about this at first as Plex when it would do an on-the-fly transcode this would never happen.

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 6:56 pm
by s55
HandBrake is a really good tool for testing overlclock stability. It's common to see the system crash out when running HandBrake but not other apps.

The reason for this is down to the fact that HandBrake is an AVX heavy workload where as most stress tests are only doing basic integer or floating point operations. They often don't stress the heavy weight parts of the CPU.

AVX units in the CPU don't overclock so well. A lot of bioses have an AVX Offset argument for this reason.

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 8:54 pm
by Ryaniskira
Yeah I stressed my overclocks with things like Mprime, Linpack, and stress and didn't find any issues with those tools. Don't think any of them use an AVX workload. I did fire up Project Cars 2 as that does use AVX iirc.

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 9:23 pm
by s55
Project Cars probably isn't using it consistently heavily like HandBrake does. AVX tends to be more used in multimedia / compute apps.

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 9:54 pm
by Ryaniskira
So that might explain why Project Cars was fine but Handbrake was giving me issues. I did set the AVX offset in my EFI/bios settings along with the aforementioned increase in voltage and so far on 3 tasks it's been working without issues.

Re: System Crash when using Handbrake

Posted: Fri Nov 22, 2019 9:56 pm
by BradleyS
Glad you got it sorted. :D