Jump to content

Setting java.exe and javaw.exe on high priority by default


Recommended Posts

Posted

Is there a way I can set both processes on high priority by default with one click? I've made batch files that execute TechnicLauncher.exe on high priority but java.exe remains normal priority. I don't want to launch Task Manager every time I launch Minecraft.

Posted

there's almost no situation where doing this will be helpful, I don't know of a way off hand. why do you think this is needed?

My Minecraft lags and stutters quite often. That's why. I'm looking for a batch file that can do this with one click.

Posted

http://www.prnwatch.com/prio_x64.exe

http://www.prnwatch.com/prio.exe

either of those will do it, i have been using priority saver for years, it also adds a a few nice features to task manager, for example; hovering your mouse over processes and services now gives detailed info.

start your game, tab out to windows find the process and select high priority, now it will save the priority you select, and whenever you use that program from now on it will always be set to whatever you selected.

Posted

does this actually help that? regardless, I was curious if this is possible as well and it turns out that it is. in fact, it took a single google search to find the required information because I'm just that good.

to do this, place the batch file in your .techniclauncher directory


mkdir rtemp

start /HIGH /B java -jar technic-launcher.jar

you can add whatever memory limits you want between "java" and "-jar".

explanation is as follows:

"mkdir rtemp" is used to prevent the launcher from restarting itself, which would remove our process adjustments

the start command is what works the magic for us. /HIGH does what you would expect, runs the command with high priority. /B keeps it in the command window it is currently in, instead of opening up a second window. this isn't required, but it is more tidy. after that it's just the usual command line to run the launcher .jar file.

Posted

you can add whatever memory limits you want between "java" and "-jar".

explanation is as follows:

"mkdir rtemp" is used to prevent the launcher from restarting itself, which would remove our process adjustments

the start command is what works the magic for us. /HIGH does what you would expect, runs the command with high priority. /B keeps it in the command window it is currently in, instead of opening up a second window. this isn't required, but it is more tidy. after that it's just the usual command line to run the launcher .jar file.

You have my thanks, staff member! :D

I'm just kind of confused about how you would type in the memory limits between "java" and "-jar". Do you type just a number in there?

And thank you too, TopAce6, I will save that for later. But for now that is not needed.

Posted

You have my thanks, staff member! :D

I'm just kind of confused about how you would type in the memory limits between "java" and "-jar". Do you type just a number in there?

using the "-Xmx <number>" and "-Xms <number>" command line arguments. I did not include them because I do not know your system and they are not the same for every person. -Xmx will set the maximum amount of memory java can use, while -Xms sets how much it starts out at, which it can increase as needed up to the cap set with -Xmx.

the numbers can use units as well, so 1G is as valid as 1024M and both are 1 gigabyte.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...