You can’t. It’s not associated with your terminal.
Foreground/background and associated/not associated with terminal are distinct concepts. A foreground process simply means that the shell is waiting for its termination. Normally it would be associated with your current shell terminal, but even that can be detached from by the process. So the two dimensions don’t necessarily have any connection.
If you want to run a job which you may want to check up on later, take a look at the “screen” program which allows you to set up a terminal shell which can be detached from and reattached to at will, even from some other login.
Keep in mind that will get you STDOUT but not STDERR, just in case you
want to see things that are not going nto STDOUT (like errors).
Good luck.
jschleede wrote:
> ok, i know screen.
> i helped me with:
>
> Code:
> --------------------
> tail -f /proc/1234/fd/1
> --------------------
>
> Now i can see, what the script do.
>
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org