lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <54815200.4040807@hitachi.com>
Date:	Fri, 05 Dec 2014 15:34:40 +0900
From:	Masami Hiramatsu <masami.hiramatsu.pt@...achi.com>
To:	Namhyung Kim <namhyung@...nel.org>
Cc:	Steven Rostedt <rostedt@...dmis.org>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Theodore Tso <tytso@....edu>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Ingo Molnar <mingo@...nel.org>
Subject: Re: [PATCH 2/2] ftracetest: Add --verbose option for showing echo
 output

(2014/12/05 14:52), Namhyung Kim wrote:
> On Fri, Dec 05, 2014 at 02:23:23PM +0900, Masami Hiramatsu wrote:
>> (2014/12/05 14:08), Namhyung Kim wrote:
>>> On Thu, Dec 04, 2014 at 02:41:23PM -0500, Masami Hiramatsu wrote:
>>>> Add --verbose/-v option for showing echo output in testcases.
>>>> This is good for checking the progress of testcases which
>>>> take a longer time to run.
>>>>
>>>> To implement this feature, all the testcase failures are
>>>> captured in ftracetest and send signal to set SIG_RESULT=FAIL.
>>>>
>>>> Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@...achi.com>
>>>> ---
>>>
>>> [SNIP]
>>>> -  # setup PID and PPID, $$ is not updated.
>>>> -  (cd $TRACING_DIR; read PID _ < /proc/self/stat ;
>>>> -   set -e; set -x; . $1) >> $testlog 2>&1
>>>> -  eval_result $? $SIG_RESULT
>>>> +  if [ $VERBOSE -ne 0 ]; then
>>>> +    __run_test $1 2>> $testlog | tee -a $testlog
>>>
>>> Shouldn't it be
>>>
>>>        __run_test $1 2>&1 | tee -a $testlog
>>>
>>> ?
>>
>> No, that outputs both stdout and stderr to $testlog and console.
>> What I'd like to do above is only stdout to $testlog and console and
>> stderr goes only to $testlog. (Note that __run_test set -x which outputs
>> every executed command to stderr)
> 
> Hmm.. so the actual output of the failing command is not shown on
> console even when -v option is given, right?

No, if a command fails, the testcase is automatically terminated
(by set -e) and $testlog is dumped on console, so that tester can
trace back the log.

> Anyway I worried about that the order of messages might be mixed..
> 
>   echo msg1 > /dev/stdout
>   echo msg2 > /dev/stderr
>   echo msg3 > /dev/stdout
>   echo msg4 > /dev/stderr
> 
> So the output in this case can be like msg2, msg4, msg1, and msg3..?

I'm not sure this can happen... Would you have any other good way to
solve this?

Thank you,

-- 
Masami HIRAMATSU
Software Platform Research Dept. Linux Technology Research Center
Hitachi, Ltd., Yokohama Research Laboratory
E-mail: masami.hiramatsu.pt@...achi.com


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ