【发布时间】:2020-04-30 18:38:19
【问题描述】:
我正在 Windows 10 上运行 PostgreSQL 12 基准测试。我想限制 PostgreSQL 服务使用的 CPU 内核数量,以测试 CPU 性能如何影响 TPU。
现在我正在使用以下命令启动 PostgreSQL 服务:
net start postgresql-x64-12
我知道如何限制普通 Windows 应用程序的 CPU 内核数量,例如:
start /affinity 1 "" "C:\Windows\System32\calc.exe"
如何限制从 net start 命令运行的 Windows 服务使用的 CPU 内核数? net start 命令中是否有等效的 /affinity 选项?
【问题讨论】:
标签: windows command-line windows-services