This script will unmount the problematic drive and try to mount it to another place /tmp/myprecious, a temporary place.
Then, as it says, will attempt to read and then write to the drive.
Finally, it removes the file it wrote to test writeability, unmounts the drive again and removes the temporary mount place.
The scripts needs root access to mount and unmount and possibly to write and read.
Please don’t run a script you found on the internet with root access without knowing what it does.
This script will unmount the problematic drive and try to mount it to another place
/tmp/myprecious
, a temporary place. Then, as it says, will attempt to read and then write to the drive. Finally, it removes the file it wrote to test writeability, unmounts the drive again and removes the temporary mount place. The scripts needs root access to mount and unmount and possibly to write and read.Please don’t run a script you found on the internet with root access without knowing what it does.
This is some very good advice, OP!