Server Version#: 1.21.1.3830
Player Version#: Whatever the latest native Roku tv Plex app is
Hi all, I’ve got a Raspberry pi 4 running the very latest plex server version. I’m experiencing an issue where playing certain video files from external drives - while they appear ok at first - end up in a long/failed buffering and then all other subsequent video play attempts fail. When I log into my Pi desktop during this issue, I’m unable to browse my files - the file browser just locks up.
I just wiped everything and started fresh. Even reformatted what I think is the problematic drive (exfat).
How should I go about diagnosing this issue from here? I can pull logs, but I’m not sure what to be looking for. I can try moving the problematic video files over to another external drive to see if I can isolate the issue to the drive itself.
Thank you for the reply. So I ran that and started up one of the problem videos. Started off ok but then froze up as expected. Terminal locked up, etc - until I just unplugged the drive and then everything began working fine again.
The logs were pretty uneventful except for the below error popping up a few times… Which doesn’t look great to me. Drive failure? It’s strange that it’s specific to certain files, though.
Dec 29 12:15:11 raspberrypi kernel: sd 1:0:0:0: [sdb] tag#0 UNKNOWN(0x2003) Result: hostbyte=0x00 driverbyte=0x08
Dec 29 12:15:11 raspberrypi kernel: sd 1:0:0:0: [sdb] tag#0 Sense Key : 0xb [current]
Dec 29 12:15:11 raspberrypi kernel: sd 1:0:0:0: [sdb] tag#0 ASC=0x47 ASCQ=0x3
Dec 29 12:15:11 raspberrypi kernel: sd 1:0:0:0: [sdb] tag#0 CDB: opcode=0x28 28 00 23 99 16 58 00 01 00 00
Dec 29 12:15:11 raspberrypi kernel: blk_update_request: I/O error, dev sdb, sector 597235288 op 0x0:(READ) flags 0x80700 phys_seg 6 prio class 0
Sorry, I overlooked the part where you say “external drive”. Yeah, I think you should run a fsck -y /dev/sdb on your drive and check if it can fix the error or mark those sectors as bad so you OS stop using it.
Thank you again!
So here’s a question… In the logs above I’m seeing reference to “dev sdb”. However, that is not exactly the name of the drive I’m expecting (or any of my drives…). It’s close, though, so good enough?
Assuming that is indeed the drive reference, I ran your suggested line:
pi@raspberrypi:~ $ sudo fsck -y /dev/sdb1
fsck from util-linux 2.33.1
exfatfsck 1.3.0
Checking file system on /dev/sdb1.
WARN: volume was not unmounted cleanly.
File system version 1.0
Sector size 512 bytes
Cluster size 256 KB
Volume size 931 GB
Used space 352 GB
Available space 580 GB
Totally 47 directories and 1211 files.
File system checking finished. No errors found.
Gotcha, ok. So I ran that and got the below - looks like it doesn’t like that the drive is exfat.
pi@raspberrypi:~ $ sudo fsck -y /dev/sdb
fsck from util-linux 2.33.1
e2fsck 1.44.5 (15-Dec-2018)
ext2fs_open2: Bad magic number in super-block
fsck.ext2: Superblock invalid, trying backup blocks...
fsck.ext2: Bad magic number in super-block while trying to open /dev/sdb
The superblock could not be read or does not describe a valid ext2/ext3/ext4
filesystem. If the device is valid and it really contains an ext2/ext3/ext4
filesystem (and not swap or ufs or something else), then the superblock
is corrupt, and you might try running e2fsck with an alternate superblock:
e2fsck -b 8193 <device>
or
e2fsck -b 32768 <device>
Found a gpt partition table in /dev/sdb
I found exfatfsck and thought perhaps that’s what I should be using instead. But that gave me the below
pi@raspberrypi:~ $ sudo exfatfsck -a /dev/sdb
exfatfsck 1.3.0
Checking file system on /dev/sdb.
ERROR: exFAT file system is not found.
File system checking stopped. ERRORS FOUND: 1, FIXED: 0.
So not sure where I’m left. I’ll try googling a bit more, but otherwise will probably dump the drive. It’s a shame since it’s pretty much new…
I suppose it is an external drive. Do not directly attach such a drive to your Pi. You need a powered USB-hub or a drive with its own power supply. Also switching to a better power adapter for your Pi might help.
Yes, it’s an external hard drive that is drawing power from the PI’s usb 3 port. Are you thinking that that the drive is underpowered and is causing sporadic failure on only specific video files…? I will look into Power supplies (I’m using the official Rpi power supply) and just a better powered drive as well.
So just wanted to thank you guys for your help troubleshooting and diagnosing. I was definitely underpowering the external drives. I bought a powered USB hub, remapped my drives, and now everything works much better. I don’t know why certain files were more impacted than others, but the problem has definitely been resolved.