![]() |
How to run a shell script in a background?
Dear Folks,
I wanted to run a particular shell program in a background, how do we do that... i have another query also, that is how to find a creation date of the file.. Thanks in advance.. Thanks and Regards, V.Anand, Bangalore. |
but an & at the end of the command to run it in background
like ./myscript& this will keep your terminal free and command will keep running in background I am not sure about the file creation date, may be someone else can help |
Quote:
|
Note that for most commands, if you run them in the background using the & after the command, they will terminate when the terminal is closed. This is because the operating system sends the SIGHUP (hang up) signal to background jobs when a terminal closes, and mos programs terminate on receipt of this signal.
You can prevent the signal from getting to the program by starting it like this: Code:
nohup command &As for the time, unix-like filesystems do not store the creation time for files. You have three time stamps to choose from:
Code:
stat -c %y filename |
| All times are GMT -5. The time now is 06:19 PM. |