Linux/Unix Commands





Español Français 中文 Deutsch Portuguese Japanese nederlands
   
 
LINUX / UNIX cmd
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Introduction
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in A
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in B
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in C
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in D
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in E
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in F
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in G
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in H
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in I
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in J
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in K
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in L
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in M
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in N
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in P
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in R
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in S
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in T
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in U
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in W
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Commands in Y
Forums Ask your doubts
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example More about Linux
LINUX/UNIX Commands tutorial/reference - Find linux cmd, syntax, example Feedback
 





bg Linux Commands


Tutorials Linux-commands

Topic

What is Linux bg Command?



Explanation

bg COMMAND:
     bg command is used to place a job in background. User can run a job in the background by adding a "&" symbol at the end of the command.

SYNTAX:
  The Syntax is
     bg [options] [job]

OPTIONS:
     
-l Report the process group ID and working directory of the jobs.
-p Report only the process group ID of the jobs.
-x Replace any job_id found in command or arguments with the corresponding process group ID, then execute command passing it arguments.
job Specifies the job that want to run in the background.



EXAMPLE:
     
  1. To Run a process in background
    kmail- start the email client application.
    
    Press ctrl+z to stop the current job.

    Now just type bg to move last stopped job to background.

  2. To move the specified job to back ground:

    Lets start some three jobs and suspend those process in background.

    kmail- start the email client application.
    Press ctrl+z to stop the current job.
    xmms- music player application.
    Press ctrl+z to stop the current job.
    sleep 120- a dummy job.
    Press ctrl+z to stop the current job.
    jobs
    The above command will display the jobs in the shell.
    [1]   Stopped                 kmail
    [2]-  Stopped                 xmms
    [3]+  Stopped                 sleep 120
    
    bg 2
    The above command will start running the xmms application. In such way you can start running the specific background process.
    jobs
    [1]-  Stopped                 kmail
    [2]   Running                 xmms &
    [3]+  Stopped                 sleep 120
    




A Note

Find LINUX Commands... Hope you enjoy this tutorial. We welcome your Valuable feedbacks or suggestions on this LINUX / UNIX cmd reference. This is a copyright content.


Other Links

web hosting

 

Free Hosting

Top Hosting Companies