Powershell: Verbose Syslog logging + GUID directory created for PowerShell Script Execution on Ubuntu1604

Created on 6 Mar 2018  路  13Comments  路  Source: PowerShell/PowerShell

It appears that PowerShell Core creates some pretty verbose logging into syslog on Ubuntu1604, as well as created a GUID directory in /tmp during script execution.

Syslog messages:

Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:1:10) [Perftrack_ConsoleStartupStart:PowershellConsoleStartup.WinStart.Informational] PowerShell console is starting up
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:6:11) [Provider_Lifecycle:ProviderStart.Method.Informational] Provider Alias changed state to Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = #012        Runspace ID = #012        Pipeline ID = #012        Command Name = #012        Command Type = #012        Script Name = #012        Command Path = #012        Sequence Number = 1#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:6:11) [Provider_Lifecycle:ProviderStart.Method.Informational] Provider Environment changed state to Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = #012        Runspace ID = #012        Pipeline ID = #012        Command Name = #012        Command Type = #012        Script Name = #012        Command Path = #012        Sequence Number = 2#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:6:11) [Provider_Lifecycle:ProviderStart.Method.Informational] Provider FileSystem changed state to Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = #012        Runspace ID = #012        Pipeline ID = #012        Command Name = #012        Command Type = #012        Script Name = #012        Command Path = #012        Sequence Number = 3#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:6:11) [Provider_Lifecycle:ProviderStart.Method.Informational] Provider Function changed state to Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = #012        Runspace ID = #012        Pipeline ID = #012        Command Name = #012        Command Type = #012        Script Name = #012        Command Path = #012        Sequence Number = 4#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:6:11) [Provider_Lifecycle:ProviderStart.Method.Informational] Provider Variable changed state to Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = #012        Runspace ID = #012        Pipeline ID = #012        Command Name = #012        Command Type = #012        Script Name = #012        Command Path = #012        Sequence Number = 5#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:1:11) [Engine_Lifecycle:EngineStart.Method.Informational] Engine state changed from None to Available.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = #012        Command Name = #012        Command Type = #012        Script Name = #012        Command Path = #012        Sequence Number = 6#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStart.Method.Informational] Command Import-Module is Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 1#012        Command Name = Import-Module#012        Command Type = Cmdlet#012        Script Name = #012        Command Path = #012        Sequence Number = 7#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStart.Method.Informational] Command Out-Default is Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 1#012        Command Name = Out-Default#012        Command Type = Cmdlet#012        Script Name = #012        Command Path = #012        Sequence Number = 8#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStop.Method.Informational] Command Import-Module is Stopped.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 1#012        Command Name = Import-Module#012        Command Type = Cmdlet#012        Script Name = #012        Command Path = #012        Sequence Number = 9#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStop.Method.Informational] Command Out-Default is Stopped.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 1#012        Command Name = Out-Default#012        Command Type = Cmdlet#012        Script Name = #012        Command Path = #012        Sequence Number = 10#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:1:10) [Perftrack_ConsoleStartupStop:PowershellConsoleStartup.WinStop.Informational] PowerShell console is ready for user input
Mar  5 11:35:16 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStart.Method.Informational] Script execution is Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 2#012        Command Name = #012        Command Type = Script#012        Script Name = #012        Command Path = #012        Sequence Number = 11#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStart.Method.Informational] Command prompt is Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 2#012        Command Name = prompt#012        Command Type = Function#012        Script Name = #012        Command Path = #012        Sequence Number = 12#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStop.Method.Informational] Command prompt is Stopped.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 2#012        Command Name = prompt#012        Command Type = Function#012        Script Name = #012        Command Path = #012        Sequence Number = 13#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStop.Method.Informational] Script execution is Stopped.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 2#012        Command Name = #012        Command Type = Script#012        Script Name = #012        Command Path = #012        Sequence Number = 14#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStart.Method.Informational] Command PSConsoleHostReadline is Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 3#012        Command Name = PSConsoleHostReadline#012        Command Type = Function#012        Script Name = #012        Command Path = #012        Sequence Number = 15#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStart.Method.Informational] Command Set-StrictMode is Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 3#012        Command Name = Set-StrictMode#012        Command Type = Cmdlet#012        Script Name = /opt/microsoft/powershell/6.0.1/Modules/PSReadLine/PSReadLine.psm1#012        Command Path = #012        Sequence Number = 16#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStop.Method.Informational] Command Set-StrictMode is Stopped.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 3#012        Command Name = Set-StrictMode#012        Command Type = Cmdlet#012        Script Name = /opt/microsoft/powershell/6.0.1/Modules/PSReadLine/PSReadLine.psm1#012        Command Path = #012        Sequence Number = 17#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStart.Method.Informational] Command Import-Module is Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 5#012        Command Name = Import-Module#012        Command Type = Cmdlet#012        Script Name = #012        Command Path = #012        Sequence Number = 18#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStop.Method.Informational] Command Import-Module is Stopped.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 5#012        Command Name = Import-Module#012        Command Type = Cmdlet#012        Script Name = #012        Command Path = #012        Sequence Number = 19#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStart.Method.Informational] Command Get-Variable is Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 4#012        Command Name = Get-Variable#012        Command Type = Cmdlet#012        Script Name = #012        Command Path = #012        Sequence Number = 20#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStop.Method.Informational] Command Get-Variable is Stopped.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 4#012        Command Name = Get-Variable#012        Command Type = Cmdlet#012        Script Name = #012        Command Path = #012        Sequence Number = 21#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStart.Method.Informational] Command prompt is Started.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 6#012        Command Name = prompt#012        Command Type = Function#012        Script Name = #012        Command Path = #012        Sequence Number = 22#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n
Mar  5 11:35:17 MYHOST powershell[4930]: (v6.0.1:9:11) [Command_Lifecycle:CommandStop.Method.Informational] Command prompt is Stopped.#012%n%nContext:%n        Severity = Informational#012        Host Name = ConsoleHost#012        Host Version = 6.0.1#012        Host ID = f85e018a-3700-4255-b508-c71bdb3b809d#012        Host Application = /opt/microsoft/powershell/6.0.1/pwsh.dll#012        Engine Version = 6.0.1#012        Runspace ID = 3ce268c9-c288-47d9-8b00-aff8c6154184#012        Pipeline ID = 6#012        Command Name = prompt#012        Command Type = Function#012        Script Name = #012        Command Path = #012        Sequence Number = 23#012        User = MYHOST\nagios#012        Connected User = #012        Shell ID = Microsoft.PowerShell#012%n%nUser Data:%n%n

Example of pipes from dotnet clr and GUI directory being created (visible using "inotifywait -e create -m /tmp" to monitor /tmp):

/tmp/ CREATE clr-debug-pipe-9951-96248424-in
/tmp/ CREATE clr-debug-pipe-9951-96248424-out
/tmp/ CREATE,ISDIR 63b11b94-e868-42ea-96a2-5f3ae578fdcf

Is there a way to disable these messages/the GUID directory from being created?

WG-Engine

Most helpful comment

This is obviously still an issue and it seems to be ignored?

CentOS Linux release 7.5.1804 (Core)
6.2.1-1.rhel.7 from packages-microsoft-com-prod

My Nagios is creating so many files and folders in /tmp that it has literally become unusable. Can't read, can't delete, can't do anything.

I could just workaround by creating a cron that empties /tmp every 5 minutes, but that really shouldn't be necessary.

All 13 comments

syslog problem was a known bug that got fixed.
You can get the fix by rebuilding from current sources or wait couple of days for the next release.
For more info see #6032 and #6218

@anmenaga what about the GUID directory? that's what's currently killing me right now. It leaves behind a ton of GUID directories until /tmp has so many files it falls over.

@dantraMSFT @daxian-dbw for info about GUID directories in /tmp

It sounds like this might be coming from dotnet clr. They have me post a ticket over here about the syslog and they're now checking but they believe it might be coming from dotnet.

dotnet says the GUID directory is coming from PowerShell https://github.com/dotnet/coreclr/issues/8844

Hi all,

This still appears to be a problem for me as well - as per dotnet/coreclr#8844 they reference the GUID/Verbose logging as a PowerShell issue. Anyone have any ideas how to fix?

OS: RHEL 7.6
PowerShell version: PowerShell 6.2.0

Seeing mass amounts of verbose logging like;

Apr 04 18:38:11 <SERVER> powershell[5783]: [24.5K blob data]
Apr 04 18:38:11 <SERVER> powershell[5783]: [20.6K blob data]
Apr 04 18:38:11 <SERVER> powershell[5783]: (6.2.0:9:80) [Command_Health:ExecutePipeline.Exception.Warning] Error Message = System error.


                                                           Context:
                                                                   Severity = Warning
                                                                   Host Name = ConsoleHost
                                                                   Host Version = 6.2.0
                                                                   Host ID = 5ffe6342-0494-4afb-815c-ea93c75c6662
                                                                   Host Application = /opt/microsoft/powershell/6/pwsh.dll <SOME SCRIPT>
                                                                   Engine Version = 6.2.0
                                                                   Runspace ID = 3bbece8e-69f7-447a-ac4f-813adb83a86a
                                                                   Pipeline ID = 1
                                                                   Command Name =
                                                                   Command Type =
                                                                   Script Name =
                                                                   Command Path =
                                                                   Sequence Number = 37
                                                                   User = <USER>
                                                                   Connected User =
                                                                   Shell ID = Microsoft.PowerShell

With files created like (note: this doesn't correlate to logging above);

/tmp/d839926e-40dc-4256-9def-efa0e3e59de5
/tmp/CoreFxPipe_PSHost.D4F03146.15029.None.pwsh
/tmp/d839926e-40dc-4256-9def-efa0e3e59de5/.cache/powershell/StartupProfileData-NonInteractive
/tmp/d839926e-40dc-4256-9def-efa0e3e59de5/.local/share/powershell/Modules/  # <-- Empty

Suspected Cause

In my case, PowerShell is a subprocess (of Zabbix monitoring scripts) which has a timeout value of 30 seconds. After this time I believe it kills the sub-process, so I'm suspecting it isn't cleaning up properly but not 100% sure yet.

Workaround:

Added a cron job to find/delete those files and added the following file (/etc/rsyslog.d/40-powershell.conf) to stop logging which seems to work okay.

:syslogtag, contains, "powershell[" stop

This is obviously still an issue and it seems to be ignored?

CentOS Linux release 7.5.1804 (Core)
6.2.1-1.rhel.7 from packages-microsoft-com-prod

My Nagios is creating so many files and folders in /tmp that it has literally become unusable. Can't read, can't delete, can't do anything.

I could just workaround by creating a cron that empties /tmp every 5 minutes, but that really shouldn't be necessary.

I have the same problem as @mattykay.
Lowering the log level from Powershell by doing the following fixes the verbose logging:

  1. Find out where $PSHOME is. My $PSHOME pointed to /opt/microsoft/powershell/6/. Take note that $PSHOME is a variable in PWSH, not in any other shell.
  2. Create a file in $PSHOME named powershell.config.json.
  3. Add the following JSON to the file:
    { "LogLevel": "error" }
    Other log levels are found here: https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_logging_non-windows?view=powershell-6#configuring-logging-on-non-windows-system

I haven't found a solution for the creation of "CoreFxPipe" files in /tmp yet. A cron script will do for now.
Here's another issue about the file creation: https://github.com/Microsoft/dotnet/issues/880

@Didr This works like a charm on Ubuntu 1804 with 6.2.0
Thanks

The problem with the massive amount of UUID directories and CoreFX files in /tmp still exists.

OS: CentOS Linux release 7.7.1908 (Core)
Powershell: 7.0.0

Same problem on debian 9.12, pwsh 7.0.0

itb filled up root /tmp with so many files that i had no inode left :-(

I have the same problem with RHEL 7.8 and powershell 7.0.0 :(

Hi all,
Is there any forecast to solve this issue?
Thanks.

Was this page helpful?
0 / 5 - 0 ratings