Skip to content

Tag: stdout

How to view stdout in AWS environment?

Below is the lambda function: executed with NodeJS runtime ( as serverless app) that writes the incoming event record to stdout By definition, console.log prints to stdout, as mentioned here, but I need to go through cloud watch logs, as this is AWS serverless app: What is the correct way to view stdout in AW…

Using unbuffered pipe as “dummy” file output

I’ve been dealing with a weird issue that I can’t find a way to solve. My situation is as follows. I have an application in python called “app1”, that requires a file for outputting the results of it’s execution. I have a secondary application, called “app2”; a binary…

how to output only when command finish

I’m running multiple commands using &: This doesn’t work well because the output lines are interleaved. I want each curl to hold its output, until it’s done. How to do that? I understand I can use temp files, concat together and delete afterwards. Are there better ways? Answer You could …

Why cat 0>file doesn’t work

In Unix, I know that 0 1 and 2 represent stdin stdout and stderr. As my understanding, the command cat meaning “concatenate” can concatenate different files. For example, cat file>&1 can concatenate the file and the stdout and the arrow means the redirection from the fileto the stdout, so w…

Redirecting stdout and stderr to a file in c++

I am trying to redirect stdout and stderr to a log file. This is what i am doing. But still i am missing out some of the logs. I came to know that when i executed my application commenting out these lines of code. I am dubious about this code snippet. Please provide your feedback on this. Answer first close