whta is the use of "exec" command?
Answer / ashu
The exec command will execute a command in place of the
current shell; that is, it terminates the current shell and
starts a new process in its place.
Use of exec command:
exec is oftenly used to execute the last command of a shell
script. This would kill the shell slightly earlier;
otherwise, the shell would wait until the last command was
finished. This practice saved a process and some memory.
| Is This Answer Correct ? | 2 Yes | 0 No |
What is the use of "$?" Sign in shell script?
What's the difference between scripting and coding?
How would you replace the n character in a file with some xyz?
What is meant by $1 in shell script?
What is path variable bash?
What does echo $0 do?
Please anyone suggest atleast 2 good training institutes in Hyderabad, INDIA where i can learn unix shell scripting.
Explore about environment variables?
Script S1 (which copies .dat files from one directory1 to another directory2) run continuously. Write Script S2 which kills S1 first, compresses all .dat files in directory1 and directory2 successfully, re-run Script S1 and stops self i.e. S2.
Why are shell scripts used?
Write a shell script to get current date, time, user name and current working directory.
What is the difference between a 'thread' and a 'process'?