I have normal user in CentOS 7 whose name is "mostafa" (the name of the account).
I naturally have another user called root with all privileges. User "mostafa" is put into sudoers file, too.
The OS is installed in VmWare, so the system is all mine.
Now I create a file with touch file.sh and put a command in it, but when I want to run it with
, an error is shown that the command
does not exist. But if I
sudo chmod 777 ./file.sh
then it gets run. My question is that, why should I use
when I myself have created the file, and I am in sudoers.
Can anyone explain me why shuold I still use
when the creator of the file is me.