On Sun, 21 Aug 2022 at 17:36, James Dutton <james.dutton@xxxxxxxxx> wrote: > > On Sun, 21 Aug 2022 at 15:47, Alan Stern <stern@xxxxxxxxxxxxxxxxxxx> wrote: > > > > > The reason being, I have a system that boots from a USB disk. > > > Due to interference, the USB device disconnects for a second or two > > > and then comes back, but Linux does not see it and I have to reboot > > > Linux to recover. So, in this situation I wish Linux to be able to > > > recover immediately, without needing a reboot. > > > > There is no way to do this. For example, consider all those failed > > writes that you get error messages about. Once they have failed, the > > system does not try to remember them in case there's a possibility of > > trying them again later. They're just lost. > I guess the solution would have to include a "retry in 1 second's > time" type failure mode, instead of just lost. > I.e. differentiate between the disk responding that the media failed, > and the link being down to the disk so the write message could not be > sent. > For example, NFS waits around for the network to return, maybe we > could add that functionality between a filesystem and usb storage. As a side note, I have seen USB links failing. Normally just to something like a keyboard or mouse, so it just comes back without the user knowing anything was wrong. The problem is USB links to disks don't recover currently.