How to fix "No such file or directory" error message on terminal wget download I am installing files with wget onto an external hard drive. Someone walked by, tripped, and disconnected my hard drive briefly. However, now my file download says: "no such file or directory" for each file, and then continues. I have paused the process, exited and re-entered the directory, but I've had no luck. Is there a way to restart the download without getting an error message
If a hard disk is disconnected while it is being written to, you need to do a few things before you can use it again. This also depends on which format was used on the hard disk.


Connect the hard disk
Start the Disk Utility
Find the external hard disk on the left hand side of the disk utility and right-click (or control-click) on it
Select 'Run First Aid', then when it asks you if you want to run First Aid, click 'Run'
Allow the process to run to completion.
After it has finished, if there were no errors on the disk, everything is fine. You can then continue. If there are errors on the disk, then you probably need to delete the file you were trying to download and start the download again.


If there were no errors, you can continue an interrupted download in wget by using the -c flag, for example:

wget -c https://example.com/file.ext


Best of luck! And keep your cables out of the way of anyone who might be walking past :)