Ubuntu mate 16.04 crashes when playing video/audio files

I have Ubuntu 16.04 LTS installed on a Dell Inspiron 3650. Since a couple of months I observed that the computer crashes when playing videos with Kodi (2:16.1~git20160425.1001-final-0xenial). Suddenly (and randomly) the video freezes and the last second of audio output repeats itself forever. There is no way to recover and hard reset is needed. I use Kodi almost once per day and I observed this kind of event once per week.

I though it was a problem related to Kodi, but during the past week I experienced the same problem while playing an audio file with Clementine (1.3.1-228-gd9b3a93~xenial): the music repeated itself endlessly like a broken disk and hard reset was the only way out.

I think it cannot be a problem with the hard disk, since the video/audio get stuck at different places and, moreover, my music and movie collections are located on different disks (one internal and the other usb). I think it something related with the sound driver.

Here goes the output of inixi -Fx with my system information.

putxisputxis@comedor:~$ inxi -Fx
System:    Host: comedor Kernel: 4.4.0-42-generic x86_64 (64 bit gcc: 5.4.0)
           Desktop: MATE 1.12.1 (Gtk 3.18.9-1ubuntu3.1) Distro: Ubuntu 16.04 xenial
Machine:   System: Dell product: Inspiron 3650 v: X00
           Mobo: Dell model: 0C2XKD v: A00 Bios: Dell v: 2.2.7 date: 12/04/2015
CPU:       Quad core Intel Core i5-6400 (-MCP-) cache: 6144 KB
           flags: (lm nx sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx) bmips: 21695
           clock speeds: max: 3300 MHz 1: 1425 MHz 2: 1241 MHz 3: 1240 MHz 4: 1221 MHz
Graphics:  Card: NVIDIA GK208 [GeForce GT 730] bus-ID: 01:00.0
           Display Server: X.Org 1.18.4 drivers: nvidia (unloaded: fbdev,vesa,nouveau)
           Resolution: [email protected]
           GLX Renderer: GeForce GT 730/PCIe/SSE2 GLX Version: 4.5.0 NVIDIA 361.42 Direct Rendering: Yes
Audio:     Card-1 NVIDIA GK208 HDMI/DP Audio Controller driver: snd_hda_intel bus-ID: 01:00.1
           Card-2 Intel Sunrise Point-H HD Audio driver: snd_hda_intel bus-ID: 00:1f.3
           Sound: Advanced Linux Sound Architecture v: k4.4.0-42-generic
Network:   Card-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller
           driver: r8169 v: 2.3LK-NAPI port: d000 bus-ID: 02:00.0
           IF: enp2s0 state: up speed: 1000 Mbps duplex: full mac: 64:00:6a:1a:46:ab
           Card-2: Realtek RTL8723BE PCIe Wireless Network Adapter port: c000 bus-ID: 03:00.0
           IF: N/A state: N/A mac: N/A
Drives:    HDD Total Size: 4032.3GB (81.2% used) ID-1: /dev/sda model: ST1000DM003 size: 1000.2GB
           ID-2: USB /dev/sdb model: External_USB_3.0 size: 3000.6GB
           ID-3: USB /dev/sdc model: DataTraveler_3.0 size: 31.5GB
Partition: ID-1: / size: 909G used: 488G (57%) fs: ext4 dev: /dev/sda2
           ID-2: swap-1 size: 8.53GB used: 0.05GB (1%) fs: swap dev: /dev/sda3
RAID:      No RAID devices: /proc/mdstat, md_mod kernel module present
Sensors:   None detected - is lm-sensors installed and configured?
Info:      Processes: 234 Uptime: 1 day Memory: 3199.1/7927.5MB Init: systemd runlevel: 5 Gcc sys: 5.4.0
           Client: Shell (bash 4.3.461) inxi: 2.2.35 

The computer is connected to a monitor (actually a Sony Bravia TV) via a HDMI cable, through which video/audio data are sent. So, it is the NVIDIA card which takes care of both. My guess is that the problem is related with the graphic card. Unfortunately, when the computer crashes, it doesn’t have time to write to the log file, so this intuition cannot be confirmed.

Please note that I’m using the proprietary driver nvidia-361.42.

My question is: is there a way to check what the problem really is? Could it be related with pulseaudio? Should I use the nouveau driver instead? Note that I would prefer not to use the open source driver because when I tried it in the past I noticed that it does not support all the features of the graphic card (well, this actually was the case a while ago…).

Any suggestion is welcome. Thanks!

I too have this same issue I have tried switching to other drivers but it persists.I also have nvidia graphics.However in my case it gets stuck while playing videos, whether VLC or youtube.