how to find what is printed to the UNIX STDOUT

Hello,

how to find what is printed to the UNIX STDOUT?

Thanks
bibi92Asked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
Patrick BogersConnect With a Mentor Datacenter platform engineer LindowsCommented:
Hi

Not totally confident i understand the question, you want to know what has been printed to the stdout?

A command like    cat /dev/stdout -less

Will show you its content. OR am i missing the issue here?
0
 
ozoCommented:
> stdout.log
0
 
bibi92Author Commented:
yes, I want to know what has been printed to the stdout
0
Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 
bibi92Author Commented:
cat: 0652-050 Cannot open /dev/stdout.
cat: 0652-050 Cannot open -less.
0
 
ozoCommented:
stdout will be what is printed on the screen.
If you want to see what was printer their earlier, scroll up.
If you want to capture what what a command prints, redirect it to a file or logger
command | tee command.log
0
 
Patrick BogersDatacenter platform engineer LindowsCommented:
If you cannot open the file you probably have no forwarder in place and then standard output is printed to the screen.
0
 
SurranoSystem EngineerCommented:
You can always check whichever process you want if you know the pid (e.g. $MYPID)

tail -f /proc/$MYPID/fd/1 # stdout
tail -f /proc/$MYPID/fd/2 # stderr

Open in new window


But it'll show only future output, not past output.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.