Jump to content

Recommended Posts

Posted

I've been trying to start a tekkit server, but when I try to open the batch file it says:

C:/Users/clarson/Desktop/Tekkit Server>java -Xms3G Xmx3G -jar Tekkit.jar nogui

'java' is not recognized as a internal or external command,

operable program or batch file.

C:/Users/clarson/Desktop/Tekkit Server>pause

Press any key to continue . . .

So I press any key ; and then the batch file instantly closes,

what do i do i need help

Posted

your path variable is not set properly. use this as you start.bat

@Echo OFF

:start

 

Set jarname=Tekkit.jar

 

SET BINDIR=%~dp0

CD /D "%BINDIR%"

color 7

cls

 

if exist {C:\Program Files\Java\jre7\bin\java.exe} (

color A

Echo.

Echo 64 Bit mode

ping 1.1.1.1 -w 1 >NUL

cls

color 7

"C:\Program Files\Java\jre7\bin\java.exe" -Xms1G -Xmx4G -jar %jarname%

goto end

 

) else (

 

color C

Echo.

Echo 32 bit mode

ping 2.2.2.2 -w 1 >NUL

cls

color 7

"C:\Program Files (x86)\Java\jre7\bin\java.exe" -Xms1G -Xmx3G -jar %jarname%

goto end

)

 

:end

cls

color E

Echo.

Echo STOPPED! CLOSE NOW TO STOP FULLY!

ping 1.1.1.1 -w 5 >NUL

ping 2.2.2.2 -w 5 >NUL

goto start

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...