【发布时间】:2023-02-09 20:58:42
【问题描述】:
我想用下面的 powershell 脚本获取 Windows 进程的内存转储。
我曾经尝试过这个脚本。但它给出以下错误:
方法调用失败,因为 [System.RuntimeType] 不包含 名为“GetCurrentThreadId”的方法。
############################################################# $process = Get-Process -Name AggregatorHost $threadId = [System.Diagnostics.Process].GetCurrentThreadId() $thread = $process.Threads | Where-Object { $_.Id -eq $threadId } $thread.Export("test.dmp") ###################################################################如何解决这个问题或者如果你有其他方法请告诉我?
powershell内存转储
【问题讨论】:
标签: windows powershell