job_id-How to find job_id of a running process
Hello,
How to find job_id of a process bg'ed.i mean how to get the job_id for running "fg" command? I tried pid,but fg command insists on job_id.please help me which command will display job_id. thanks :) |
jobs is a shell internal which lists running jobs controlled by that shell.
|
now how do i use fg and bg without job_id :? for eg; i invoked firefox from terminal without "&".now if i want to detach the process from shell,how can we achieve it :? i am aware of pid,but job id is something new for me :) thanks,waiting for reply :-|
|
A job is a concept which is only meaningful inside the shell. Please read the JOB CONTROL section of the bash manual page for an overview (search for upper case JON CONTROL).
When a shell is closed, any backgrounded jobs attached to that terminal are send a signal SIGHUP (hang up). Most programs will terminate when they receive this signal. A program may choose to do something else other than terminate on receiving SIGHUP. At least in Ubuntu, firefox seems to be one of these, so you can just bg the process and then close the terminal. For programs which terminate when you close the terminal which they are attached to, you have a few options:
|
yes.your explanation is what i needed ATM!thanks!:) and i am doubting with epiphany browser only! :D
|
All times are GMT -5. The time now is 01:01 PM. |