On that day I received an email from a person asking me how to recover EFI files, yes those that are stored in the path:
According to the person, the system had created the directory in the path:
/boot/grub/x86_64-efi and the grub of a second system was trying to find it in
/boot/efi, so she decided to create a symbolic link to try solve the problem:
Only that did not solve it and she decided to remove the symbolic link with the following command:
What happens is that the
/boot/grub/x86_64-efi directory has not been removed, but the files have! 😱
If you create a test there on your system with directories in your
/home/$USER/ just for that, you will realize that this is really what will happen!
And how to avoid this?
Well, the measure to be taken so that this does not happen is to use the command
unlink before removing. Take her example as an example.
First, it should “remove the link” the directory, like this:
And only after that use the
Sometimes (just, sometimes, don’t get used to it), simple solutions avoid complex problems!