Disk errors and, generally speaking, general hardware / system errors are usually not handled properly in any application. The database should provide the highest possible strength in such scenarios, and the correct behavior is to disconnect and break as little as possible.
As for your application - if you cannot connect to the database, there is no difference in what caused the error. The application will not work.
There are special tools that can control your computer, i.e. Nagios . If you are the administrator of this server, use such applications. When the disk is full, you will receive an email or text. Use such tools and do not break the open door, introducing several hundred lines of code to handle random and very rare situations.
source share