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.
Answer Posted / ganesh
Hi Vipul,
Script1 have to run continuously.. So,
Script1 should be
#!bin/sh
while true
do
cp directory1/*.dat directory2/
done
Is This Answer Correct ? | 10 Yes | 1 No |
Post New Answer View All Answers
Is cmd a shell?
Determine the output of the following command: name=shubham && echo ‘my name is $name’.
I have 2 files and I want to print the records which are common to both.
What can scripts do?
How do we delete all blank lines in a file?
How do you create a shortcut in linux?
Give some situations where typing error can destroy a program?
Suppose you execute a command using exec, what will be the status of your current process in the shell?
how to get part of string variable with echo command only?
How to find all the files modified in less than 3 days and save the record in a text file?
What is a shell environment?
How does path variable work?
What does chmod do?
What is the first line in every perl script called?
What is a program shell?