[libvirt] [PATCH] parallels: suppress console output from parallels SDK
Maxim Nestratov
mnestratov at virtuozzo.com
Tue May 26 17:04:25 UTC 2015
26.05.2015 18:01, Daniel P. Berrange пишет:
> On Tue, May 26, 2015 at 05:57:41PM +0300, Maxim Nestratov wrote:
>> It is necessary to have unpolluted screen when connecting to
>> parallels driver via virsh.
>> Otherwise a lot of unexpected output one will get on the console.
>>
>> Signed-off-by: Maxim Nestratov <mnestratov at parallels.com>
>> ---
>> src/parallels/parallels_sdk.c | 3 +++
>> 1 file changed, 3 insertions(+)
>>
>> diff --git a/src/parallels/parallels_sdk.c b/src/parallels/parallels_sdk.c
>> index 542e09e..b717ccf 100644
>> --- a/src/parallels/parallels_sdk.c
>> +++ b/src/parallels/parallels_sdk.c
>> @@ -205,6 +205,9 @@ prlsdkInit(void)
>> {
>> PRL_RESULT ret;
>>
>> + /* Disable console output */
>> + PrlApi_SwitchConsoleLogging(0);
> Does the SDK logging ever produce anything that would be useful when
> troubleshooting libvirt ?
>
> If so, you might be better to protect this with
>
> if (virGetEnvBlockSUID("LIBVIRT_PARALLELS_DEBUG") == NULL)
> PrlApi_SwitchConsoleLogging(0);
>
> IOW, so people can do
>
> LIBVIR_PARALLELS_DEBUG=1 virsh ....
>
> if they need to see debugging info
>
> Regards,
> Daniel
Actually these debug output can be helpful but as soon as they are
written to /var/log/parallels.log by default and duplicated to the
console, I think it is not necessary to keep them in two places.
Maybe it's worth mentioning this in commit message.
Best,
Maxim
More information about the libvir-list
mailing list