Optical USB drive was working, but not quit.

blindguynar

Cadet
Joined
Feb 20, 2023
Messages
7
I'm fairly new to TrueNAS Scale and really to NAS in general. I want to apologize upfront that i'm not a HARDCORE linux guy so be gentle.

The hardware is a dedicated machine only running truenas scale as the OS.

I'm running the latest SCALE release and had a blueray drive attached via USB and had be passing it to MakeMkv with success, but after a restart today the drive no longer seems to mount to sr0. It shows connecting in dmesg, but i can't see to see it after wards.

Code:
[  581.679538] usb 1-7: USB disconnect, device number 8
[  585.107999] usb 1-7: new high-speed USB device number 9 using xhci_hcd
[  585.257740] usb 1-7: New USB device found, idVendor=174c, idProduct=55aa, bcdDevice= 1.00
[  585.259508] usb 1-7: New USB device strings: Mfr=2, Product=3, SerialNumber=1
[  585.261317] usb 1-7: Product: External Drive
[  585.263130] usb 1-7: Manufacturer: ASUSTek
[  585.264867] usb 1-7: SerialNumber: 123456789012
[  585.267995] usb-storage 1-7:1.0: USB Mass Storage device detected
[  585.270251] usb-storage 1-7:1.0: Quirks match for vid 174c pid 55aa: 400000
[  585.272266] scsi host7: usb-storage 1-7:1.0
[  586.366672] scsi 7:0:0:0: CD-ROM            ASUS     BW-16D1X-U       A104 PQ: 0 ANSI: 0
[  586.427185] sr 7:0:0:0: [sr0] scsi3-mmc drive: 48x/48x writer dvd-ram cd/rw xa/form2 cdda tray
[  586.467520] sr 7:0:0:0: Attached scsi CD-ROM sr0
[  586.467737] sr 7:0:0:0: Attached scsi generic sg5 type 5


However i can't see it with blkid but it does show sr0 in lsblk.
Code:
root@ting-nas[~]# blkid
/dev/nvme0n1p2: LABEL_FATBOOT="EFI" LABEL="EFI" UUID="5038-26BD" BLOCK_SIZE="512" TYPE="vfat" PARTUUID="203cb34f-1678-4773-9114-87ec3ec92117"
/dev/nvme0n1p3: LABEL="boot-pool" UUID="4469725695177636301" UUID_SUB="15667677895988747485" BLOCK_SIZE="4096" TYPE="zfs_member" PARTUUID="4731e764-3f91-49d9-8432-b62f26d07d73"
/dev/sdc1: UUID="c8883dba-be7e-c32c-7daa-28663283845e" UUID_SUB="39aa2481-830d-fa1f-bf43-cbe118b09b6f" LABEL="ting-nas.home:swap0" TYPE="linux_raid_member" PARTUUID="4361b18a-387b-43fc-84da-2a13686244dd"
/dev/sdc2: LABEL="NAS" UUID="2768324709600536478" UUID_SUB="7992577992517912951" BLOCK_SIZE="4096" TYPE="zfs_member" PARTUUID="9b95fe01-9fae-43be-ad14-fbeb83da4042"
/dev/sdd1: UUID="c8883dba-be7e-c32c-7daa-28663283845e" UUID_SUB="93b56f14-1320-f02a-61c4-46bedd6adea8" LABEL="ting-nas.home:swap0" TYPE="linux_raid_member" PARTUUID="f71165b5-4038-4563-9069-5a9deb41f129"
/dev/sdd2: LABEL="NAS" UUID="2768324709600536478" UUID_SUB="17252936581636967910" BLOCK_SIZE="4096" TYPE="zfs_member" PARTUUID="a557e20a-7dbd-479d-b335-c85b7bbd3a07"
/dev/sdb1: UUID="f10620f2-ba91-3607-1fc6-ab55cc850756" UUID_SUB="9920f931-a536-2cf6-aa2d-66508ed8ddf1" LABEL="ting-nas.home:swap1" TYPE="linux_raid_member" PARTUUID="9278595c-2aa1-4bfc-a8a8-98b1f701fef0"
/dev/sdb2: LABEL="NAS" UUID="2768324709600536478" UUID_SUB="1287776257302707625" BLOCK_SIZE="4096" TYPE="zfs_member" PARTUUID="cc7132b8-eeae-4934-add8-c54a21d9c885"
/dev/sda1: UUID="f10620f2-ba91-3607-1fc6-ab55cc850756" UUID_SUB="bd779c1e-2178-2bdd-8cbf-9785abb8636d" LABEL="ting-nas.home:swap1" TYPE="linux_raid_member" PARTUUID="c0d97a6b-122e-4e75-bd79-ea8d9af4c66e"
/dev/sda2: LABEL="NAS" UUID="2768324709600536478" UUID_SUB="8221789973209686518" BLOCK_SIZE="4096" TYPE="zfs_member" PARTUUID="414455bb-2328-49fd-b158-8700f8fe9d33"
/dev/mapper/md126: UUID="5cb8fb3a-0ccd-4d5b-a64c-d6a7e05ac723" TYPE="swap"
/dev/mapper/md127: UUID="ad3dbabb-b8ff-4ac0-92f6-5fa3f9528780" TYPE="swap"
/dev/nvme0n1p1: PARTUUID="1172e658-f553-4b2f-a584-f6c7d4415680"
/dev/nvme0n1p4: PARTUUID="cc121db1-49a7-4438-8c60-0e92402d3d4b"
/dev/zd0: PTUUID="7f12503d-983e-4534-b483-a9cb4fbe9f5c" PTTYPE="gpt"
/dev/zd16: PTUUID="7f12503d-983e-4534-b483-a9cb4fbe9f5c" PTTYPE="gpt"
/dev/zd32: PTUUID="7f12503d-983e-4534-b483-a9cb4fbe9f5c" PTTYPE="gpt"
/dev/zd48: PTUUID="7f12503d-983e-4534-b483-a9cb4fbe9f5c" PTTYPE="gpt"
/dev/zd64: PTUUID="7f12503d-983e-4534-b483-a9cb4fbe9f5c" PTTYPE="gpt"
/dev/zd80: PTUUID="7f12503d-983e-4534-b483-a9cb4fbe9f5c" PTTYPE="gpt"

root@ting-nas[~]# lsblk |grep sr0
sr0          11:0    1  1024M  0 rom   
root@ting-nas[~]#


i can disconnect it and reconnect it and i see the dmesg entries.

Code:
root@ting-nas[/dev]# ll -la cdrom
lrwxrwxrwx 1 root 3 Feb 20 20:14 cdrom -> sr0/
root@ting-nas[/dev]# ll -la sr0
total 0
drwxr-xr-x  2 root   40 Feb 20 20:06 ./
drwxr-xr-x 22 root 4100 Feb 20 20:14 ../


Links seem accurate?

It won't mount manually either.
Code:
root@ting-nas[~]# mount /dev/sr0 /dev/cdrom
mount: /dev/sr0: /dev/sr0 is not a block device.
root@ting-nas[~]# 


it isn't in fstab, but i'm not sure it has to be there or what values to put in there either. Seemingly that no longer used to mount things

It was working until a reboot today. Reboot was just to move some other equip. I literally used the drive this morning without issue. The drive on another PC works fine. I'm at a lose and being a none Linux guy makes it even harder.

Any ideas? Nothing in search seems to help. Again i'm a newbee so i apologize upfront.
 

Arwen

MVP
Joined
May 17, 2014
Messages
3,611
Well first, BlueRay discs are not general purpose file storage. Yes, they contain UDF file systems, but those may not be included in the TrueNAS SCALE kernel build out. So you would not be mounting it / them.

Next, while it has been many months since I used MakeMKV, (on my Linux desktop), it does not require an optical disc to be mounted, for it to work on the disc. Have you tried to launch MakeMKV?

Last, you probably have an optical disc inserted, but make sure you do.
 

blindguynar

Cadet
Joined
Feb 20, 2023
Messages
7
1. It was working on truenas scale just this morning so i feel its included.

2. I want the Blueray Drive to back up my dvd collection with makemkv. So i need to pass sr0 into the app. Well truth be told i tried it as an app over the last few weeks and that worked until todays reboot. Tonight i tried it as a vir machine and that too has same result even though UI lets me add it to the VM.

3. Yes

And thank you for your suggestions. High learning factor within the last couple weeks!
 

Arwen

MVP
Joined
May 17, 2014
Messages
3,611
Hmm, I just thought of something. You seem to have "/dev/sr0" as a directory. This is wrong. It should be a device file.

My suggestion is to do this;
  1. Power off your USB Optical drive
  2. Wait a minute or 2
  3. Run this command as user "root":
    rmdir /dev/sr0
  4. If you get any errors, make a note and put them here in the forum thread. Don't continue.
  5. Power on your USB Optical drive
  6. When you can, install a DVD or BlueRay optical disc in it
  7. Wait a minute
  8. Perform this command and put output it in a forum thread response:
    ls -ld /dev/sr0
Let me know if their is any change. Good luck.


By the way, this should not work unless you have special mount parameters. Nor should it be necessary. MakeMKV should read the RAW device at "/dev/sr0". And you are not giving a valid mount point, which is a directory not in "/dev/".

root@ting-nas[~]# mount /dev/sr0 /dev/cdrom mount: /dev/sr0: /dev/sr0 is not a block device.
 

blindguynar

Cadet
Joined
Feb 20, 2023
Messages
7
1. i receive no errors on the rmdir /dev/sr0 as root
2. Power on shows drive connecting with same messages as above.
3. Inserting a disk gives following errors to dmesg
Code:
[45005.758093] blk_update_request: I/O error, dev sr0, sector 2048 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 0
[45005.758847] Buffer I/O error on dev sr0, logical block 512, async page read
[45007.425623] sr 7:0:0:0: [sr0] tag#0 FAILED Result: hostbyte=DID_OK driverbyte=DRIVER_OK cmd_age=0s
[45007.428771] sr 7:0:0:0: [sr0] tag#0 Sense Key : Illegal Request [current]
[45007.431059] sr 7:0:0:0: [sr0] tag#0 Add. Sense: Read of scrambled sector without authentication
[45007.431839] sr 7:0:0:0: [sr0] tag#0 CDB: Read(10) 28 00 00 00 04 00 00 00 02 00
[45007.432590] blk_update_request: I/O error, dev sr0, sector 4096 op 0x0:(READ) flags 0x80700 phys_seg 1 prio class 0
[45007.470082] sr 7:0:0:0: [sr0] tag#0 FAILED Result: hostbyte=DID_OK driverbyte=DRIVER_OK cmd_age=0s
[45007.471350] sr 7:0:0:0: [sr0] tag#0 Sense Key : Illegal Request [current]
[45007.472744] sr 7:0:0:0: [sr0] tag#0 Add. Sense: Read of scrambled sector without authentication
[45007.474187] sr 7:0:0:0: [sr0] tag#0 CDB: Read(10) 28 00 00 00 04 00 00 00 01 00
[45007.475594] blk_update_request: I/O error, dev sr0, sector 4096 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 0
[45007.477115] Buffer I/O error on dev sr0, logical block 1024, async page read


Tried other disk and same resultant messages.

4. result of ls
Code:
root@ting-nas[~]# ls -ld /dev/sr0
brw-rw---- 1 root cdrom 11, 0 Feb 21 08:35 /dev/sr0
root@ting-nas[~]# 
 

blindguynar

Cadet
Joined
Feb 20, 2023
Messages
7
Since it's so easy i tried a "hale mary" pass and reloaded the boot device with a fresh Truenas Scale copy. (exported pool, backed up config, and reloaded). Then imported pool and reloaded configs in UI. It did not help / solve the issue.

i thought maybe a hardware issue on that usb port or cord, but replaced cord and switched usb ports with no resolution. Other USB devices work in that same port.

i had been running it in an truecharts app by adding it as an additional resource. In virtualization i saw i could add the drive as a usb device so the UI sees it, but it doesn't pass on to the VM. I can pass other usb devices (usb zigbee dongle) into VM's using this method with success.

I'd really think the "non-supported" route if i had never used it before, but it was literally working pre-reboot yesterday morning.

Very frustrating ...
 

Arwen

MVP
Joined
May 17, 2014
Messages
3,611
Well, at least this looks better;

root@ting-nas[~]# ls -ld /dev/sr0 brw-rw---- 1 root cdrom 11, 0 Feb 21 08:35 /dev/sr0

Supported verses working are 2 different things. TrueNAS SCALE is a targeted NAS OS based on Linux. While some things may work, they would not be "supported" / "supportable". If the documentation does not say it works, then it is not "supported".

That said, yes it would be nice if it worked.


One other thing. My own LG Blue-Ray USB3 drive does not like my Linux desktop's USB3 ports. But works perfectly fine on a USB 2 port. Even seems to work at a good speed. If you have not already tried a USB 2 port, please do do.


Also, I would ignore the dmesg errors and see if it works. I've seen odd errors on my setup, (but Linux desktop, not SCALE), however they did not seem to impact video extraction.
 
Top