External SSD disconnects at night w/ error notification about not being ejected properly
I have an external SSD (Samsung 8TB SSD in a Cable Matters Thunderbolt 3 case) that I use for my Photos library.
Recently upgraded to a Mac Studio M2 Max running Ventura 13.5.
It seems like every night, the SSD unmounts, and I come back to an error saying that the SSD was ejected improperly. However, it is plugged in and the drive shows up.
I tried replacing the Thunderbolt cable with a new Thunderbolt 4 cable, no change.
The drive is plugged into one of the 4 rear ports. I do not have this problem with a second SSD plugged into one of the front ports.
I've checked settings to make sure that I don't have it set to put hard drives to sleep. Is there some other setting I am missing? This is a fairly critical problem because putting the drive away this way risks damaging my photo library *and* it gets in the way of my nightly backups.
Mac Studio