Changing Windows process priority via command line
I want to change Windows process priority via command line.
How can I do that?
windows command-line process priority
add a comment |
I want to change Windows process priority via command line.
How can I do that?
windows command-line process priority
add a comment |
I want to change Windows process priority via command line.
How can I do that?
windows command-line process priority
I want to change Windows process priority via command line.
How can I do that?
windows command-line process priority
windows command-line process priority
asked Jul 17 '13 at 5:47
Bobs
1,92521520
1,92521520
add a comment |
add a comment |
5 Answers
5
active
oldest
votes
The command line syntax:
wmic process where name="AppName" CALL setpriority ProcessIDLevel
Example:
wmic process where name="calc.exe" CALL setpriority 32768
or
wmic process where name="calc.exe" CALL setpriority "above normal"
Priority:
- idle: 64 (or "idle")
- below normal: 16384 (or "below normal")
- normal: 32 (or "normal")
- above normal: 32768 (or "above normal")
- high priority: 128 (or "high priority")
- real time: 256 (or "realtime")
7
You can also do wildcardswmic process where "CommandLine like '%calc%'" CALL setpriority "below normal"
– laggingreflex
Feb 16 '14 at 17:59
Its possible to do the same for Background(low IO and memory priority) like in Process Explorer?
– miky
Aug 5 '14 at 8:53
will this work even on "cmd.exe" from batch? ...batch that will start that cmd.exe?
– user902300
May 23 '18 at 16:35
Note: the first set of quotes is mandatory, so in other shells the quotes must be escaped (or double-quoted). In Cygwin:wmic process where 'name="calc.exe"' CALL setpriority "idle"
– piojo
Aug 7 '18 at 3:07
why is below/above normal value is so large and strange? And why is normal less than both idle and realtime?
– phuclv
Sep 5 '18 at 4:54
|
show 1 more comment
A small addition.
You can also use string values instead of integers (easier to memorize) like that:
wmic process where name="calc.exe" CALL setpriority "idle"
Possible values:
"idle", "low", "below normal", "normal", "above normal", "high priority", "realtime"
PS. Don't forget the quotes, especially if using multiple words in a string value
The first set of quotes is mandatory, even if not using multiple words. It must also be passed to the command, rather than being interpreted by the shell.
– piojo
Aug 7 '18 at 3:08
On win10 Pro 1809, "low" is not a recognized value - it throws an error. using "Idle" causes the process to be displayed as "low" priority in task manager...
– ljwobker
Dec 3 '18 at 15:01
add a comment |
From batch command line I would simply use PowerShell. This example starts calc.exe, finds its process and adjusts its priority class to "IDLE", aka LOW:
start /b /wait powershell.exe -command "calc.exe;$prog = Get-Process -Name calc;$prog.PriorityClass = [System.Diagnostics.ProcessPriorityClass]::IDLE"
Specify one of the following enumeration values: "Normal, Idle, High, RealTime, BelowNormal, AboveNormal"
Here is the same thing from PowerShell with split lines:
calc.exe
$prog = Get-Process -Name calc
$prog.PriorityClass = [System.Diagnostics.ProcessPriorityClass]::IDLE
What's the point of repeating what was already said before?
– harrymc
Feb 12 '14 at 15:15
@harrymc It answers the original question, using PowerShell.
– paradroid
Feb 12 '14 at 17:00
@harrymc - actually I am repeating what I said from DEC. stackoverflow.com/questions/20693028/…
– Knuckle-Dragger
Feb 15 '14 at 16:41
No problem. Just that I linked to something pretty similar.
– harrymc
Feb 15 '14 at 17:33
add a comment |
In addition to existing answers, the question Windows Equivalent of 'nice'
lists some more solutions:
- Using the command START in the command-prompt (CMD).
- Using the free ProcessTamer to set up a rule on the .exe
that is automatically enforced whenever that process is started. - Using a PowerShell script contained here.
- Using a VBScript script contained here.
Additionally, the old SetPriority utility might still work, but I haven't tried it for many years now.
Some of these solutions may not work on system services or may need to be Run as Administrator.
add a comment |
I am running Windows 7 64-bit.
The wmic command is not reliable. In my considerable experience, it fails unexpectedly for too many (mostly inexplicable) reasons.
The best possible command, because of its reliability, is the START command. The syntax is very simple (this is the 3-line run command for a batch file):
:: Boost thread priority
SET command=<program.exe> <options>
start "" /REALTIME /B /W %command%
In my opinion its high degree of reliability stems from the fact that it sets the priority level with which the .exe program is launched, rather than trying to meddle with priority after the program has begun running with a different priority.
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "3"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f620724%2fchanging-windows-process-priority-via-command-line%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
5 Answers
5
active
oldest
votes
5 Answers
5
active
oldest
votes
active
oldest
votes
active
oldest
votes
The command line syntax:
wmic process where name="AppName" CALL setpriority ProcessIDLevel
Example:
wmic process where name="calc.exe" CALL setpriority 32768
or
wmic process where name="calc.exe" CALL setpriority "above normal"
Priority:
- idle: 64 (or "idle")
- below normal: 16384 (or "below normal")
- normal: 32 (or "normal")
- above normal: 32768 (or "above normal")
- high priority: 128 (or "high priority")
- real time: 256 (or "realtime")
7
You can also do wildcardswmic process where "CommandLine like '%calc%'" CALL setpriority "below normal"
– laggingreflex
Feb 16 '14 at 17:59
Its possible to do the same for Background(low IO and memory priority) like in Process Explorer?
– miky
Aug 5 '14 at 8:53
will this work even on "cmd.exe" from batch? ...batch that will start that cmd.exe?
– user902300
May 23 '18 at 16:35
Note: the first set of quotes is mandatory, so in other shells the quotes must be escaped (or double-quoted). In Cygwin:wmic process where 'name="calc.exe"' CALL setpriority "idle"
– piojo
Aug 7 '18 at 3:07
why is below/above normal value is so large and strange? And why is normal less than both idle and realtime?
– phuclv
Sep 5 '18 at 4:54
|
show 1 more comment
The command line syntax:
wmic process where name="AppName" CALL setpriority ProcessIDLevel
Example:
wmic process where name="calc.exe" CALL setpriority 32768
or
wmic process where name="calc.exe" CALL setpriority "above normal"
Priority:
- idle: 64 (or "idle")
- below normal: 16384 (or "below normal")
- normal: 32 (or "normal")
- above normal: 32768 (or "above normal")
- high priority: 128 (or "high priority")
- real time: 256 (or "realtime")
7
You can also do wildcardswmic process where "CommandLine like '%calc%'" CALL setpriority "below normal"
– laggingreflex
Feb 16 '14 at 17:59
Its possible to do the same for Background(low IO and memory priority) like in Process Explorer?
– miky
Aug 5 '14 at 8:53
will this work even on "cmd.exe" from batch? ...batch that will start that cmd.exe?
– user902300
May 23 '18 at 16:35
Note: the first set of quotes is mandatory, so in other shells the quotes must be escaped (or double-quoted). In Cygwin:wmic process where 'name="calc.exe"' CALL setpriority "idle"
– piojo
Aug 7 '18 at 3:07
why is below/above normal value is so large and strange? And why is normal less than both idle and realtime?
– phuclv
Sep 5 '18 at 4:54
|
show 1 more comment
The command line syntax:
wmic process where name="AppName" CALL setpriority ProcessIDLevel
Example:
wmic process where name="calc.exe" CALL setpriority 32768
or
wmic process where name="calc.exe" CALL setpriority "above normal"
Priority:
- idle: 64 (or "idle")
- below normal: 16384 (or "below normal")
- normal: 32 (or "normal")
- above normal: 32768 (or "above normal")
- high priority: 128 (or "high priority")
- real time: 256 (or "realtime")
The command line syntax:
wmic process where name="AppName" CALL setpriority ProcessIDLevel
Example:
wmic process where name="calc.exe" CALL setpriority 32768
or
wmic process where name="calc.exe" CALL setpriority "above normal"
Priority:
- idle: 64 (or "idle")
- below normal: 16384 (or "below normal")
- normal: 32 (or "normal")
- above normal: 32768 (or "above normal")
- high priority: 128 (or "high priority")
- real time: 256 (or "realtime")
edited Aug 24 '17 at 14:16
Fabby
4461418
4461418
answered Jul 17 '13 at 5:47
Bobs
1,92521520
1,92521520
7
You can also do wildcardswmic process where "CommandLine like '%calc%'" CALL setpriority "below normal"
– laggingreflex
Feb 16 '14 at 17:59
Its possible to do the same for Background(low IO and memory priority) like in Process Explorer?
– miky
Aug 5 '14 at 8:53
will this work even on "cmd.exe" from batch? ...batch that will start that cmd.exe?
– user902300
May 23 '18 at 16:35
Note: the first set of quotes is mandatory, so in other shells the quotes must be escaped (or double-quoted). In Cygwin:wmic process where 'name="calc.exe"' CALL setpriority "idle"
– piojo
Aug 7 '18 at 3:07
why is below/above normal value is so large and strange? And why is normal less than both idle and realtime?
– phuclv
Sep 5 '18 at 4:54
|
show 1 more comment
7
You can also do wildcardswmic process where "CommandLine like '%calc%'" CALL setpriority "below normal"
– laggingreflex
Feb 16 '14 at 17:59
Its possible to do the same for Background(low IO and memory priority) like in Process Explorer?
– miky
Aug 5 '14 at 8:53
will this work even on "cmd.exe" from batch? ...batch that will start that cmd.exe?
– user902300
May 23 '18 at 16:35
Note: the first set of quotes is mandatory, so in other shells the quotes must be escaped (or double-quoted). In Cygwin:wmic process where 'name="calc.exe"' CALL setpriority "idle"
– piojo
Aug 7 '18 at 3:07
why is below/above normal value is so large and strange? And why is normal less than both idle and realtime?
– phuclv
Sep 5 '18 at 4:54
7
7
You can also do wildcards
wmic process where "CommandLine like '%calc%'" CALL setpriority "below normal"– laggingreflex
Feb 16 '14 at 17:59
You can also do wildcards
wmic process where "CommandLine like '%calc%'" CALL setpriority "below normal"– laggingreflex
Feb 16 '14 at 17:59
Its possible to do the same for Background(low IO and memory priority) like in Process Explorer?
– miky
Aug 5 '14 at 8:53
Its possible to do the same for Background(low IO and memory priority) like in Process Explorer?
– miky
Aug 5 '14 at 8:53
will this work even on "cmd.exe" from batch? ...batch that will start that cmd.exe?
– user902300
May 23 '18 at 16:35
will this work even on "cmd.exe" from batch? ...batch that will start that cmd.exe?
– user902300
May 23 '18 at 16:35
Note: the first set of quotes is mandatory, so in other shells the quotes must be escaped (or double-quoted). In Cygwin:
wmic process where 'name="calc.exe"' CALL setpriority "idle"– piojo
Aug 7 '18 at 3:07
Note: the first set of quotes is mandatory, so in other shells the quotes must be escaped (or double-quoted). In Cygwin:
wmic process where 'name="calc.exe"' CALL setpriority "idle"– piojo
Aug 7 '18 at 3:07
why is below/above normal value is so large and strange? And why is normal less than both idle and realtime?
– phuclv
Sep 5 '18 at 4:54
why is below/above normal value is so large and strange? And why is normal less than both idle and realtime?
– phuclv
Sep 5 '18 at 4:54
|
show 1 more comment
A small addition.
You can also use string values instead of integers (easier to memorize) like that:
wmic process where name="calc.exe" CALL setpriority "idle"
Possible values:
"idle", "low", "below normal", "normal", "above normal", "high priority", "realtime"
PS. Don't forget the quotes, especially if using multiple words in a string value
The first set of quotes is mandatory, even if not using multiple words. It must also be passed to the command, rather than being interpreted by the shell.
– piojo
Aug 7 '18 at 3:08
On win10 Pro 1809, "low" is not a recognized value - it throws an error. using "Idle" causes the process to be displayed as "low" priority in task manager...
– ljwobker
Dec 3 '18 at 15:01
add a comment |
A small addition.
You can also use string values instead of integers (easier to memorize) like that:
wmic process where name="calc.exe" CALL setpriority "idle"
Possible values:
"idle", "low", "below normal", "normal", "above normal", "high priority", "realtime"
PS. Don't forget the quotes, especially if using multiple words in a string value
The first set of quotes is mandatory, even if not using multiple words. It must also be passed to the command, rather than being interpreted by the shell.
– piojo
Aug 7 '18 at 3:08
On win10 Pro 1809, "low" is not a recognized value - it throws an error. using "Idle" causes the process to be displayed as "low" priority in task manager...
– ljwobker
Dec 3 '18 at 15:01
add a comment |
A small addition.
You can also use string values instead of integers (easier to memorize) like that:
wmic process where name="calc.exe" CALL setpriority "idle"
Possible values:
"idle", "low", "below normal", "normal", "above normal", "high priority", "realtime"
PS. Don't forget the quotes, especially if using multiple words in a string value
A small addition.
You can also use string values instead of integers (easier to memorize) like that:
wmic process where name="calc.exe" CALL setpriority "idle"
Possible values:
"idle", "low", "below normal", "normal", "above normal", "high priority", "realtime"
PS. Don't forget the quotes, especially if using multiple words in a string value
answered Jul 17 '13 at 6:33
Ashtray
1,33911216
1,33911216
The first set of quotes is mandatory, even if not using multiple words. It must also be passed to the command, rather than being interpreted by the shell.
– piojo
Aug 7 '18 at 3:08
On win10 Pro 1809, "low" is not a recognized value - it throws an error. using "Idle" causes the process to be displayed as "low" priority in task manager...
– ljwobker
Dec 3 '18 at 15:01
add a comment |
The first set of quotes is mandatory, even if not using multiple words. It must also be passed to the command, rather than being interpreted by the shell.
– piojo
Aug 7 '18 at 3:08
On win10 Pro 1809, "low" is not a recognized value - it throws an error. using "Idle" causes the process to be displayed as "low" priority in task manager...
– ljwobker
Dec 3 '18 at 15:01
The first set of quotes is mandatory, even if not using multiple words. It must also be passed to the command, rather than being interpreted by the shell.
– piojo
Aug 7 '18 at 3:08
The first set of quotes is mandatory, even if not using multiple words. It must also be passed to the command, rather than being interpreted by the shell.
– piojo
Aug 7 '18 at 3:08
On win10 Pro 1809, "low" is not a recognized value - it throws an error. using "Idle" causes the process to be displayed as "low" priority in task manager...
– ljwobker
Dec 3 '18 at 15:01
On win10 Pro 1809, "low" is not a recognized value - it throws an error. using "Idle" causes the process to be displayed as "low" priority in task manager...
– ljwobker
Dec 3 '18 at 15:01
add a comment |
From batch command line I would simply use PowerShell. This example starts calc.exe, finds its process and adjusts its priority class to "IDLE", aka LOW:
start /b /wait powershell.exe -command "calc.exe;$prog = Get-Process -Name calc;$prog.PriorityClass = [System.Diagnostics.ProcessPriorityClass]::IDLE"
Specify one of the following enumeration values: "Normal, Idle, High, RealTime, BelowNormal, AboveNormal"
Here is the same thing from PowerShell with split lines:
calc.exe
$prog = Get-Process -Name calc
$prog.PriorityClass = [System.Diagnostics.ProcessPriorityClass]::IDLE
What's the point of repeating what was already said before?
– harrymc
Feb 12 '14 at 15:15
@harrymc It answers the original question, using PowerShell.
– paradroid
Feb 12 '14 at 17:00
@harrymc - actually I am repeating what I said from DEC. stackoverflow.com/questions/20693028/…
– Knuckle-Dragger
Feb 15 '14 at 16:41
No problem. Just that I linked to something pretty similar.
– harrymc
Feb 15 '14 at 17:33
add a comment |
From batch command line I would simply use PowerShell. This example starts calc.exe, finds its process and adjusts its priority class to "IDLE", aka LOW:
start /b /wait powershell.exe -command "calc.exe;$prog = Get-Process -Name calc;$prog.PriorityClass = [System.Diagnostics.ProcessPriorityClass]::IDLE"
Specify one of the following enumeration values: "Normal, Idle, High, RealTime, BelowNormal, AboveNormal"
Here is the same thing from PowerShell with split lines:
calc.exe
$prog = Get-Process -Name calc
$prog.PriorityClass = [System.Diagnostics.ProcessPriorityClass]::IDLE
What's the point of repeating what was already said before?
– harrymc
Feb 12 '14 at 15:15
@harrymc It answers the original question, using PowerShell.
– paradroid
Feb 12 '14 at 17:00
@harrymc - actually I am repeating what I said from DEC. stackoverflow.com/questions/20693028/…
– Knuckle-Dragger
Feb 15 '14 at 16:41
No problem. Just that I linked to something pretty similar.
– harrymc
Feb 15 '14 at 17:33
add a comment |
From batch command line I would simply use PowerShell. This example starts calc.exe, finds its process and adjusts its priority class to "IDLE", aka LOW:
start /b /wait powershell.exe -command "calc.exe;$prog = Get-Process -Name calc;$prog.PriorityClass = [System.Diagnostics.ProcessPriorityClass]::IDLE"
Specify one of the following enumeration values: "Normal, Idle, High, RealTime, BelowNormal, AboveNormal"
Here is the same thing from PowerShell with split lines:
calc.exe
$prog = Get-Process -Name calc
$prog.PriorityClass = [System.Diagnostics.ProcessPriorityClass]::IDLE
From batch command line I would simply use PowerShell. This example starts calc.exe, finds its process and adjusts its priority class to "IDLE", aka LOW:
start /b /wait powershell.exe -command "calc.exe;$prog = Get-Process -Name calc;$prog.PriorityClass = [System.Diagnostics.ProcessPriorityClass]::IDLE"
Specify one of the following enumeration values: "Normal, Idle, High, RealTime, BelowNormal, AboveNormal"
Here is the same thing from PowerShell with split lines:
calc.exe
$prog = Get-Process -Name calc
$prog.PriorityClass = [System.Diagnostics.ProcessPriorityClass]::IDLE
edited Sep 5 '18 at 0:18
Peter Mortensen
8,331166184
8,331166184
answered Feb 11 '14 at 20:17
Knuckle-Dragger
1,6271917
1,6271917
What's the point of repeating what was already said before?
– harrymc
Feb 12 '14 at 15:15
@harrymc It answers the original question, using PowerShell.
– paradroid
Feb 12 '14 at 17:00
@harrymc - actually I am repeating what I said from DEC. stackoverflow.com/questions/20693028/…
– Knuckle-Dragger
Feb 15 '14 at 16:41
No problem. Just that I linked to something pretty similar.
– harrymc
Feb 15 '14 at 17:33
add a comment |
What's the point of repeating what was already said before?
– harrymc
Feb 12 '14 at 15:15
@harrymc It answers the original question, using PowerShell.
– paradroid
Feb 12 '14 at 17:00
@harrymc - actually I am repeating what I said from DEC. stackoverflow.com/questions/20693028/…
– Knuckle-Dragger
Feb 15 '14 at 16:41
No problem. Just that I linked to something pretty similar.
– harrymc
Feb 15 '14 at 17:33
What's the point of repeating what was already said before?
– harrymc
Feb 12 '14 at 15:15
What's the point of repeating what was already said before?
– harrymc
Feb 12 '14 at 15:15
@harrymc It answers the original question, using PowerShell.
– paradroid
Feb 12 '14 at 17:00
@harrymc It answers the original question, using PowerShell.
– paradroid
Feb 12 '14 at 17:00
@harrymc - actually I am repeating what I said from DEC. stackoverflow.com/questions/20693028/…
– Knuckle-Dragger
Feb 15 '14 at 16:41
@harrymc - actually I am repeating what I said from DEC. stackoverflow.com/questions/20693028/…
– Knuckle-Dragger
Feb 15 '14 at 16:41
No problem. Just that I linked to something pretty similar.
– harrymc
Feb 15 '14 at 17:33
No problem. Just that I linked to something pretty similar.
– harrymc
Feb 15 '14 at 17:33
add a comment |
In addition to existing answers, the question Windows Equivalent of 'nice'
lists some more solutions:
- Using the command START in the command-prompt (CMD).
- Using the free ProcessTamer to set up a rule on the .exe
that is automatically enforced whenever that process is started. - Using a PowerShell script contained here.
- Using a VBScript script contained here.
Additionally, the old SetPriority utility might still work, but I haven't tried it for many years now.
Some of these solutions may not work on system services or may need to be Run as Administrator.
add a comment |
In addition to existing answers, the question Windows Equivalent of 'nice'
lists some more solutions:
- Using the command START in the command-prompt (CMD).
- Using the free ProcessTamer to set up a rule on the .exe
that is automatically enforced whenever that process is started. - Using a PowerShell script contained here.
- Using a VBScript script contained here.
Additionally, the old SetPriority utility might still work, but I haven't tried it for many years now.
Some of these solutions may not work on system services or may need to be Run as Administrator.
add a comment |
In addition to existing answers, the question Windows Equivalent of 'nice'
lists some more solutions:
- Using the command START in the command-prompt (CMD).
- Using the free ProcessTamer to set up a rule on the .exe
that is automatically enforced whenever that process is started. - Using a PowerShell script contained here.
- Using a VBScript script contained here.
Additionally, the old SetPriority utility might still work, but I haven't tried it for many years now.
Some of these solutions may not work on system services or may need to be Run as Administrator.
In addition to existing answers, the question Windows Equivalent of 'nice'
lists some more solutions:
- Using the command START in the command-prompt (CMD).
- Using the free ProcessTamer to set up a rule on the .exe
that is automatically enforced whenever that process is started. - Using a PowerShell script contained here.
- Using a VBScript script contained here.
Additionally, the old SetPriority utility might still work, but I haven't tried it for many years now.
Some of these solutions may not work on system services or may need to be Run as Administrator.
edited Sep 5 '18 at 0:19
Peter Mortensen
8,331166184
8,331166184
answered Feb 11 '14 at 10:25
harrymc
253k12261563
253k12261563
add a comment |
add a comment |
I am running Windows 7 64-bit.
The wmic command is not reliable. In my considerable experience, it fails unexpectedly for too many (mostly inexplicable) reasons.
The best possible command, because of its reliability, is the START command. The syntax is very simple (this is the 3-line run command for a batch file):
:: Boost thread priority
SET command=<program.exe> <options>
start "" /REALTIME /B /W %command%
In my opinion its high degree of reliability stems from the fact that it sets the priority level with which the .exe program is launched, rather than trying to meddle with priority after the program has begun running with a different priority.
add a comment |
I am running Windows 7 64-bit.
The wmic command is not reliable. In my considerable experience, it fails unexpectedly for too many (mostly inexplicable) reasons.
The best possible command, because of its reliability, is the START command. The syntax is very simple (this is the 3-line run command for a batch file):
:: Boost thread priority
SET command=<program.exe> <options>
start "" /REALTIME /B /W %command%
In my opinion its high degree of reliability stems from the fact that it sets the priority level with which the .exe program is launched, rather than trying to meddle with priority after the program has begun running with a different priority.
add a comment |
I am running Windows 7 64-bit.
The wmic command is not reliable. In my considerable experience, it fails unexpectedly for too many (mostly inexplicable) reasons.
The best possible command, because of its reliability, is the START command. The syntax is very simple (this is the 3-line run command for a batch file):
:: Boost thread priority
SET command=<program.exe> <options>
start "" /REALTIME /B /W %command%
In my opinion its high degree of reliability stems from the fact that it sets the priority level with which the .exe program is launched, rather than trying to meddle with priority after the program has begun running with a different priority.
I am running Windows 7 64-bit.
The wmic command is not reliable. In my considerable experience, it fails unexpectedly for too many (mostly inexplicable) reasons.
The best possible command, because of its reliability, is the START command. The syntax is very simple (this is the 3-line run command for a batch file):
:: Boost thread priority
SET command=<program.exe> <options>
start "" /REALTIME /B /W %command%
In my opinion its high degree of reliability stems from the fact that it sets the priority level with which the .exe program is launched, rather than trying to meddle with priority after the program has begun running with a different priority.
answered Dec 18 '18 at 15:40
Ed999
1587
1587
add a comment |
add a comment |
Thanks for contributing an answer to Super User!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f620724%2fchanging-windows-process-priority-via-command-line%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown