my Plex is struggling to play MKV files & other formats

my Plex server is struggling to play MKV file formats & other formats the only one that really works is MP4

Specs
Intel Xeon E3-1270V3
2x HDD 4,0 TB SATA Enterprise
4x RAM DDR3 8192 MB ECC
1GBPS connection

Should i just use Linux?

I have performance issues when I try to play 4K MKV files similar than you reported on Feb 2017, so no idea what could be the reason. In this case, I have tested in Linux.

Configuration:
Server:

  • OS: Tested in Gentoo own kernel, Centos 7 and Ubuntu 16.04 LTS with last available Plex version.
  • Xeon E3-1265L V2 (4 Cores/8HT)
  • 2x8GB DDR3 ECC
  • 3x3TB WD Red (Raid5 + Luks + ext4)
  • Double Intel Giga lan PCI-E
    Client: Play Station 4
    Connected: giga lan switch and P-to-P (for testing)

As per Plex logs:

1 Mbps: no cuts

Plex Media Server.log:Jun 30, 2018 19:27:35.234 [0x7f22de7ff700] VERBOSE -  * speed => 11.2
Plex Media Server.log:Jun 30, 2018 19:27:43.288 [0x7f22dbbfe700] VERBOSE -  * speed => 10.2
Plex Media Server.log:Jun 30, 2018 19:27:43.791 [0x7f22dd7ff700] VERBOSE -  * speed => 14.3
Plex Media Server.log:Jun 30, 2018 19:27:50.835 [0x7f22e2fff700] VERBOSE -  * speed => 10.6
Plex Media Server.log:Jun 30, 2018 19:27:58.891 [0x7f22e2fff700] VERBOSE -  * speed => 10.5
Plex Media Server.log:Jun 30, 2018 19:28:06.947 [0x7f22e73ff700] VERBOSE -  * speed => 11.2

12 Mbps, 1080p: no cuts

Plex Media Server.log:Jun 30, 2018 19:42:29.265 [0x7f22df7ff700] VERBOSE - * speed => 1.9
Plex Media Server.log:Jun 30, 2018 19:42:29.778 [0x7f22c7bff700] VERBOSE - * speed => 2.0
Plex Media Server.log:Jun 30, 2018 19:42:30.285 [0x7f22e73ff700] VERBOSE - * speed => 1.5
Plex Media Server.log:Jun 30, 2018 19:42:30.825 [0x7f22c73fe700] VERBOSE - * speed => 2.0
Plex Media Server.log:Jun 30, 2018 19:42:31.377 [0x7f22df7ff700] VERBOSE - * speed => 1.7
Plex Media Server.log:Jun 30, 2018 19:42:31.903 [0x7f22e73ff700] VERBOSE - * speed => 2.0
Plex Media Server.log:Jun 30, 2018 19:42:32.422 [0x7f22df7ff700] VERBOSE - * speed => 1.7
Plex Media Server.log:Jun 30, 2018 19:42:32.914 [0x7f22c7bff700] VERBOSE - * speed => 1.9

27 Mbps, 4K: cuts every 4 or 5 seconds

Plex Media Server.log:Jun 30, 2018 19:33:16.621 [0x7f22c73fe700] VERBOSE -  * speed => 1.3
Plex Media Server.log:Jun 30, 2018 19:33:17.663 [0x7f22e73ff700] VERBOSE -  * speed => 1.5
Plex Media Server.log:Jun 30, 2018 19:33:18.190 [0x7f22df7ff700] VERBOSE -  * speed => 1.8
Plex Media Server.log:Jun 30, 2018 19:33:19.241 [0x7f22df7ff700] VERBOSE -  * speed => 1.4
Plex Media Server.log:Jun 30, 2018 19:33:20.285 [0x7f22c7bff700] VERBOSE -  * speed => 1.3
Plex Media Server.log:Jun 30, 2018 19:33:21.873 [0x7f22e73ff700] VERBOSE -  * speed => 1.3

Testing in Plex server:

CPU:

$ cat /proc/cpuinfo | grep “model name” | awk -F’:’ {‘print $2’} | sort | uniq -c
8 Intel(R) Xeon(R) CPU E3-1265L V2 @ 2.50GHz
$ cat /proc/cpuinfo | grep MHz | sort | uniq -c
1 cpu MHz : 2440.480
7 cpu MHz : 2500.000

Memory:

free -m
total used free shared buff/cache available
Mem: 16002 4256 8885 77 2861 11337
Swap: 4427 0 4427

CPU Temperature:

Physical id 0: +63.0°C (high = +90.0°C, crit = +94.0°C)
Core 0: +57.0°C (high = +90.0°C, crit = +94.0°C)
Core 1: +56.0°C (high = +90.0°C, crit = +94.0°C)
Core 2: +56.0°C (high = +90.0°C, crit = +94.0°C)
Core 3: +62.0°C (high = +90.0°C, crit = +94.0°C)

Disk:

$ hdparm -tT /dev/mapper/raid
/dev/mapper/raid:
Timing cached reads: 17662 MB in 1.99 seconds = 8855.79 MB/sec
Timing buffered disk reads: 878 MB in 3.00 seconds = 292.51 MB/sec

$ cryptsetup luksDump /dev/md127
LUKS header information for /dev/md127
Version: 1
Cipher name: aes
Cipher mode: xts-plain64
Hash spec: sha1
Payload offset: 4096
MK bits: 512

$ mdadm --detail /dev/md127
/dev/md127:
Version : 1.2
Creation Time : Wed Jan 27 20:34:41 2016
Raid Level : raid5
Array Size : 5860268032 (5588.79 GiB 6000.91 GB)
Used Dev Size : 2930134016 (2794.39 GiB 3000.46 GB)
Raid Devices : 3
Total Devices : 3
Persistence : Superblock is persistent

State : clean
Active Devices : 3
Working Devices : 3
Failed Devices : 0
Spare Devices : 0

     Layout : left-symmetric
 Chunk Size : 512K

       Name : localhost:raid
       UUID : d78ab670:4f5d8dbd:XXXXXXXXX
     Events : 98977

Number   Major   Minor   RaidDevice State
   0       8       49        0      active sync   /dev/sdd1
   1       8       33        1      active sync   /dev/sdc1
   3       8       17        2      active sync   /dev/sdb1