How to make the background process run back to the foreground in Linux

Time:2019-11-8

How to make the background process run back to the foreground in Linux

WeChat public address:51 yards of rural network
Professional programming Q & a community
www.51manong.com

For example, using characters & running a script in the background, how can I get this process back to the foreground?

[[email protected] ~]#  51mn.sh  &
[1] 5821

First, use the jobs command to view the running jobs

[[email protected] ~]#  jobs
[1] + Running   51mn.sh

Then use the FG command, followed by a percentage symbol and job number

[[email protected] ~]#  fg %1
51mn.sh

At this time, the process has returned to the foreground to run. Press ctrl-c to terminate the 51mn.sh command

Recommended Today

The use of progressbarcontrol, a progress bar control of devexpress – Taking ZedGraph as an example to add curve progress

scene WinForm control – devexpress18 download installation registration and use in vs: https://blog.csdn.net/BADAO_LIUMANG_QIZHI/article/details/100061243 When using ZedGraph to add curves, the number of curves is slower if there are many cases. So in the process of adding curve, the progress needs to be displayed, and the effect is as follows     Note: Blog home page:https://blog.csdn.net/badao_liumang_qizhi […]