I got a Pi4 and an SSD about a month ago and once setup, have had continual problems with it becoming unresponsive. I now believe this to be a DietPi problem.
The SSD is setup using dietpi-drivemanager with rootfs mounted on the SSD (excellent feature BTW); booting from SD Card.
The system will run for a while until it appears to lose contact with the USB mount point. At this time, if an SSH session is connected, the session will appear to work but any command issued returns an error of ‘Command Not Found’ or an IO error. It is not possible to open a new SSH session, it returns a network error. It is impossible to reboot from the command line and the only option is to remove the power supply. On plugging the power back in, the device will then reboot and run for a while.
I have attempted to run a journalctl command in an SSH session to capture any kernel or other errors but nothing appears. I have also persisted the journal log, but again, nothing to indicate what the issue is.
The original point of concern for me was Home Assistant installed as a Generic HassIO setup (so everything in docker containers). I was also running pywws (a python script to extract weather station data). I gradually switched these things off to reduce the IO, but still the problem persisted - after a short while (20 minutes or so) the device would become unresponsive.
Next step in the investigation was to use a WD PiDrive as I have seen that there are sometimes issues with SSD drives. I’d been using the PiDrive for about 3 years without any bother in exactly the same configuration (rootfs on PiDrive - Boot from SD). However, I experienced exactly the same issues. It has occurred to me if it was the boot SD, but I remembered this system was built using a different SD card.
So I have tried 2 different drives with the Pi4 - same issue.
Next step was to try the PiDrive with a Pi3 B+ - this was the device that has been running a DietPi Stretch image for quite a while. I cannot honestly remember what the last update I had done to this device. I simply moved the SD card across, plugged in the drive and re-booted. However, it again died in the same manner within a short period of time.
I have now built a Raspbian based Pi4 setup with the original SSD, manually moved the rootfs and it is quite happily sitting here chugging away.
My conclusion, therefore, is that there is an issue with the DietPi Buster setup with rootfs on an SSD.