[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#33292: Piped log program failed unexpectedly when using sed with Apa
From: |
Assaf Gordon |
Subject: |
bug#33292: Piped log program failed unexpectedly when using sed with Apache at windows |
Date: |
Tue, 6 Nov 2018 10:51:22 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 |
tags 33292 moreinfo
stop
Hello,
On 2018-11-06 10:42 a.m., Assaf Gordon wrote:
Bug report forwarded from
From github https://github.com/agordon/sed/issues/1
and/or stackoverflow https://stackoverflow.com/q/53118038
Vikram Singh writes:
====
I am using sed to mask some data in proxy logs of Apache at windows.
Putting command in httpd.conf file is :
CustomLog "|$'C:/Program Files (x86)/GnuWin32/bin/sed' -i
's/password=[^ ]*/password=masked/' 'logs/proxy-access.log'" combined
The GnuWin32 version is sed is not maintained by us, so we can't
directly help with it.
There were alos some windows-related improvements recently,
if you could test a newer version that would be very useful.
Lastly,
The command seems weird at a cursory look:
Using "|" means you are piping into sed (and expecting sed to output
the data to STDOUT). but using "sed -i" is "replace --in-place",
meaning it will read the "logs/proxy-access.log" and update it without
reading anything from STDIN or writing anything to STDOUT.
Is that intentional?
on starting Apache service command prompts start opening and closing and
in error.logs found exception i.e :
AH00106: piped log program ''C:/Program Files (x86)/GnuWin32/bin/sed' -i
's/password=[^ ]*/password=masked/' 'C:/Apache24/logs/proxy-access.log''
failed unexpectedly
apache logging sed proxy
===
"failed unexpectedly" is not a sed error - another program generates it
(apache?) - so it isn't clear what is failing and how.
Can you provide more details?
regards,
- assaf