1

An application is already running without command output, only GUi.

How can I grab the application's command output from a new terminal window?

Another application is already running as CLi, but I would like to monitor that specific application from a different window or even remotely without affecting the application itself?

neverMind9
  • 1,690
  • 1
    Is it a type of application that generates log files? Do you only want to know how to do this when applications are already running, or is a case where you know beforehand alright as well? – Academiphile Jan 21 '18 at 04:45

1 Answers1

2

This is very complicated for a running application. You need to attach a debugger, close the file descriptors 0, 1, and 2, open a new controllingf terminal and open the file descriptors accordingly. Probably not even this works if the app notices that it does not have a controlling terminal and thus does not use stdin, stdout, and stderr the usual way, maybe even has closed them and used them for different purposes.

Hauke Laging
  • 90,279