Error content
When running the model, I encountered the following error:
-bash: sudo: command not found
It probably means that sudo
the relevant command was not found. Since the server I am using is brand new, and the relevant environment and commands are not pre-configured, there is a high probability that this is the problem.
Error resolution
First enter this line of command:
find /etc/sudoers.d
The meaning of this line of command is to go to etc
this folder to find if there is sudoers.d
such a file.
Usually there are two return results after input:
(1) Return No such file or directory
, which means that we have not installed sudo
, so there is no sudoers.d
such file. It can be installed with the following command:
apt-get install sudo
(2) Return E: Unable to locate package sudo
, which means sudo
it exists, but cannot be found. At this time, just use the following command to update:
apt-get update
The update update is also a solution to many related error reports. If you are in doubt, you can update it directly~