Guys- I'm trying to learn to script with sh.
I thought it would be a good idea to do this in a jail so as not to destroy anything on my server, so I have created a vanilla jail with the GUI, added storage to it via the GUI.
Back to windows, I have created a script "t.sh" in the folder that is mounted in the test jail.
Next i have SSH'ed into the jail as root and i can see my script. I have given it 777 permissions and set the owner to root.
root@testscripting:/mnt/test # ls -l
total 9
-rwxrwxrwx 1 root 1001 466 Sep 24 12:20 t.sh
However, the script won't run:
root@testscripting:/mnt/test # ./ t.sh
./: Permission denied.
I thought it would be a good idea to do this in a jail so as not to destroy anything on my server, so I have created a vanilla jail with the GUI, added storage to it via the GUI.
Back to windows, I have created a script "t.sh" in the folder that is mounted in the test jail.
Next i have SSH'ed into the jail as root and i can see my script. I have given it 777 permissions and set the owner to root.
root@testscripting:/mnt/test # ls -l
total 9
-rwxrwxrwx 1 root 1001 466 Sep 24 12:20 t.sh
However, the script won't run:
root@testscripting:/mnt/test # ./ t.sh
./: Permission denied.