Ctrl-C kills background process also
Hi ,
I am working on uClinux 2.4.24 on ARM processor. Whenever I run some application in background (unsing "&" , for eg "ping 172.16.3.119 &")and press Ctrl-C , the background process also gets killed. To my understanding Ctrl-C must kill only the foreground process. What do i do so that Ctrl-C will not kill my background process. Niraj |
Try the command: `nohup`
So you run it like this: nohup some_command Output will go to a file called nohup.out --Shaun |
Thanks shaun
But there is no "nohup" command for my uClinux. Or else i will have to get source code for that command , compile it for my ARM processor (ARM ELF big-endian executable) and then use it. Any other way... |
Do you have the command: `setsid` ?
That seemed to work for me also. If you don't have that, then the only other thing I can think of is to write a wrapper around the commands that you are using and trap ctrl-c. I would use this is a last resort though. --Shaun |
All times are GMT -5. The time now is 11:43 PM. |